/*
Theme Name: Quietype
Theme URI: https://github.com/taifuer/quietype
Author: taifu
Author URI: https://github.com/taifuer
Description: A quiet WordPress theme for thoughtful reading, designed for Chinese long-form and technical writing.
Version: 0.10.21
Requires at least: 6.6
Tested up to: 6.8
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: quietype
*/

/* Design tokens */
:root {
	--page: #fdfdfb;
	--paper: #fdfdfb;
	--text: #262724;
	--text-soft: #40423e;
	--muted: #666a63;
	--faint: #858980;
	--line: #e3e0d8;
	--accent: #795844;
	--accent-soft: #eee4dc;
	--code: #f1f2ef;
	--code-dark: #f8f9f6;
	--serif: "Source Han Serif SC", "Noto Serif CJK SC", "Noto Serif SC", "Songti SC", STSong, SimSun, serif;
	--sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
	--mono: "JetBrains Mono", "Sarasa Mono SC", "Cascadia Code", "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
	--content: 800px;
	--layout: 960px;
	--anchor-offset: 88px;
}

html[data-reading-bg="warm"] {
	--page: #fbf6e9;
	--paper: #fbf6e9;
	--text: #302b23;
	--text-soft: #4b453a;
	--muted: #70685a;
	--faint: #8e8576;
	--line: #ded5c4;
	--accent: #805a3d;
	--accent-soft: #eee0cb;
	--code: #eee8dc;
	--code-dark: #faf6ed;
}

html[data-reading-bg="green"] {
	--page: #f2f7ef;
	--paper: #f2f7ef;
	--text: #263029;
	--text-soft: #414d44;
	--muted: #637066;
	--faint: #7f8c82;
	--line: #d2ddd2;
	--accent: #4d725c;
	--accent-soft: #d9e8dc;
	--code: #e5ece4;
	--code-dark: #f3f7f1;
}

/* Base */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--page); -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--text); font: 17px/1.8 var(--sans); font-kerning: normal; font-variant-ligatures: common-ligatures; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; transition: background-color .22s, color .22s; }
a { color: inherit; text-decoration: none; }
button, input, textarea { color: inherit; font: inherit; }
img { max-width: 100%; height: auto; }
figure { margin: 0; }
::selection { background: var(--accent-soft); }
.screen-reader-text, .skip-link:not(:focus) { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link:focus { position: fixed; top: 10px; left: 10px; z-index: 100; padding: 8px 14px; background: var(--text); color: var(--paper); }
.quietype-icon { display: block; width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; }

/* Header and navigation */
.site-header { position: sticky; top: 0; z-index: 40; border-bottom: 1px solid color-mix(in srgb, var(--line) 78%, transparent); background: color-mix(in srgb, var(--page) 92%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.site-header__inner, .site-footer__inner, .prefooter-nav__inner { width: calc(100% - 48px); max-width: var(--layout); margin: auto; }
.site-header__inner { display: flex; align-items: center; height: 72px; }
.site-brand { display: flex; align-items: center; gap: 12px; }
.site-brand__wordmark { display: inline-block; color: var(--text); font: 700 21px/1.2 var(--serif); letter-spacing: .035em; }
.site-nav { display: flex; align-items: center; gap: 18px; margin-left: auto; }
.site-nav .menu { display: flex; align-items: center; gap: 24px; padding: 0; margin: 0; list-style: none; }
.site-nav li { position: relative; }
.site-nav a, .nav-toggle { padding: 7px 0; border: 0; background: none; color: var(--muted); font-size: 15px; line-height: 1.4; cursor: pointer; }
.site-nav a:hover, .site-nav .current-menu-item > a, .site-nav .current_page_item > a { color: var(--accent); }
.site-nav .sub-menu { display: none; position: absolute; top: 32px; left: -16px; width: 150px; padding: 8px; margin: 0; border: 1px solid var(--line); background: var(--paper); box-shadow: 0 12px 30px #302b2114; list-style: none; }
.site-nav li:hover > .sub-menu, .site-nav li:focus-within > .sub-menu { display: block; }
.site-nav .sub-menu a { display: block; padding: 7px 9px; }
.mobile-header-actions { display: none; align-items: center; gap: 4px; margin-left: auto; }
.nav-toggle, .nav-backdrop, .submenu-toggle { display: none; }
.icon-button, .tool-button { position: relative; display: grid; place-items: center; width: 40px; height: 40px; padding: 0; margin: 0; border: 0; border-radius: 50%; background: transparent; color: var(--muted); box-shadow: none; cursor: pointer; transition: background-color .16s, color .16s; }
.icon-button:hover, .icon-button:focus-visible, .tool-button:hover, .tool-button:focus-visible { background: var(--accent-soft); color: var(--accent); outline: 0; }
.icon-button:focus-visible, .tool-button:focus-visible { box-shadow: 0 0 0 2px var(--page), 0 0 0 4px color-mix(in srgb, var(--accent) 50%, transparent); }
.icon-button[data-label]::after, .tool-button[data-label]::after { content: attr(data-label); position: absolute; top: 50%; right: calc(100% + 8px); z-index: 4; padding: 4px 7px; transform: translateY(-50%); border: 1px solid var(--line); border-radius: 3px; background: var(--paper); color: var(--text); font: 13px/1.3 var(--sans); white-space: nowrap; opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .12s; }
.icon-button[data-label]:hover::after, .icon-button[data-label]:focus-visible::after, .tool-button[data-label]:hover::after, .tool-button[data-label]:focus-visible::after { opacity: 1; visibility: visible; }
.search-toggle { display: grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--muted); box-shadow: none; cursor: pointer; }
.search-toggle:hover { background: var(--accent-soft); color: var(--accent); }
.search-toggle::after { right: auto; left: calc(100% + 8px); }
.site-search { position: absolute; top: calc(100% + 10px); right: calc((100% - var(--layout)) / 2); width: min(420px, calc(100vw - 32px)); padding: 12px; border: 1px solid var(--line); border-radius: 7px; background: var(--paper); box-shadow: 0 14px 38px #342d241c; }
.site-search .search-form { max-width: none; margin: 0; }
.search-form { display: flex; gap: 8px; border: 0; }
.search-form label { flex: 1; }
.search-field { width: 100%; min-height: 42px; padding: 8px 11px; border: 1px solid var(--line); border-radius: 4px; background: var(--page); font-size: 15px; outline: 0; }
.search-field:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 12%, transparent); }
.search-form button { min-width: 68px; padding: 8px 14px; border: 1px solid var(--text); border-radius: 4px; background: var(--text); color: var(--paper); font-size: 14px; font-weight: 600; cursor: pointer; }
.search-form button:hover { border-color: var(--accent); background: var(--accent); }
.site-reading-progress { display: none; position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; overflow: hidden; }
.single-post .site-reading-progress { display: block; }
.site-reading-progress i { display: block; width: 0; height: 100%; background: var(--accent); transition: width .08s linear; }

/* Shared layout and page headings */
.section-wrap { width: calc(100% - 48px); max-width: var(--layout); padding: 72px 0 54px; margin: auto; }
.content-width { width: calc(100% - 48px); max-width: var(--content); margin-right: auto; margin-left: auto; }
.eyebrow { color: var(--accent) !important; font-size: 13px !important; font-weight: 650; line-height: 1.5 !important; letter-spacing: .18em; text-transform: uppercase; }
.page-entry.section-wrap, .archive-index.section-wrap, .archive-page.section-wrap, .links-page.section-wrap, .tags-page.section-wrap { padding-top: 42px; }
.site-main .page-hero { max-width: 800px; margin-bottom: 24px; }
.page-hero h1 { margin: 0 0 20px; font: 650 clamp(36px, 4.25vw, 48px)/1.24 var(--sans); letter-spacing: -.03em; }
.page-hero > p:last-child, .page-description { color: var(--muted); font-size: 17px; }
.page-hero > :last-child, .page-description p { margin-bottom: 0; }
.page-entry > .content-width { max-width: 800px; margin-right: 0; margin-left: 0; }
.page-entry .article-content { margin-top: 0; }
.page-entry .article-content > :first-child { margin-top: 0; }
.empty-state { padding: 40px 0; color: var(--muted); }

/* Post index */
.post-index--home { padding-top: 58px; }
.section-title { display: flex; align-items: end; justify-content: flex-start; padding-bottom: 12px; border-bottom: 1px solid var(--text); }
.section-title h1 { margin: 0; font: 600 22px/1.2 var(--serif); letter-spacing: .04em; }
.section-title > a { color: var(--muted); font-size: 13px; }
.post-row { display: block; padding: 24px 0; border-bottom: 1px solid var(--line); }
.post-row h2 { margin: 0 0 4px; font: 620 20px/1.45 var(--serif); letter-spacing: -.01em; }
.post-row h2 a:hover { color: var(--accent); }
.post-row__excerpt { color: var(--muted); font-size: 15px; }
.post-row__excerpt p { margin: 0; }
.post-row__meta { display: flex; align-items: center; gap: 10px; min-height: 18px; margin-top: 9px; }
.post-row__date, .post-row__views, .post-row__reading { color: var(--muted); font-size: 13px; line-height: 1.5; white-space: nowrap; }
.post-row__date { padding: 0; font-family: var(--mono); font-size: 12px !important; font-variant-numeric: tabular-nums; letter-spacing: -.015em; }
.post-row__date::after { content: "·"; margin-left: 10px; color: var(--line); }
.post-row__terms { display: flex; flex-wrap: wrap; gap: 8px; }
.post-row__views { margin-left: 0; }
.post-row__views::before { content: "·"; margin-right: 10px; color: var(--line); }
.post-row__reading { margin-left: 0; padding: 0; }
.pagination { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px; margin-top: 54px; }
.pagination .page-numbers { display: grid; place-items: center; min-width: 34px; height: 34px; padding: 0 8px; border: 1px solid transparent; color: var(--muted); font-size: 13px; }
.pagination .current { border-color: var(--line); background: var(--paper); color: var(--text); }
.pagination a:hover { color: var(--accent); }

/* Taxonomies */
.post-category, .post-tag { font-size: 13px; line-height: inherit; letter-spacing: 0; }
.post-category { display: inline-flex; align-items: center; gap: 0; color: var(--accent); font-weight: 600; }
.post-category::before { content: ""; display: block; flex: none; width: 3px; height: .9em; margin-right: 4px; border-radius: 1px; background: currentColor; }
.post-category:hover { color: color-mix(in srgb, var(--accent) 78%, var(--text)); }
.post-tag { display: inline-flex; align-items: baseline; gap: 3px; color: var(--accent); font-weight: 500; }
.post-tag__mark { color: color-mix(in srgb, var(--accent) 82%, var(--muted)); font-family: var(--mono); font-size: .92em; font-weight: 650; line-height: 1; }
.post-row__terms a, .article-terms a, .archive-terms a { margin-right: 7px; }
.post-row__terms a:last-child, .article-terms a:last-child, .archive-terms a:last-child { margin-right: 0; }
.taxonomy-path { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin: 0 0 10px; color: var(--faint); font-size: 14px; line-height: 1.5; }
.taxonomy-path a { color: var(--muted); }
.taxonomy-path a:hover, .taxonomy-path a:focus-visible, .taxonomy-path span[aria-current="page"] { color: var(--accent); }

/* Article header and prose */
.article { position: relative; padding: 64px 0 110px; }
.article-header { padding-bottom: 28px; margin-bottom: 30px; border-bottom: 1px solid var(--line); }
.article-header h1 { margin: 0 0 18px; font: 680 clamp(34px, 3.75vw, 44px)/1.28 var(--sans); letter-spacing: -.025em; }
.article-terms { display: flex; flex-wrap: wrap; gap: 7px 12px; margin-bottom: 12px; }
.article-terms a { font-size: 14px !important; }
.article-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 0; color: var(--muted); font-size: 13px; line-height: 1.7; font-variant-numeric: tabular-nums; }
.article-meta__group { display: inline-flex; align-items: center; flex-wrap: wrap; }
.article-meta__group > * + *::before, .article-meta > .article-meta__group + *::before { content: "·"; display: inline-block; margin: 0 9px; color: var(--faint); }
.article-content { color: var(--text-soft); font: 400 17px/1.8 var(--sans); letter-spacing: .006em; }
.article-content > p:first-child { font-size: 17px; }
.article-content p { margin: .86em 0; }
.article-content h2, .article-content h3, .article-content h4 { color: var(--text); scroll-margin-top: var(--anchor-offset); }
.article-content h2 { margin: 1.55em 0 .6em; font: 650 24px/1.42 var(--sans); letter-spacing: -.018em; }
.article-content h3 { margin: 1.35em 0 .52em; font: 650 19px/1.48 var(--sans); }
.article-content h4 { margin: 1.2em 0 .46em; font: 650 17px/1.5 var(--sans); }
.heading-permalink { position: relative; display: inline-grid; place-items: center; width: 1.35em; height: 1.35em; margin-left: .24em; border-radius: 50%; color: var(--faint) !important; text-decoration: none !important; vertical-align: -.18em; opacity: 0; transition: background-color .14s, color .14s, opacity .14s; }
.heading-permalink .quietype-icon { width: .72em; height: .72em; }
.article-content :is(h2, h3):hover > .heading-permalink, .heading-permalink:focus-visible, .heading-permalink[data-copy-state="success"] { opacity: 1; }
.heading-permalink:hover, .heading-permalink:focus-visible { background: var(--accent-soft); color: var(--accent) !important; outline: 0; }
.heading-permalink:focus-visible { box-shadow: 0 0 0 2px var(--page), 0 0 0 4px color-mix(in srgb, var(--accent) 45%, transparent); }
.heading-permalink[data-copy-state="success"]::after { content: "已复制"; position: absolute; top: calc(100% + 4px); left: 50%; z-index: 5; padding: 3px 6px; transform: translateX(-50%); border: 1px solid var(--line); border-radius: 3px; background: var(--paper); color: var(--muted); box-shadow: 0 5px 14px #342d2412; font: 12px/1.35 var(--sans); letter-spacing: 0; white-space: nowrap; }
.article-content a { color: var(--accent); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--accent) 38%, transparent); text-decoration-thickness: 1px; text-underline-offset: .18em; overflow-wrap: anywhere; word-break: break-word; }
.article-content a:hover { text-decoration-color: var(--accent); }
.article-content strong { color: var(--text); font-weight: 650; }
.article-content :where(p, li, blockquote, td, th, figcaption) { min-width: 0; overflow-wrap: break-word; }
.article-content :not(pre) > code { padding: .12em .35em; border-radius: 3px; background: var(--code); font: 500 .86em/1.55 var(--mono); white-space: normal; overflow-wrap: anywhere; word-break: break-all; line-break: anywhere; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.article-content blockquote { padding: .1em 0 .1em 20px; margin: 1.35em 0; border-left: 3px solid var(--accent); color: var(--muted); }
.article-content blockquote p { margin: .65em 0; }
.article-content .article-alert { padding: 10px 16px; margin: 1.1em 0; border-left: 3px solid var(--muted); border-radius: 0 4px 4px 0; background: color-mix(in srgb, var(--code) 55%, var(--paper)); color: var(--text-soft); }
.article-content .article-alert--tip, .article-content .article-alert--important { border-left-color: var(--accent); }
.article-content .article-alert--warning, .article-content .article-alert--caution { border-left-color: #997439; background: color-mix(in srgb, #cda550 9%, var(--paper)); }
.article-content .article-alert .article-alert__title { margin: 0 0 5px; color: var(--text); font-size: 14px; font-weight: 650; }
.article-content .article-alert > :last-child { margin-bottom: 0; }
.article-content ul, .article-content ol { padding-left: 1.5em; margin: .8em 0; }
.article-content ul { list-style-type: disc; }
.article-content ul ul { list-style-type: circle; }
.article-content ul ul ul { list-style-type: square; }
.article-content ol { list-style-type: decimal; }
.article-content ol ol { list-style-type: lower-alpha; }
.article-content ol ol ol { list-style-type: lower-roman; }
.article-content li { padding-left: .22em; margin: .22em 0; }
.article-content li::marker { color: var(--accent); }
.article-content li > ul, .article-content li > ol { padding-left: 1.35em; margin: .28em 0; }
.article-content li > p:only-child { margin-top: 0; margin-bottom: 0; }
.article-content hr { margin: 1.8em 0; border: 0; border-top: 1px solid var(--line); }
.page-entry .article-content hr { margin: 1.65em 0; }
.article-content figure, .article-content > .wp-caption { max-width: 100%; margin: 2.3em auto; }
.article-content img { display: block; margin: auto; }
.article-content img:not(.emoji):not(.avatar) { padding: 2px; border: 1px solid var(--line); background: var(--paper); }
.article-content img:not(.emoji):not(.avatar):not(.no-lightbox) { cursor: zoom-in; }
.article-content figcaption, .article-content .wp-caption-text { margin: 10px auto 0; color: var(--muted); font: 13px/1.6 var(--sans); text-align: center; }
.article-content .article-figure { margin: 1.35em 0; }
.article-content .article-figure > p { margin: 0; }
.article-content .article-figure figcaption { font-size: 14px; overflow-wrap: anywhere; }
.article-content .alignwide { width: min(960px, calc(100vw - 48px)); max-width: none; margin-left: 50%; transform: translateX(-50%); }
.article-content .alignfull { width: 100vw; max-width: none; margin-left: 50%; transform: translateX(-50%); }
.article-table { max-width: 100%; margin: 1.35em 0; overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.article-content table { width: 100%; margin: 0; border-collapse: collapse; font: 14px/1.6 var(--sans); }
.article-content table > caption { padding: 0 0 10px; caption-side: top; color: var(--muted); font: 14px/1.6 var(--sans); text-align: left; overflow-wrap: anywhere; }
.article-content th, .article-content td { padding: 11px 13px; border: 1px solid var(--line); text-align: left; }
.article-content th { background: var(--code); font-weight: 650; }
.article-content mark { padding: 0 .12em; background: #eadc91; color: inherit; }
.article-content kbd { padding: 2px 5px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 3px; background: var(--paper); font: 13px/1 var(--mono); }
.article-content sup a { border: 0; }
.article-content iframe { max-width: 100%; }

/* Code and formula rendering */
.article-content pre, .article-content pre[class*="language-"], .article-content div.code-toolbar { max-width: 100%; min-width: 0; }
.article-content pre, .article-content .code-toolbar { position: relative; margin: 1.35em 0; }
.article-content div.code-toolbar { width: 100%; }
.article-content pre, .article-content pre[class*="language-"] { padding: 20px 22px; overflow: auto; overscroll-behavior-inline: contain; border: 1px solid color-mix(in srgb, var(--line) 92%, var(--text)); border-radius: 5px; background: var(--code-dark); box-shadow: none; color: #383a42; text-shadow: none; scrollbar-color: var(--line) transparent; scrollbar-width: thin; font: 13.5px/1.72 var(--mono); font-variant-ligatures: none; tab-size: 4; }
.article-content pre::-webkit-scrollbar { height: 7px; }
.article-content pre::-webkit-scrollbar-thumb { border: 2px solid var(--code-dark); border-radius: 999px; background: var(--line); }
.article-content pre code, .article-content code[class*="language-"] { padding: 0; border: 0; background: none; color: inherit; text-shadow: none; font-family: var(--mono); word-break: normal; }
.article-content pre[class*="language-"] > code { display: block; padding: 0 !important; border: 0 !important; background: transparent !important; background-image: none !important; box-shadow: none !important; }
.article-content pre[class*="language-"]::before, .article-content pre[class*="language-"]::after { display: none !important; }
.article-content .code-toolbar.has-code-label pre, .article-content div.code-toolbar > pre { padding-top: 48px; }
.code-language { position: absolute; top: 10px; left: 13px; z-index: 3; color: var(--muted); font: 600 13px/1.4 var(--sans); letter-spacing: .03em; }
.code-actions { position: absolute; top: 9px; right: 10px; z-index: 5; display: flex; align-items: center; gap: 8px; }
.copy-code, .wrap-code { flex: none; min-height: 26px; padding: 4px 7px; border: 1px solid transparent; border-radius: 3px; background: var(--paper); color: var(--muted); font: 12px/1.3 var(--sans); white-space: nowrap; cursor: pointer; }
.copy-code { border-color: var(--line); }
.copy-code:hover, .copy-code:focus-visible { border-color: var(--accent); color: var(--accent); outline: 0; }
.copy-code:focus-visible { box-shadow: 0 0 0 2px var(--code-dark), 0 0 0 4px color-mix(in srgb, var(--accent) 45%, transparent); }
.wrap-code:hover, .wrap-code[aria-pressed="true"] { color: var(--accent); background: var(--accent-soft); }
.wrap-code[hidden] { display: none; }
.article-content pre.code-wrap, .article-content pre.code-wrap > code { white-space: pre-wrap !important; overflow-wrap: anywhere; word-break: normal; }
.article-content div.code-toolbar > .toolbar { position: absolute; top: 9px; right: 0; left: 0; z-index: 4; display: flex; align-items: center; justify-content: space-between; padding: 0 10px; opacity: 1; pointer-events: none; }
.article-content div.code-toolbar > .toolbar > .toolbar-item { pointer-events: auto; }
.article-content div.code-toolbar > .toolbar > .toolbar-item > span, .article-content div.code-toolbar > .toolbar > .toolbar-item > button { font-size: 13px !important; }
.article-content div.code-toolbar > .toolbar > .toolbar-item > span { padding: 4px 2px; border: 0; background: transparent; box-shadow: none; color: var(--muted); font-weight: 650 !important; }
.article-content div.code-toolbar > .toolbar > .toolbar-item > button { padding: 5px 9px; border: 1px solid var(--line); border-radius: 3px; background: var(--paper); box-shadow: none; color: var(--muted); font-family: var(--sans); }
.article-content div.code-toolbar > .toolbar > .toolbar-item > button:hover, .article-content div.code-toolbar > .toolbar > .toolbar-item > button:focus-visible { border-color: var(--accent); color: var(--accent); outline: 0; }
.article-content div.code-toolbar > .toolbar > .toolbar-item > button:focus-visible { box-shadow: 0 0 0 2px var(--code-dark), 0 0 0 4px color-mix(in srgb, var(--accent) 45%, transparent); }
.article-content pre.line-numbers { position: relative; padding-left: 3.8em !important; counter-reset: linenumber; }
.article-content pre.line-numbers > code { position: relative; display: block; padding-left: 0 !important; white-space: inherit; }
.article-content .line-numbers-rows { position: absolute; top: 0; left: -3.2em; width: 2.5em; border-right: 1px solid var(--line); font-size: 100%; letter-spacing: -1px; pointer-events: none; user-select: none; }
.article-content .line-numbers-rows > span { display: block; counter-increment: linenumber; }
.article-content .line-numbers-sizer { position: absolute; top: 0; left: 0; display: block; width: 100%; visibility: hidden; pointer-events: none; }
.article-content .line-numbers-rows > span::before { content: counter(linenumber); display: block; padding-right: .8em; color: var(--muted); text-align: right; }
.article-content pre .comment, .article-content .token.comment, .article-content .token.prolog, .article-content .token.doctype, .article-content .token.cdata { color: #6f757d; font-style: italic; }
.article-content .token.punctuation { color: #5c6370; }
.article-content .token.property, .article-content .token.tag, .article-content .token.constant, .article-content .token.symbol, .article-content .token.deleted { color: #b34b42; }
.article-content .token.boolean, .article-content .token.number { color: #986801; }
.article-content .token.selector, .article-content .token.attr-name, .article-content .token.string, .article-content .token.char, .article-content .token.builtin, .article-content .token.inserted { color: #3f7f4f; }
.article-content .token.operator, .article-content .token.entity, .article-content .token.url { background: none; color: #2b7188; }
.article-content .token.atrule, .article-content .token.attr-value, .article-content .token.keyword { color: #8f3f91; }
.article-content .token.function, .article-content .token.class-name { color: #356b9a; }
.article-content .katex { font-size: 1.06em !important; }
.article-content .katex-display { margin: 1.5em 0; padding: .25em 0; overflow: auto hidden; }
.article-content mjx-container[display="true"] { margin: 1.5em 0 !important; overflow-x: auto; overflow-y: hidden; font-size: 100% !important; }
.article-content p > .katex, .article-content li > .katex, .article-content td > .katex { max-width: 100%; white-space: normal; }
.article-content p > .katex > .katex-html, .article-content li > .katex > .katex-html, .article-content td > .katex > .katex-html, .article-content p > .katex > .katex-html > .base, .article-content li > .katex > .katex-html > .base, .article-content td > .katex > .katex-html > .base { display: inline; white-space: normal; }
.article-content mjx-container:not([display="true"]) { display: inline; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }

/* Diagrams keep the article palette, with source text available on failure. */
.article-content .mermaid-figure { max-width: 100%; margin: 1.35em 0; padding: 10px 14px; border: 1px solid var(--line); border-radius: 5px; background: var(--paper); }
.mermaid-toolbar { display: flex; justify-content: flex-end; align-items: center; min-height: 30px; gap: 12px; }
.mermaid-status { margin-right: auto; color: var(--muted); font-size: 13px; }
.mermaid-expand { padding: 4px 7px; border: 0; border-radius: 3px; background: transparent; color: var(--muted); font: 13px/1.5 var(--sans); cursor: pointer; }
.mermaid-expand:hover { background: var(--accent-soft); color: var(--accent); }
.mermaid-canvas { max-width: 100%; overflow-x: auto; }
.mermaid-canvas > svg { display: block; max-width: 100%; height: auto; margin: 0 auto; }
.mermaid-source-panel { margin-top: 8px; color: var(--muted); font-size: 13px; }
.mermaid-source-panel summary { padding: 4px 0; cursor: pointer; }
.article-content .mermaid-source-panel pre { margin: 8px 0 0; padding: 12px; white-space: pre; }
.reading-dialog.diagram-dialog { width: calc(100% - 32px); max-width: 1280px; height: calc(100dvh - 32px); max-height: 1000px; padding: 12px 16px; overflow: hidden; }
.diagram-dialog .reading-dialog__header { height: 40px; margin: 0 0 8px; }
.diagram-actions { display: flex; align-items: center; gap: 4px; }
.diagram-actions button { min-width: 36px; min-height: 36px; padding: 4px 8px; border: 0; border-radius: 4px; background: none; color: var(--text-soft); font: 14px/1.4 var(--sans); cursor: pointer; }
.diagram-actions button[data-zoom="in"], .diagram-actions button[data-zoom="out"] { font-size: 22px; }
.diagram-actions .reading-dialog__close { font-size: 24px; }
.diagram-actions button:hover { background: var(--accent-soft); }
.diagram-actions button:disabled { opacity: .4; cursor: default; }
.diagram-viewport { width: 100%; height: calc(100% - 48px); overflow: auto; overscroll-behavior: contain; background: var(--paper); }
.diagram-viewport .mermaid-canvas { display: grid; place-items: center; max-width: none; overflow: visible; padding: 16px; }

/* Table of contents and article footer */
.article-toc { position: fixed; top: 142px; left: calc(50% + 300px); display: flex; flex-direction: column; gap: 7px; width: 180px; max-height: calc(100vh - 166px); overflow: hidden; color: var(--muted); font-size: 13px; line-height: 1.5; transition: opacity .16s, visibility .16s; }
.article-toc > strong { margin-bottom: 4px; color: var(--text); font-size: 13px; letter-spacing: .1em; }
.article-toc nav { display: flex; flex: 1 1 auto; flex-direction: column; gap: 8px; min-height: 0; padding-right: 8px; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.article-toc nav::-webkit-scrollbar { width: 4px; }
.article-toc nav::-webkit-scrollbar-thumb { border-radius: 999px; background: var(--line); }
.article-toc a { flex-shrink: 0; overflow: hidden; line-height: 1.65; white-space: nowrap; text-overflow: ellipsis; }
.toc-tooltip { position: fixed; z-index: 65; max-width: min(320px, calc(100vw - 32px)); padding: 8px 11px; border: 1px solid var(--line); border-radius: 4px; background: var(--paper); box-shadow: 0 6px 20px #342d2414; color: var(--text-soft); font: 14px/1.6 var(--sans); overflow-wrap: anywhere; pointer-events: none; }
.article-toc a:hover, .article-toc a.active { color: var(--accent); }
.article-toc .toc-level-3 { padding-left: 12px; color: var(--muted); }
.article-toc.is-past-article { opacity: 0; visibility: hidden; pointer-events: none; }
.admin-bar .article-toc { top: 174px; max-height: calc(100vh - 198px); }
.mobile-toc { display: none; }
.reading-toc-toggle { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: var(--paper); color: var(--muted); box-shadow: 0 7px 22px #342d2414; cursor: pointer; }
.reading-toc-toggle:hover { color: var(--accent); }
html.reading-dialog-open { overflow: hidden; }
.reading-dialog { width: min(440px, calc(100% - 32px)); max-height: calc(100dvh - 48px); padding: 18px 20px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); color: var(--text-soft); box-shadow: 0 18px 60px #26272433; }
.reading-dialog::backdrop { background: #26272455; }
.reading-dialog__header { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 12px; }
.reading-dialog__header strong { font-size: 15px; }
.reading-dialog__close { display: grid; place-items: center; flex: none; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--muted); font: 24px/1 var(--sans); cursor: pointer; }
.reading-dialog__close:hover { background: var(--accent-soft); color: var(--accent); }
.toc-dialog nav { max-height: min(560px, calc(100dvh - 150px)); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.toc-dialog nav a { display: block; padding: 9px 2px; font-size: 14px; line-height: 1.6; overflow-wrap: anywhere; }
.toc-dialog .toc-level-3 { padding-left: 16px; color: var(--muted); }
.toc-dialog a.active, .mobile-toc a.active { color: var(--accent); }
.article-license { padding: 18px 20px; margin-top: 42px; border: 1px solid var(--line); border-left: 3px solid var(--accent); background: color-mix(in srgb, var(--paper) 72%, var(--page)); color: var(--muted); font: 13px/1.65 var(--sans); }
.article-license dl { margin: 0; }
.article-license dl > div { display: grid; grid-template-columns: 68px minmax(0, 1fr); gap: 10px; }
.article-license dl > div + div { margin-top: 4px; }
.article-license dt { color: var(--text); font-weight: 600; }
.article-license dd { min-width: 0; margin: 0; overflow-wrap: anywhere; }
.article-license a { color: var(--accent); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--accent) 38%, transparent); text-underline-offset: .16em; }
.article-end { margin-top: 72px; }
.post-tags { display: flex; align-items: baseline; flex-wrap: wrap; gap: 9px; color: var(--muted); font-size: 13px; }
.post-tags a { color: var(--accent); }
.post-tags a::before { content: "#"; }
.post-navigation { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; padding-top: 28px; margin-top: 28px; border-top: 1px solid var(--line); }
.post-navigation div:last-child { text-align: right; }
.post-navigation span { display: block; color: var(--muted); font-size: 13px; }
.post-navigation a { font: 500 15px/1.5 var(--serif); }
.post-navigation a:hover { color: var(--accent); }

/* Annual reading archive */
.books-page.section-wrap { max-width: var(--layout); padding-top: 42px; }
.books-hero { display: grid; grid-template-areas: "title meta actions"; grid-template-columns: fit-content(540px) minmax(0, 340px) minmax(56px, 1fr); align-items: end; gap: 36px; margin-bottom: 34px; }
.books-hero .eyebrow { margin-bottom: 16px; }
.books-hero h1 { margin: 0; font: 680 clamp(36px, 4.25vw, 48px)/1.22 var(--sans); letter-spacing: -.035em; }
.collection-hero__title { grid-area: title; min-width: 0; }
.books-hero__meta { grid-area: meta; min-width: 0; max-width: 340px; padding-bottom: 5px; color: var(--muted); text-align: left; }
.books-hero__meta p { margin: 0; font-size: 14px; line-height: 1.65; }
.books-hero__meta .collection-stats, .photos-hero__meta .collection-stats { margin-top: 5px; font: 13px/1.55 var(--mono); font-variant-numeric: tabular-nums; }
.collection-year-actions { display: none; grid-area: actions; align-items: center; justify-content: flex-end; align-self: end; min-height: 28px; padding-bottom: 5px; }
html.js .collection-year-actions { display: flex; }
.collection-years-toggle { min-height: 28px; padding: 0 2px; border: 0; background: transparent; color: var(--muted); font: 13px/28px var(--sans); cursor: pointer; text-underline-offset: .2em; }
.collection-years-toggle:hover { color: var(--accent); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.collection-years-toggle:focus-visible { border-radius: 2px; outline: 2px solid var(--accent); outline-offset: 3px; }
.book-year-index { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); margin-bottom: 8px; border-block: 1px solid var(--line); }
.book-year-index a { display: flex; align-items: baseline; justify-content: center; gap: 8px; padding: 13px 10px; color: var(--muted); }
.book-year-index a + a { border-left: 1px solid var(--line); }
.book-year-index strong { color: var(--text-soft); font: 600 15px/1.4 var(--mono); }
.book-year-index span { font-size: 12px; }
.book-year-index a:hover, .book-year-index a:focus-visible { background: color-mix(in srgb, var(--accent-soft) 42%, transparent); color: var(--accent); outline: 0; }
.book-year-index a:hover strong, .book-year-index a:focus-visible strong { color: var(--accent); }
.book-year-shelf { display: grid; grid-template-columns: 108px minmax(0, 1fr); gap: 28px; padding: 42px 0 46px; border-bottom: 1px solid var(--line); scroll-margin-top: 88px; }
.book-year-heading { position: sticky; top: 102px; align-self: start; }
.book-year-heading h2 { margin: 0; font: 520 34px/1 var(--serif); letter-spacing: -.02em; }
.book-year-heading p { margin: 10px 0 0; color: var(--muted); font-size: 13px; }
.book-year-toggle, .photo-year__toggle { display: inline-flex; align-items: center; gap: 10px; padding: 2px 0; border: 0; background: transparent; color: inherit; font: inherit; letter-spacing: inherit; cursor: pointer; }
.book-year-toggle i, .photo-year__toggle i { width: 8px; height: 8px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: translateY(-2px) rotate(45deg); transition: transform .2s ease; }
.book-year-toggle[aria-expanded="true"] i, .photo-year__toggle[aria-expanded="true"] i { transform: translateY(2px) rotate(225deg); }
.book-year-toggle:hover, .photo-year__toggle:hover { color: var(--accent); }
.book-year-toggle:focus-visible, .photo-year__toggle:focus-visible { border-radius: 2px; outline: 2px solid var(--accent); outline-offset: 5px; }
.book-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 30px; }
html.js .book-year-shelf[data-expanded="false"] { display: block; padding: 20px 0; }
html.js .book-year-shelf[data-expanded="false"] .book-year-heading { position: static; display: flex; align-items: baseline; justify-content: space-between; }
html.js .book-year-shelf[data-expanded="false"] .book-year-heading p { margin: 0; }
html.js .book-year-shelf[data-expanded="false"] .book-grid { display: none; }
.book-item { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 16px; min-width: 0; padding-bottom: 27px; border-bottom: 1px solid var(--line); scroll-margin-top: 88px; }
.book-cover { position: relative; display: block; align-self: start; width: 84px; height: 124px; overflow: hidden; border: 1px solid var(--line); background: var(--code-dark); }
.book-cover img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; padding: 2px; background: var(--paper); object-fit: contain; }
.book-cover__fallback { display: flex; flex-direction: column; align-items: center; justify-content: space-between; width: 100%; height: 100%; padding: 20px 9px 11px; background: linear-gradient(145deg, color-mix(in srgb, var(--accent-soft) 76%, var(--paper)), var(--paper)); color: var(--accent); text-align: center; }
.book-cover.has-cover .book-cover__fallback { display: none; }
.book-cover.has-cover.is-cover-missing .book-cover__fallback { display: flex; }
.book-cover.is-cover-missing img { display: none; }
.book-recommendation { position: absolute; z-index: 2; top: -2px; right: -2px; display: block; width: 20px; height: 20px; color: #e0a11b; filter: drop-shadow(0 0 1px var(--paper)) drop-shadow(0 1px 1px rgb(38 39 36 / 32%)); }
.book-recommendation .quietype-icon { width: 20px; height: 20px; fill: currentColor; stroke: #76501c; stroke-width: 1.25; }
.book-cover i { font: 600 17px/1.55 var(--serif); font-style: normal; letter-spacing: .03em; }
.book-cover small { max-width: 100%; overflow: hidden; color: var(--muted); font-size: 11px; line-height: 1.45; text-overflow: ellipsis; }
.book-body { display: flex; min-width: 0; flex-direction: column; }
.book-title-row { min-width: 0; }
.book-title-row h3 { min-width: 0; margin: 0; font: 620 18px/1.4 var(--serif); }
.book-title-row h3 a:hover { color: var(--accent); }
.douban-rating { display: inline-flex; align-items: baseline; flex: none; gap: 4px; font-size: 11px; line-height: 1.4; white-space: nowrap; }
.douban-rating small { color: var(--muted); font-size: 11px; }
.douban-rating strong { color: var(--accent); font: 600 12px/1.4 var(--mono); }
.book-meta { margin: 4px 0 0; overflow: hidden; color: var(--muted); font-size: 12px; line-height: 1.45; text-overflow: ellipsis; white-space: nowrap; }
.book-terms { display: flex; align-items: center; flex-wrap: wrap; gap: 5px 9px; margin-top: 5px; font-size: 12px; line-height: 1.4; }
.book-terms .post-category, .book-terms .post-tag { font-size: inherit; }
.book-evaluation { min-height: 17px; margin-top: 6px; }
.book-evaluation__summary { display: flex; align-items: baseline; flex-wrap: wrap; min-width: 0; row-gap: 5px; }
.book-evaluation__summary > * + *::before { content: "·"; margin: 0 4px; color: var(--faint); }
.book-status { color: var(--accent); font-size: 12px; line-height: 1.4; white-space: nowrap; }
.personal-rating { display: inline-flex; align-items: baseline; color: var(--muted); font-size: 12px; line-height: 1.4; white-space: nowrap; }
.personal-rating__stars { display: inline-flex; align-items: baseline; gap: 1px; }
.personal-rating__star { color: var(--line); font: 12px/1.4 var(--serif); font-style: normal; }
.personal-rating__star.is-full { color: var(--accent); }
.book-read-date { color: var(--muted); font: 12px/1.4 var(--mono); }
.book-note { display: -webkit-box; margin: 6px 0 0; overflow: hidden; color: var(--text-soft); font-size: 13px; line-height: 1.6; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }

/* Annual photo archive */
.photos-page.section-wrap { max-width: var(--layout); padding-top: 42px; }
.photos-hero { display: grid; grid-template-areas: "title meta actions"; grid-template-columns: fit-content(540px) minmax(0, 340px) minmax(56px, 1fr); align-items: end; gap: 36px; margin-bottom: 34px; }
.photos-hero .eyebrow { margin-bottom: 16px; }
.photos-hero h1 { margin: 0; font: 680 clamp(36px, 4.25vw, 48px)/1.22 var(--sans); letter-spacing: -.035em; }
.photos-hero__meta { grid-area: meta; min-width: 0; max-width: 340px; padding-bottom: 5px; color: var(--muted); text-align: left; }
.photos-hero__meta p { margin: 0; font-size: 14px; line-height: 1.65; }
.photo-year-index { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); margin-bottom: 8px; border-block: 1px solid var(--line); }
.photo-year-index a { display: flex; align-items: baseline; justify-content: center; gap: 8px; padding: 13px 10px; color: var(--muted); }
.photo-year-index a + a { border-left: 1px solid var(--line); }
.photo-year-index strong { color: var(--text-soft); font: 600 15px/1.4 var(--mono); }
.photo-year-index span { font-size: 12px; }
.photo-year-index a:hover, .photo-year-index a:focus-visible { background: color-mix(in srgb, var(--accent-soft) 42%, transparent); color: var(--accent); outline: 0; }
.photo-year-index a:hover strong, .photo-year-index a:focus-visible strong { color: var(--accent); }
.photo-year { display: grid; grid-template-columns: 108px minmax(0, 1fr); gap: 28px; padding: 42px 0 46px; border-bottom: 1px solid var(--line); scroll-margin-top: 88px; }
.photo-year__heading { position: sticky; top: 102px; align-self: start; }
.photo-year__heading h2 { margin: 0; font: 520 34px/1 var(--serif); letter-spacing: -.02em; }
.photo-year__heading p { margin: 10px 0 0; color: var(--muted); font-size: 13px; }
.photo-grid { display: grid; grid-auto-flow: dense; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 28px 10px; min-width: 0; }
html.js .photo-year[data-expanded="false"] { display: block; padding: 20px 0; }
html.js .photo-year[data-expanded="false"] .photo-year__heading { position: static; display: flex; align-items: baseline; justify-content: space-between; }
html.js .photo-year[data-expanded="false"] .photo-year__heading p { margin: 0; }
html.js .photo-year[data-expanded="false"] .photo-grid { display: none; }
.photo-card { min-width: 0; margin: 0; grid-column: span 6; scroll-margin-top: 88px; }
.photo-card--wide { grid-column: span 8; }
.photo-card--narrow, .photo-card--square { grid-column: span 4; }
.photo-frame { position: relative; display: block; overflow: hidden; border: 1px solid var(--line); background: color-mix(in srgb, var(--line) 44%, var(--paper)); aspect-ratio: 3 / 2; cursor: zoom-in; }
.photo-card--wide .photo-frame { aspect-ratio: 8 / 5; }
.photo-card--narrow .photo-frame { aspect-ratio: 4 / 5; }
.photo-card--square .photo-frame { aspect-ratio: 1; }
.photo-frame::after { position: absolute; inset: 0; border: 1px solid rgba(255, 255, 255, .12); pointer-events: none; content: ""; }
.photo-frame img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease, opacity .2s ease; }
.js .photo-frame img[data-photo-deferred]:not(.is-photo-loaded) { opacity: 0; }
html:not(.js) .photo-frame img[data-photo-deferred] { display: none; }
.photo-frame.is-photo-error::before { position: absolute; inset: 0; display: grid; place-items: center; color: var(--faint); font-size: 13px; content: "照片暂未载入"; }
.photo-frame:hover img { transform: scale(1.012); }
.photo-caption { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding-top: 9px; }
.photo-caption strong { overflow: hidden; color: var(--text-soft); font: 560 15px/1.45 var(--serif); text-overflow: ellipsis; white-space: nowrap; }
.photo-caption small { flex: none; color: var(--muted); font: 11px/1.4 var(--mono); white-space: nowrap; }

/* Archives */
.archive-tags { padding: 20px 0 22px; margin: 0 0 40px; border-block: 1px solid var(--line); }
.archive-tags__heading { display: flex; align-items: baseline; flex-wrap: wrap; gap: 10px; margin-bottom: 17px; }
.archive-tags__heading h2 { margin: 0; font-size: 19px; }
.archive-tags__heading span { color: var(--muted); font-size: 13px; white-space: nowrap; }
.archive-tags__list { display: grid; grid-template-columns: repeat(auto-fill, minmax(138px, 1fr)); gap: 8px; }
.archive-tags__list a { display: inline-flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; min-width: 0; padding: 6px 10px; border: 1px solid var(--line); border-radius: 4px; background: color-mix(in srgb, var(--paper) 65%, transparent); font-size: 14px; }
.archive-tags__list a:hover { border-color: var(--accent); color: var(--accent); }
.archive-tags__list a > span { display: flex; align-items: baseline; gap: 3px; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.archive-tags__list i { color: var(--accent); font-family: var(--mono); font-size: .92em; font-style: normal; font-weight: 650; }
.archive-tags__list small { min-width: 1.3em; color: var(--muted); font-size: 13px; text-align: right; }
.archive-year { display: grid; grid-template-columns: 125px 1fr; margin-bottom: 52px; }
.archive-year h2 { margin: 12px 0; font: 500 30px/1 var(--serif); }
.archive-year h2 sup { margin-left: 5px; color: var(--muted); font: 13px/1 var(--sans); }
.archive-year ol { padding: 0; margin: 0; list-style: none; }
.archive-year li { display: grid; grid-template-columns: 64px minmax(0, 1fr) minmax(230px, auto); align-items: baseline; gap: 18px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.archive-year time { color: var(--muted); font-size: 13px; }
.archive-year li > a { font-family: var(--serif); }
.archive-year li > a:hover { color: var(--accent); }
.archive-details { display: flex; align-items: center; justify-content: flex-end; gap: 12px; }
.archive-terms { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 7px; min-width: 0; }
.archive-terms .post-category, .archive-terms .post-tag { color: var(--muted); }
.archive-views { flex: none; color: var(--muted); font-size: 13px; white-space: nowrap; }
.archive-views::before { content: "·"; margin-right: 12px; color: var(--line); }

/* Friend links, search and errors */
.link-groups { display: block; }
.link-group { min-width: 0; }
.link-group + .link-group { margin-top: 38px; }
.link-group__header { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; padding: 0 1px; margin: 0 0 13px; }
.link-group__header h2 { margin: 0; color: var(--text); font: 650 18px/1.4 var(--serif); letter-spacing: .02em; }
.link-group__count { display: inline-flex; flex-shrink: 0; align-items: center; justify-content: center; min-width: 24px; height: 24px; padding-inline: 5px; border-radius: 999px; background: var(--accent-soft); color: var(--text-soft); font: 13px/1 var(--sans); font-variant-numeric: tabular-nums; }
.link-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; background: transparent; }
.link-grid > a { display: block; padding: 27px; border: 1px solid var(--line); background: var(--paper); }
.link-grid > a:hover strong { color: var(--accent); }
.link-grid strong { display: block; font: 600 18px/1.5 var(--serif); }
.link-grid span { display: block; margin-top: 7px; color: var(--muted); font-size: 13px; }
.link-card { position: relative; min-width: 0; }
.link-card.is-offline { padding-right: 72px; }
.link-card.is-offline strong, .link-card.is-offline .link-card__description { color: var(--muted); }
.link-grid .link-card__status { position: absolute; top: 15px; right: 16px; display: inline-block; padding: 2px 7px; margin: 0; border: 1px solid var(--line); border-radius: 999px; background: var(--page); color: var(--muted); font: 600 11px/1.45 var(--sans); letter-spacing: .06em; }
.link-card.is-offline:hover .link-card__status { border-color: color-mix(in srgb, var(--accent) 40%, var(--line)); color: var(--accent); }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 9px; }
.tag-cloud a { padding: 7px 12px !important; border: 1px solid var(--line); background: var(--paper); }
.tag-cloud a:hover { border-color: var(--accent); color: var(--accent); }
.not-found { max-width: 760px; }
.not-found h1 { margin: 14px 0 24px; font: 600 clamp(40px, 7vw, 70px)/1.2 var(--serif); }
.not-found > p:not(.eyebrow):not(.not-found__links) { max-width: 680px; color: var(--muted); }
.not-found .search-form { max-width: 500px; margin: 44px 0 28px; }
.not-found__links { display: flex; gap: 24px; }
.not-found__links a { color: var(--accent); }

/* Comments */
.comments-area { padding-top: 42px; margin-top: 64px; border-top: 1px solid var(--line); }
.comments-title, .comment-reply-title { margin: 0 0 26px; font: 650 22px/1.4 var(--sans); letter-spacing: -.01em; }
.comment-list { padding: 0; margin: 0 0 54px; list-style: none; }
.comment-list > .comment { border-bottom: 1px solid var(--line); }
.comment-body { position: relative; padding: 25px 0; border-bottom: 1px solid var(--line); }
.comment-list > .comment > .comment-body { border-bottom: 0; }
.comment-author { display: flex; align-items: center; gap: 11px; font-size: 15px; }
.comment-author img { width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 50%; }
.comment-author .says { display: none; }
.comment-author .fn { font-style: normal; font-weight: 650; }
.comment-author .fn a:hover, .comment-metadata a:hover { color: var(--accent); }
.comment-metadata { margin: 5px 0 10px 51px; color: var(--muted); font-size: 13px !important; }
.comment-content { margin-left: 51px; color: var(--text-soft); font: 15px/1.75 var(--sans); }
.comment-content p { margin: .55em 0; }
.reply { margin: 10px 0 0 51px; font-size: 13px !important; }
.reply a { color: var(--accent); }
.comment-list .children { padding: 0 0 0 22px; margin: 0 0 0 24px; border-left: 2px solid #c9b8aa; list-style: none; }
.comment-list .children .comment { padding: 0; border: 0 !important; background: transparent !important; box-shadow: none !important; }
.comment-list .children .comment-body { padding: 19px 0; border: 0; }
.comment-list .children .comment + .comment { border-top: 1px solid var(--line) !important; }
.comment-list .children .children { padding-left: 18px; margin-left: 18px; }
.comment-respond { margin-top: 46px; }
.comment-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.comment-form > p { margin: 0 0 17px; }
.comment-form-comment, .comment-notes, .logged-in-as, .comment-form-cookies-consent, .form-submit { grid-column: 1 / -1; }
.comment-form-author, .comment-form-email, .comment-form-url { display: block; width: 100%; margin-right: 0; }
.comment-form-url, .comment-form-captcha { grid-column: auto; }
.comment-form label { display: block; margin-bottom: 6px; color: var(--text-soft); font-size: 14px !important; font-weight: 550; }
.comment-form input:not([type="submit"]):not([type="checkbox"]), .comment-form textarea { width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 4px; background: var(--paper); font-size: 15px; line-height: 1.6; outline: 0; transition: border-color .15s, box-shadow .15s; }
.comment-form textarea { height: 112px; min-height: 112px; resize: vertical; }
.comment-form input:focus, .comment-form textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 10%, transparent); }
.comment-form-cookies-consent { display: flex; align-items: flex-start; gap: 8px; color: var(--muted); font-size: 14px; }
.comment-form-cookies-consent input { margin-top: 6px; }
.comment-form-cookies-consent label { font-weight: 400; }
.form-submit input { padding: 10px 20px; border: 0; border-radius: 4px; background: var(--text); color: var(--paper); font-size: 14px; font-weight: 600; cursor: pointer; }
.form-submit input:hover { background: var(--accent); }
.comment-captcha-code { display: inline-block; margin-left: 3px; color: var(--accent); font-family: var(--mono); font-size: .95em; font-weight: 700; letter-spacing: .08em; font-variant-numeric: tabular-nums; }
.comment-form-captcha input { font-variant-numeric: tabular-nums; }
.quietype-comment-honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }
.comments-area .pagination { justify-content: flex-start; margin-top: 25px; }
.comments-pagination { margin: 28px 0 46px; }
.comments-pagination .nav-links { display: flex; align-items: center; flex-wrap: wrap; gap: 5px; }
.comments-pagination .page-numbers { display: grid; place-items: center; min-width: 32px; height: 32px; padding: 0 8px; border: 1px solid transparent; color: var(--muted); font-size: 13px; }
.comments-pagination .current { border-color: var(--line); background: var(--paper); color: var(--text); }
.comments-pagination a:hover { color: var(--accent); }

/* Footer and reading tools */
.prefooter-nav { border-top: 1px solid var(--line); }
.prefooter-nav__inner { display: flex; align-items: center; justify-content: center; min-height: 54px; }
.prefooter-nav__menu { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; padding: 0; margin: 0; list-style: none; }
.prefooter-nav__menu li { display: flex; align-items: center; }
.prefooter-nav__menu li + li::before { content: "·"; margin: 0 13px; color: var(--faint); }
.prefooter-nav__menu a { display: grid; min-height: 36px; place-items: center; color: var(--muted); font-size: 15px; line-height: 1.5; }
.prefooter-nav__menu a:hover, .prefooter-nav__menu a:focus-visible, .prefooter-nav__menu .current-menu-item > a { color: var(--accent); }
.site-footer { border-top: 1px solid var(--line); }
.site-footer__inner { position: relative; display: flex; align-items: center; justify-content: space-between; min-height: 72px; padding: 0; color: var(--muted); font-size: 14px; }
.site-footer a:hover { color: var(--accent); }
.footer-legal { display: flex; align-items: center; justify-content: space-between; gap: 20px; width: 100%; }
.footer-policies { display: flex; align-items: center; gap: 14px; margin-left: auto; }
.footer-contact { position: absolute; left: 50%; display: flex; align-items: center; gap: 5px; transform: translateX(-50%); }
.footer-contact a { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; color: var(--muted); }
.footer-contact a:hover, .footer-contact a:focus-visible { background: var(--accent-soft); color: var(--accent); outline: 0; }
.footer-contact .quietype-icon { width: 18px; height: 18px; }
.reading-tools { position: fixed; right: 22px; bottom: calc(22px + var(--footer-overlap, 0px)); z-index: 30; display: flex; flex-direction: column; align-items: center; gap: 7px; transition: bottom .12s ease; }
.reading-tools__navigation[hidden] { display: none !important; }
.reading-tools__navigation { display: flex; flex-direction: column; width: 36px; padding: 0; border: 1px solid var(--line); border-radius: 999px; background: color-mix(in srgb, var(--paper) 94%, transparent); box-shadow: 0 7px 22px #342d2414; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.reading-tools__navigation .tool-button { width: 34px; height: 34px; border-radius: 50%; background: transparent; }
.reading-tools__navigation .tool-button + .tool-button:not([hidden]) { border-top: 0; border-radius: 50%; }
.reading-tools__navigation.has-both .top-button { border-bottom-right-radius: 0; border-bottom-left-radius: 0; }
.reading-tools__navigation.has-both .bottom-button { border-top: 1px solid var(--line); border-top-left-radius: 0; border-top-right-radius: 0; }
.top-button { display: none; }
.top-button:not([hidden]) { display: grid; }
.tool-button[hidden] { display: none !important; }
.reading-background { position: relative; }
.reading-background__toggle { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: color-mix(in srgb, var(--paper) 94%, transparent); color: var(--muted); box-shadow: 0 7px 22px #342d2414; cursor: pointer; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.reading-background__toggle:hover { border-color: color-mix(in srgb, var(--accent) 35%, var(--line)); color: var(--accent); }
.reading-background__options { position: absolute; right: 48px; bottom: -42px; width: 208px; padding: 14px; border: 1px solid var(--line); border-radius: 7px; background: var(--paper); box-shadow: 0 14px 38px #342d241c; }
.reading-background__options > span { display: block; margin-bottom: 8px; color: var(--muted); font-size: 13px; letter-spacing: .08em; }
.reading-background__options button { display: grid; grid-template-columns: 22px 1fr auto; align-items: center; gap: 9px; width: 100%; padding: 9px 7px; border: 0; border-radius: 4px; background: none; color: var(--muted); font-size: 14px; text-align: left; cursor: pointer; }
.reading-background__options button:hover, .reading-background__options button.active { background: var(--accent-soft); color: var(--accent); }
.reading-background__options i { width: 20px; height: 20px; border: 1px solid #00000014; border-radius: 50%; background: #fdfdfb; }
.reading-background__options [data-reading-bg="warm"] i { background: #fbf6e9; }
.reading-background__options [data-reading-bg="green"] i { background: #f2f7ef; }
.reading-background__options b { font-weight: 600; }
.reading-background__options small { color: var(--muted); font-size: 13px; }

/* PhotoSwipe */
.pswp { --pswp-bg: #191816; --pswp-icon-color: #fff; --pswp-icon-color-secondary: #191816; }
.pswp__top-bar { background: linear-gradient(180deg, rgba(25, 24, 22, .72), rgba(25, 24, 22, 0)); }
.pswp__button--quietype-zoom { color: var(--pswp-icon-color); }
.pswp__button--quietype-zoom svg { display: block; width: 24px; height: 24px; margin: auto; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.pswp__quietype-caption { position: absolute; z-index: 10; right: 72px; bottom: 20px; left: 72px; display: flex; justify-content: center; color: rgba(255, 255, 255, .86); pointer-events: none !important; }
.pswp__quietype-caption[hidden] { display: none; }
.pswp__quietype-caption-inner { max-width: min(720px, 100%); text-align: center; text-shadow: 0 1px 2px rgba(0, 0, 0, .45); }
.pswp__quietype-caption-inner > div { display: flex; align-items: baseline; justify-content: center; flex-wrap: wrap; gap: 5px 12px; }
.pswp__quietype-caption strong { font: 560 15px/1.45 var(--serif); }
.pswp__quietype-caption span, .pswp__quietype-caption small { color: rgba(255, 255, 255, .62); font-size: 12px; }
.pswp__quietype-caption p { margin: 4px 0 0; font-size: 13px; line-height: 1.5; }
.pswp__quietype-caption small { display: block; margin-top: 4px; font-family: var(--mono); }
.pswp__quietype-caption a { display: inline-block; margin-top: 6px; color: rgba(255, 255, 255, .76); font-size: 12px; pointer-events: auto; text-decoration: underline; text-decoration-color: rgba(255, 255, 255, .34); text-underline-offset: 3px; }
.pswp__quietype-caption a[hidden] { display: none; }
.pswp__quietype-caption a:hover, .pswp__quietype-caption a:focus-visible { color: #fff; text-decoration-color: currentColor; }

/* Tablet and compact desktop */
@media (max-width: 1380px) {
	.article-toc { display: none; }
	.mobile-toc { display: block; margin-top: -32px; margin-bottom: 44px; border-bottom: 1px solid var(--line); }
	.mobile-toc summary { padding: 12px 0; color: var(--muted); font-size: 13px; list-style: none; cursor: pointer; }
	.mobile-toc summary::-webkit-details-marker { display: none; }
	.mobile-toc summary::after { content: "＋"; float: right; }
	.mobile-toc[open] summary::after { content: "－"; }
	.mobile-toc nav { display: flex; flex-direction: column; gap: 8px; padding: 0 0 14px; font-size: 13px; }
	.mobile-toc .toc-level-3 { padding-left: 14px; color: var(--muted); }
}

@media (min-width: 1381px) {
	.single-post .article--with-toc > .content-width { max-width: 760px; margin-right: 0; margin-left: calc(50% - 480px); }
}

/* Mobile */
@media (max-width: 720px) {
	:root { --anchor-offset: 80px; }
	html, body { max-width: 100%; overflow-x: hidden; }
	@supports (overflow: clip) { html, body { overflow-x: clip; } }
	body { font-size: 16px; }
	html.nav-open { overflow: hidden; overscroll-behavior: none; }
	.site-header { background: var(--page); backdrop-filter: none; -webkit-backdrop-filter: none; }
	.site-header__inner, .site-footer__inner, .prefooter-nav__inner, .section-wrap, .content-width { width: calc(100% - 32px); }
	.site-header__inner { height: 64px; }
	.site-brand__wordmark { font-size: 20px; }
	.mobile-header-actions { position: relative; z-index: 46; display: flex; gap: 2px; }
	.mobile-header-actions .icon-button { display: grid; width: 38px; height: 38px; }
	.mobile-header-actions .icon-button:not([data-label])::after, .search-toggle--mobile::after { content: none; display: none; }
	.nav-toggle { position: relative; z-index: 46; display: block; margin: 0; }
	.site-nav { position: fixed; top: 64px; right: 0; bottom: 0; z-index: 45; display: block; width: 50vw; min-width: 0; max-width: 220px; padding: 12px 14px calc(24px + env(safe-area-inset-bottom)); border: 0; border-left: 1px solid var(--line); background: var(--paper); box-shadow: -16px 0 40px #302b2118; overflow: auto; overscroll-behavior: contain; transform: translateX(105%); transition: transform .2s ease; }
	.site-nav.open { transform: translateX(0); }
	.site-nav .menu { display: block; }
	.site-nav .menu > li { padding: 2px 0; border-bottom: 1px solid var(--line); }
	.site-nav a { display: block; min-height: 44px; padding: 11px 4px; font-size: 15px; line-height: 1.45; white-space: normal; }
	.site-nav .sub-menu { position: static; display: block; width: auto; padding: 0 0 8px 14px; border: 0; background: transparent; box-shadow: none; }
	.site-nav .sub-menu a { min-height: 38px; padding: 8px 3px; font-size: 14px; }
	.site-nav .search-toggle--desktop { display: none; }
	.site-nav .menu > .menu-item-has-children > a { padding-right: 44px; }
	.js .site-nav .sub-menu, .js .site-nav .menu-item-has-children:not(.submenu-open) > .sub-menu { display: none !important; }
	.js .site-nav .submenu-open > .sub-menu { display: block !important; }
	.js .submenu-toggle { position: absolute; top: 5px; right: 0; display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--muted); font-size: 18px; line-height: 1; cursor: pointer; }
	.submenu-toggle:hover, .submenu-toggle:focus-visible { background: var(--accent-soft); color: var(--accent); outline: 0; }
	.nav-backdrop:not([hidden]) { position: fixed; inset: 64px 0 0; z-index: 44; display: block; border: 0; background: #2928222b; backdrop-filter: blur(2px); }
	body.nav-open .reading-tools { opacity: 0; visibility: hidden; pointer-events: none; }
	.site-search { top: calc(100% + 8px); right: 16px; }
	.section-wrap { padding-top: 52px; padding-bottom: 36px; }
	.post-index--home { padding-top: 30px; }
	.page-entry.section-wrap, .archive-index.section-wrap, .archive-page.section-wrap, .links-page.section-wrap, .tags-page.section-wrap { padding-top: 30px; }
	.site-main .page-hero { margin-bottom: 20px; }
	.page-hero h1 { font-size: 34px; }
	.page-entry > .content-width { width: 100%; }
	.section-title { padding-bottom: 10px; }
	.post-row { padding: 19px 0; }
	.post-row h2 { margin-bottom: 5px; font-size: 17px; line-height: 1.55; }
	.post-row__excerpt { display: -webkit-box; overflow: hidden; font-size: 14px; line-height: 1.65; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
	.post-row__meta { align-items: center; flex-wrap: wrap; gap: 5px 8px; margin-top: 8px; }
	.post-row__date::after { margin-left: 7px; }
	.post-row__terms { width: auto; order: initial; gap: 6px; }
	.post-row__views { display: none; }
	.post-index .pagination { margin-top: 36px; }
	.site-main, .article, .article-header, .article-content, .article-end, .comments-area { min-width: 0; max-width: 100%; }
	.article { padding-top: 42px; }
	.article-header { padding-bottom: 23px; margin-bottom: 26px; }
	.article-header h1 { margin-bottom: 16px; font-size: 30px; line-height: 1.35; }
	.article-terms { margin-bottom: 11px; }
	.article-meta { display: grid; gap: 3px; }
	.article-meta__group { display: flex; width: 100%; line-height: 1.7; }
	.article-meta > .article-meta__group + *::before { content: none; display: none !important; }
	.article-meta__group > * { display: inline; }
	.article-meta__group > * + *::before { display: inline-block !important; margin: 0 7px; }
	.article-content { font-size: 16px; line-height: 1.78; }
	.article-content > p:first-child { font-size: 16px; }
	.article-content p { margin: .78em 0; }
	.article-content h2 { margin-top: 1.45em; font-size: 21px; }
	.article-content h3 { margin-top: 1.25em; font-size: 18px; }
	.article-content h4 { margin-top: 1.15em; font-size: 16px; }
	.article-content hr, .page-entry .article-content hr { margin: 1.55em 0; }
	.article-content pre, .article-content pre[class*="language-"], .article-content .code-toolbar { width: 100%; max-width: 100%; margin-right: 0 !important; margin-left: 0 !important; border-radius: 4px; }
	.article-content pre, .article-content pre[class*="language-"] { padding: 18px 14px 18px 16px; font-size: 13px; }
	.article-content .alignwide, .article-content .alignfull { width: 100%; max-width: 100%; margin-left: 0; transform: none; }
	.article-content table { width: 100%; max-width: 100%; margin-left: 0; }
	.article-content iframe, .article-content video, .article-content svg { max-width: 100%; }
	.article-license { padding: 15px 16px; margin-top: 32px; font-size: 12px; }
	.article-license dl > div { grid-template-columns: 64px minmax(0, 1fr); gap: 7px; }
	.post-navigation { grid-template-columns: 1fr; }
	.post-navigation div:last-child { text-align: left; }
	.archive-tags__list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
	.archive-year { grid-template-columns: 1fr; }
	.archive-year h2 { margin-bottom: 16px; }
	.archive-year li { grid-template-columns: 48px minmax(0, 1fr); gap: 12px; }
	.archive-year li > span.archive-details { display: flex; grid-column: 2; align-items: flex-start; justify-content: space-between; gap: 8px; margin-top: -5px; }
	.archive-details .archive-terms { justify-content: flex-start; }
	.archive-views::before { display: none; }
	.link-grid { grid-template-columns: 1fr; }
	.books-page.section-wrap { padding-top: 30px; }
	.books-hero { display: grid; grid-template-areas: "title title" "meta actions"; grid-template-columns: minmax(0, 1fr) auto; gap: 0 16px; margin-bottom: 25px; }
	.books-hero .eyebrow { margin-bottom: 13px; }
	.books-hero h1 { font-size: 34px; line-height: 1.28; }
	.books-hero__meta { max-width: none; padding: 0; margin-top: 14px; text-align: left; }
	.collection-year-actions { min-height: 32px; padding-bottom: 0; }
	.collection-years-toggle { min-height: 32px; font-size: 13px; line-height: 32px; }
	.book-year-index { grid-template-columns: repeat(6, minmax(0, 1fr)); margin-bottom: 2px; border-bottom: 0; }
	.book-year-index a { grid-column: span 2; flex-direction: column; align-items: center; gap: 1px; padding: 10px 4px; border-bottom: 1px solid var(--line); }
	.book-year-index a:nth-child(3n + 1) { border-left: 0; }
	.book-year-index--count-1 a { grid-column: 1 / -1; }
	.book-year-index--count-2 a, .book-year-index--count-4 a { grid-column: span 3; }
	.book-year-index--count-4 a:nth-child(odd) { border-left: 0; }
	.book-year-index--count-4 a:nth-child(even) { border-left: 1px solid var(--line); }
	.book-year-index--remainder-2 a:nth-last-child(-n + 2) { grid-column: span 3; }
	.book-year-index strong { font-size: 14px; }
	.book-year-shelf { display: block; padding: 32px 0 36px; scroll-margin-top: 76px; }
	.book-year-heading { position: static; display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 22px; }
	.book-year-heading h2 { font-size: 29px; }
	.book-year-heading p { margin: 0; }
	html.js .book-year-shelf[data-expanded="false"] { padding: 18px 0; }
	.book-grid { grid-template-columns: 1fr; gap: 22px; }
	.book-item { grid-template-columns: 76px minmax(0, 1fr); gap: 14px; padding-bottom: 22px; }
	.book-item, .photo-card { scroll-margin-top: 76px; }
	.book-cover { width: 76px; height: 112px; }
	.book-title-row h3 { font-size: 17px; }
	.book-terms { margin-top: 5px; }
	.book-note { margin-top: 6px; font-size: 13px; -webkit-line-clamp: 2; }
	.book-evaluation { margin-top: 6px; }
	.link-group + .link-group { margin-top: 30px; }
	.link-group__header { margin-bottom: 11px; }
	.link-group__header h2 { font-size: 17px; }
	.comments-area { padding-top: 34px; margin-top: 52px; }
	.comment-content, .comment-metadata, .reply { margin-left: 0; }
	.comment-list .children { padding-left: 14px; margin-left: 12px; }
	.comment-list .children .children { padding-left: 12px; margin-left: 10px; }
	.comment-form { grid-template-columns: 1fr; }
	.comment-form > p, .comment-form-url, .comment-form-captcha { grid-column: 1; }
	.comment-form textarea { height: 108px; min-height: 108px; }
	.site-footer__inner { display: flex; flex-direction: column; justify-content: center; gap: 4px; min-height: 0; padding: 12px 0 14px; text-align: center; line-height: 1.5; }
	.prefooter-nav__inner { min-height: 50px; }
	.prefooter-nav__menu li + li::before { margin: 0 9px; }
	.prefooter-nav__menu a { min-height: 34px; font-size: 14px; }
	.footer-legal { justify-content: center; flex-wrap: wrap; gap: 3px 10px; white-space: nowrap; }
	.footer-policies { justify-content: center; gap: 10px; margin-left: 0; }
	.footer-contact { position: static; order: -1; gap: 6px; margin: 0; transform: none; }
	.footer-contact a { width: 30px; height: 30px; }
	.reading-tools { right: max(18px, calc(env(safe-area-inset-right) + 12px)); bottom: calc(18px + env(safe-area-inset-bottom) + var(--footer-overlap, 0px)); }
	.reading-background__options { right: 45px; }
}

@media (max-width: 340px) {
	.book-evaluation__summary .douban-rating::before { content: none; }
	.book-evaluation__summary .douban-rating { margin-left: 8px; }
}

@media (max-width: 720px) {
	.photos-page.section-wrap { padding-top: 30px; }
	.photos-hero { display: grid; grid-template-areas: "title title" "meta actions"; grid-template-columns: minmax(0, 1fr) auto; gap: 0 16px; margin-bottom: 25px; }
	.photos-hero .eyebrow { margin-bottom: 13px; }
	.photos-hero h1 { font-size: 34px; line-height: 1.28; }
	.photos-hero__meta { max-width: none; padding: 0; margin-top: 14px; text-align: left; }
	.photo-year-index { grid-template-columns: repeat(6, minmax(0, 1fr)); margin-bottom: 2px; border-bottom: 0; }
	.photo-year-index a { grid-column: span 2; flex-direction: column; align-items: center; gap: 1px; padding: 10px 4px; border-bottom: 1px solid var(--line); }
	.photo-year-index a:nth-child(3n + 1) { border-left: 0; }
	.photo-year-index--count-1 a { grid-column: 1 / -1; }
	.photo-year-index--count-2 a, .photo-year-index--count-4 a { grid-column: span 3; }
	.photo-year-index--count-4 a:nth-child(odd) { border-left: 0; }
	.photo-year-index--count-4 a:nth-child(even) { border-left: 1px solid var(--line); }
	.photo-year-index--remainder-2 a:nth-last-child(-n + 2) { grid-column: span 3; }
	.photo-year-index strong { font-size: 14px; }
	.photo-year { display: block; padding: 32px 0 36px; scroll-margin-top: 76px; }
	.photo-year__heading { position: static; display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 22px; }
	.photo-year__heading h2 { font-size: 29px; }
	.photo-year__heading p { margin: 0; }
	html.js .photo-year[data-expanded="false"] { padding: 18px 0; }
	.photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 8px; }
	.photo-card, .photo-card--wide, .photo-card--narrow, .photo-card--square { grid-column: span 1; }
	.photo-grid--odd .photo-card--lead { grid-column: 1 / -1; }
	.photo-card .photo-frame { aspect-ratio: 1; }
	.photo-grid--odd .photo-card--lead .photo-frame { aspect-ratio: 16 / 10; }
	.photo-caption { display: block; padding-top: 7px; }
	.photo-caption strong { display: block; font-size: 14px; }
	.photo-caption small { display: block; margin-top: 2px; font-size: 10px; }
	.pswp__quietype-caption { right: 24px; bottom: calc(14px + env(safe-area-inset-bottom)); left: 24px; }
	.pswp__quietype-caption-inner > div { gap: 3px 8px; }
	.pswp__quietype-caption p { margin-top: 3px; font-size: 12px; line-height: 1.45; }
	.pswp__quietype-caption small { margin-top: 3px; font-size: 10.5px; line-height: 1.45; }
	.pswp--touch .pswp__button--arrow { visibility: visible; width: 48px; height: 64px; margin-top: -32px; opacity: 0; }
	.pswp--touch.pswp--ui-visible .pswp__button--arrow { opacity: .82; }
	.pswp--touch .pswp__button--arrow::before { position: absolute; top: 50%; left: 50%; width: 42px; height: 42px; border-radius: 50%; background: rgba(25, 24, 22, .42); transform: translate(-50%, -50%); backdrop-filter: blur(5px); pointer-events: none; content: ""; }
	.pswp--touch .pswp__button--arrow .pswp__icn { top: 50%; right: auto; left: calc(50% + 4.2px); box-sizing: border-box; width: 42px; height: 42px; margin-top: -21px; padding: 9px; background: none; transform: translateX(-50%); }
	.pswp--touch .pswp__button--arrow--next .pswp__icn { right: auto; left: calc(50% - 4.2px); transform: translateX(-50%) scale(-1, 1); }
	.pswp--touch .pswp__button--arrow--prev { left: calc(2px + env(safe-area-inset-left)); }
	.pswp--touch .pswp__button--arrow--next { right: calc(2px + env(safe-area-inset-right)); }
}

@media (hover: none) {
	.reading-toc-toggle[data-label]::after { display: none; }
	.icon-button:hover, .tool-button:hover { background: transparent; color: var(--muted); }
	.heading-permalink { opacity: .48; }
	.reading-background__toggle:hover { border-color: var(--line); background: color-mix(in srgb, var(--paper) 94%, transparent); color: var(--muted); }
	.reading-background__options button:hover:not(.active) { background: transparent; color: var(--muted); }
}

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	body { transition: none; }
	.photo-frame img { transition: none; }
}

@media print {
	.reading-dialog, .toc-tooltip, .wrap-code, .copy-code, .mermaid-toolbar, .mermaid-figure[data-state="ready"] .mermaid-source-panel { display: none !important; }
	.article-table { overflow: visible; }
	.site-header, .prefooter-nav, .site-footer, .reading-tools, .article-toc, .mobile-toc, .comments-area, .heading-permalink, .collection-year-actions, .book-year-index, .photo-year-index { display: none !important; }
	body, html { background: #fff; }
	.book-grid[hidden] { display: grid !important; }
	.article { padding: 0; }
	.article-content, .article-header { width: 100%; max-width: none; }
	.article-content { color: #000; font-size: 11pt; }
	.article-header h1 { font-size: 26pt; }
}
