/* Hallmark · shape: Index-First journal · genre: editorial · theme: brand (Apple reference, Xingyu identity) · hero: Banner · nav: quiet edge-aligned · footer: colophon · signature: panoramic coast beneath a two-line Chinese headline · posture: Restrained · v2.0.0 */
/* Hallmark · pre-emit critique: P4 H4 E4 S4 R5 V4 · weakest: specificity; replaced generic benefits with notes on this site's domain separation and browser experiments. */
/* Hallmark · waive 1 · Apple-inspired system display is explicitly requested · Installed CJK faces preserve platform typography without external font files. */
/* Hallmark · waive 59 · Index-First journal is a dense rule-separated macrostructure · Notes use hairlines and alternate surfaces to separate reading tasks. */
/* Hallmark · dismissed 25 · Short Chinese introductory sentence, not long-form prose; verified at 320 to 1920px. */
/* Hallmark · answered F15 · Reading index rows use 32px while editorial split sections use 64px, collapsing to 32px at tablet sizes. */
@import url('./tokens.css');
@import url('./base.css');
body { font-synthesis: none; }
a, button, summary { -webkit-tap-highlight-color: var(--color-clear); }
a { text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: .3em; }
a:active, button:active { transform: translateY(1px); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, summary:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 5px; }
button { cursor: pointer; }
button:disabled { opacity: .55; cursor: not-allowed; transform: none; }
button[aria-busy='true'] { cursor: progress; }
.skip { position: absolute; z-index: var(--z-toast); transform: translateY(-200%); padding: var(--space-sm) var(--space-lg); background: var(--color-ink); color: var(--color-paper); }
.skip:focus-visible { transform: none; }
.site-header { padding-block: var(--space-lg); }
.header-inner { display: flex; justify-content: space-between; align-items: center; gap: var(--space-lg); min-height: 44px; }
.brand { display: inline-flex; gap: var(--space-sm); align-items: center; font-size: var(--text-lg); font-weight: 600; min-height: 44px; white-space: nowrap; }
.brand svg { width: 25px; height: 25px; color: var(--color-accent); }
.brand-sub { font-size: var(--text-sm); font-weight: 400; color: var(--color-muted); margin-left: var(--space-xs); }
nav { display: flex; align-items: center; gap: var(--space-xl); }
nav a { display: inline-flex; align-items: center; min-height: 44px; font-size: var(--text-sm); white-space: nowrap; }
nav a[aria-current] { color: var(--color-accent); text-decoration: underline; text-underline-offset: .4em; }
.hero { padding-block: var(--space-3xl) var(--space-2xl); }
.intro-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); align-items: end; gap: var(--space-3xl); margin-bottom: var(--space-2xl); }
.hero h1 { max-width: 12ch; line-height: 1.2; }
.intro-note { padding-bottom: var(--space-xs); }
.intro-note p { max-width: 28ch; color: var(--color-muted); font-size: var(--text-lead); line-height: 1.8; }
.text-action { display: inline-flex; min-height: 44px; align-items: center; gap: var(--space-sm); color: var(--color-accent); font-weight: 600; margin-top: var(--space-lg); }
.text-action svg { width: 18px; height: 18px; }
.hero-image { margin: 0; }
.hero-image img { width: 100%; aspect-ratio: 3.15; object-fit: cover; object-position: 50% 50%; border-radius: var(--radius-card); }
.hero-image figcaption { display: flex; justify-content: space-between; gap: var(--space-lg); margin-top: var(--space-md); color: var(--color-muted); font-size: var(--text-sm); }
.journal { padding-block: var(--section-gap-s) var(--section-gap); }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: var(--space-xl); margin-bottom: var(--space-2xl); }
.section-head p { color: var(--color-muted); max-width: 45ch; line-height: 1.8; }
.note-list { border-top: 1px solid var(--color-rule); }
.note-link { display: grid; grid-template-columns: minmax(0, .5fr) minmax(0, 2fr) minmax(0, 1fr) auto; align-items: center; gap: var(--gap-columns); padding-block: var(--space-xl); border-bottom: 1px solid var(--color-rule); }
.note-link:hover { text-decoration: none; }
.note-link:hover h3 { color: var(--color-accent); }
.note-kind { color: var(--color-muted); font-size: var(--text-sm); }
.note-link h3 { line-height: 1.55; letter-spacing: -.03em; }
.note-desc { font-size: var(--text-sm); color: var(--color-muted); line-height: 1.7; }
.note-link svg { width: 20px; height: 20px; }
.lab { background: var(--color-paper-2); padding-block: var(--section-gap-s); }
.lab-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); gap: var(--space-3xl); align-items: center; }
.lab-intro h2 { line-height: 1.25; }
.lab-intro p { margin-top: var(--space-lg); color: var(--color-muted); max-width: 45ch; line-height: 1.8; }
.lab-controls { display: flex; align-items: center; justify-content: space-between; gap: var(--space-md); margin-bottom: var(--space-lg); }
.lab-controls label { color: var(--color-muted); font-size: var(--text-sm); }
select { min-height: 44px; padding: var(--space-xs) var(--space-sm); border: 1px solid var(--color-muted); border-radius: 8px; background: var(--color-paper); color: var(--color-ink); }
.type-sample { background: var(--color-paper); border-radius: var(--radius-card); padding: var(--space-xl); }
.type-sample h3 { margin-bottom: var(--space-lg); font-size: var(--text-xl); }
.type-sample p { font-size: var(--sample-size, 18px); line-height: 1.9; color: var(--color-ink-2); max-width: 65ch; }
.lab-meta { margin-top: var(--space-md); font-size: var(--text-sm); color: var(--color-muted); min-height: 1lh; }
.about { padding-block: var(--section-gap) var(--section-gap-s); }
.about-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: var(--space-3xl); }
.about h2 { line-height: 1.3; margin-bottom: var(--space-xl); }
.about-copy { font-size: var(--text-lead); line-height: 1.9; max-width: 45ch; color: var(--color-muted); }
.about dl { margin: 0; }
.about dl div { display: grid; grid-template-columns: 80px minmax(0, 1fr); gap: var(--space-lg); padding-block: var(--space-lg); border-bottom: 1px solid var(--color-rule); }
.about dl div:first-child { padding-top: 0; }
dt { color: var(--color-muted); font-size: var(--text-sm); }
dd { margin: 0; line-height: 1.8; }
.feedback { padding-block: var(--section-gap-s); background: var(--color-field); color: var(--color-field-ink); }
.feedback-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-3xl); }
.feedback h2 { line-height: 1.3; }
.feedback p { color: var(--color-field-muted); line-height: 1.9; margin-top: var(--space-lg); max-width: 45ch; }
.feedback .text-action { color: var(--color-field-ink); }
.feedback :focus-visible { outline-color: var(--color-field-ink); }
.feedback details { border-top: 1px solid var(--color-field-muted); }
.feedback details:last-child { border-bottom: 1px solid var(--color-field-muted); }
summary { cursor: pointer; padding-block: var(--space-lg); min-height: 48px; }
.feedback details p { margin-top: 0; padding-bottom: var(--space-lg); font-size: var(--text-sm); max-width: 45ch; }
.site-footer { padding-block: var(--space-3xl) var(--space-xl); background: var(--color-paper-2); }
.footer-top, .footer-bottom { display: flex; justify-content: space-between; gap: var(--space-xl); align-items: start; }
.footer-links { display: flex; flex-wrap: wrap; gap: var(--space-lg); }
.footer-links a { min-height: 44px; display: inline-flex; align-items: center; font-size: var(--text-sm); white-space: nowrap; }
.footer-bottom { margin-top: var(--space-2xl); font-size: var(--text-xs); color: var(--color-muted); line-height: 1.9; }
.footer-bottom p { max-width: 50ch; }
.footer-bottom a { text-decoration: underline; }
.article-header { padding-block: var(--space-3xl) var(--space-2xl); }
.article-header h1 { max-width: 18ch; font-size: clamp(2.25rem, 4vw, 3.75rem); line-height: 1.3; }
.article-header time { display: block; margin-top: var(--space-lg); color: var(--color-muted); font-size: var(--text-sm); }
.article-header .lead { margin-top: var(--space-lg); color: var(--color-muted); }
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .4fr); gap: var(--space-3xl); padding-bottom: var(--section-gap-s); }
.prose { font-size: var(--text-lg); line-height: 1.95; min-width: 0; }
.prose p, .prose ul, .prose ol { margin-block: var(--space-lg); max-width: 65ch; }
.prose h2 { margin-top: var(--space-2xl); margin-bottom: var(--space-lg); font-size: var(--text-xl); line-height: 1.55; }
.prose h2:first-child { margin-top: 0; }
.prose code { font-family: var(--font-outlier); font-size: var(--text-md); overflow-wrap: anywhere; }
.prose a { color: var(--color-accent); text-decoration: underline; }
.prose li { margin-block: var(--space-xs); }
.aside-note { border-top: 1px solid var(--color-rule); padding-top: var(--space-lg); color: var(--color-muted); font-size: var(--text-sm); line-height: 1.9; }
.aside-note p + p { margin-top: var(--space-lg); }
.form { max-width: 680px; }
.form label { display: block; font-weight: 600; margin-top: var(--space-lg); margin-bottom: var(--space-xs); }
.form input, .form textarea { width: 100%; min-height: 48px; border: 1px solid var(--color-muted); border-radius: 8px; background: var(--color-paper); color: var(--color-ink); padding: var(--space-sm) var(--space-md); font-size: var(--text-md); }
.form textarea { resize: vertical; min-height: 176px; }
.form input[aria-invalid='true'], .form textarea[aria-invalid='true'] { border-color: var(--color-error); }
.form-help { color: var(--color-muted); font-size: var(--text-sm); margin-top: var(--space-xs); line-height: 1.8; }
.form-status { min-height: 1lh; margin-top: var(--space-md); line-height: 1.7; }
.form-status[data-error='true'] { color: var(--color-error); }
.btn { border: 0; border-radius: var(--radius-pill); background: var(--color-accent); color: var(--color-accent-ink); min-height: 48px; padding: var(--space-sm) var(--space-lg); font-size: var(--text-md); font-weight: 600; white-space: nowrap; transition: transform var(--dur-short) var(--ease-out); }
.btn:hover { opacity: .9; }
.form .btn { margin-top: var(--space-lg); }
.noscript-note { margin-block: var(--space-md); color: var(--color-muted); }
@media (max-width: 60rem) {
 :root { --gutter: 32px; }
 .brand-sub { display: none; }
 .intro-grid { gap: var(--space-xl); }
 .hero-image img { aspect-ratio: 2.4; }
 .note-link { grid-template-columns: minmax(0, .4fr) minmax(0, 2fr) auto; }
 .note-desc { display: none; }
 .lab-layout, .about-layout, .feedback-layout { gap: var(--space-xl); }
 .article-layout { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 40rem) {
 :root { --gutter: 24px; --text-display: 2.75rem; --section-gap-s: 64px; --section-gap: 80px; }
 nav { gap: var(--space-lg); }
 nav a { font-size: var(--text-sm); }
 .site-header { padding-block: var(--space-md); }
 .hero { padding-top: var(--space-2xl); padding-bottom: var(--space-lg); }
 .intro-grid { grid-template-columns: minmax(0, 1fr); gap: var(--space-lg); margin-bottom: var(--space-xl); }
 .intro-note p { max-width: 30ch; font-size: var(--text-md); }
 .text-action { margin-top: var(--space-md); }
 .hero-image img { aspect-ratio: 1.2; border-radius: 12px; }
 .hero-image figcaption { font-size: var(--text-xs); }
 .hero-image figcaption span:last-child { display: none; }
 .section-head { display: block; margin-bottom: var(--space-xl); }
 .section-head p { margin-top: var(--space-md); }
 .note-link { grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-sm); padding-block: var(--space-lg); }
 .note-kind { grid-column: 1 / -1; }
 .note-link h3 { font-size: var(--text-lg); }
 .lab-layout, .about-layout, .feedback-layout { grid-template-columns: minmax(0, 1fr); gap: var(--space-2xl); }
 .type-sample { padding: var(--space-lg); }
 .footer-top, .footer-bottom { flex-direction: column; gap: var(--space-lg); }
 .footer-links { gap: var(--space-md); }
 .article-header { padding-top: var(--space-2xl); }
 .article-header h1 { font-size: 2.25rem; }
 .article-layout { gap: var(--space-xl); }
}
@media (max-width: 360px) { nav { gap: var(--space-md); } .brand { gap: var(--space-xs); } }
@media (prefers-reduced-motion: reduce) { .btn, a, button { transition: none; } a:active, button:active { transform: none; } }

/* Reading controls use data attributes so the site also works with a strict CSP. */
#reading-sample[data-size='16'] { --sample-size: 16px; }
#reading-sample[data-size='18'] { --sample-size: 18px; }
#reading-sample[data-size='20'] { --sample-size: 20px; }
.prose h3 { margin-top: var(--space-xl); font-size: var(--text-lg); line-height: 1.6; }
.prose pre { white-space: pre-wrap; overflow-wrap: anywhere; padding: var(--space-lg); background: var(--color-paper-2); border-radius: var(--radius-card); }
.prose ul, .prose ol { padding-inline-start: var(--space-lg); }
.prose li > p { margin-block: var(--space-xs); }
.article-header .text-action { font-size: var(--text-sm); margin-top: 0; margin-bottom: var(--space-lg); }
.prose .form-status { max-width: none; }
@media (pointer: coarse) { nav a, .footer-links a, .text-action, summary { min-height: 48px; } }
