:root {
  color-scheme: light;
  --paper: #f7f6f2; --surface: #fffefa; --ink: #222823; --muted: #62685f;
  --line: #d8dbd1; --accent: #b33e22; --accent-soft: #f3e6de; --on-accent: #ffffff;
  --success: #426747; --warning: #8b661f; --error: #b13030; --info: #335a78;
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 20px; --s6: 24px;
  --s8: 32px; --s12: 48px; --s16: 64px; --s24: 96px;
  --caption: .75rem; --small: .875rem; --body: 1rem; --h4: 1.125rem;
  --h3: 1.5rem; --h2: 2rem; --h1: 4rem; --mobile-h1: 2.5rem;
  --radius: 4px; --pill: 999px; --stroke: 1px; --focus: 2px; --speed: 160ms;
  --page-width: 1200px; --touch: 44px; --sidebar: 264px; --reading-width: 760px;
  --tight: 1.15; --normal: 1.6; --reading: 1.85; --tracking: -.045em;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --paper: #191e1b; --surface: #202622; --ink: #f0f0e8; --muted: #adb4a9;
    --line: #3c443d; --accent: #ff9876; --accent-soft: #3b2b23; --on-accent: #191e1b;
    --success: #9bc89f; --warning: #dbc288; --error: #ee9595; --info: #9ebdd5;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #191e1b; --surface: #202622; --ink: #f0f0e8; --muted: #adb4a9;
  --line: #3c443d; --accent: #ff9876; --accent-soft: #3b2b23; --on-accent: #191e1b;
  --success: #9bc89f; --warning: #dbc288; --error: #ee9595; --info: #9ebdd5;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: Pretendard, "Noto Sans KR", system-ui, sans-serif; font-size: var(--body); line-height: var(--normal); }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button, a, input { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button, input { color: inherit; }
button, a { transition: color var(--speed), background var(--speed); }
button:hover, a:hover { color: var(--accent); }
:focus-visible { outline: var(--focus) solid var(--accent); outline-offset: var(--s1); }
[hidden] { display: none !important; }
h1, h2, h3, h4, p { margin: 0; }
.page-shell { max-width: var(--page-width); margin: auto; padding: 0 var(--s6); }
.site-header { display: flex; justify-content: space-between; align-items: center; min-height: var(--s24); border-bottom: var(--stroke) solid var(--line); gap: var(--s6); }
.brand { display: flex; align-items: baseline; font-size: var(--h2); font-weight: 850; letter-spacing: var(--tracking); }
.brand-dot { color: var(--accent); }
.brand-note { margin-left: var(--s6); font-size: var(--caption); font-weight: 500; letter-spacing: normal; color: var(--muted); }
.header-nav { display: flex; gap: var(--s8); align-items: center; font-size: var(--small); }
.nav-log { font-weight: 700; }
.button { min-height: var(--touch); padding: var(--s2) var(--s4); border: var(--stroke) solid var(--line); border-radius: var(--radius); background: var(--surface); display: inline-flex; align-items: center; justify-content: center; gap: var(--s2); font-size: var(--small); }
.theme-toggle { border: none; background: transparent; padding-right: 0; }
.theme-toggle > span:first-child { font-size: var(--h3); }
.hero { padding: var(--s16) 0; display: flex; align-items: center; justify-content: space-between; gap: var(--s12); border-bottom: var(--stroke) solid var(--line); }
.eyebrow { font-size: var(--caption); font-weight: 650; letter-spacing: .12em; color: var(--muted); }
.hero .eyebrow { display: flex; gap: var(--s2); align-items: center; color: var(--accent); margin-bottom: var(--s6); }
.status-dot { display: inline-block; width: var(--s2); height: var(--s2); background: var(--accent); border-radius: var(--pill); flex: none; }
h1 { font-size: var(--h1); line-height: var(--tight); font-weight: 730; letter-spacing: var(--tracking); word-break: keep-all; }
.hero h1 span { color: var(--accent); }
.hero-description { margin-top: var(--s6); line-height: var(--reading); color: var(--muted); }
.hero-stamp { width: var(--sidebar); flex: none; text-align: center; color: var(--accent); display: grid; justify-items: center; gap: var(--s4); }
.hero-stamp svg { width: calc(var(--s16) * 2); height: calc(var(--s12) * 2); }
.stamp-top, .stamp-bottom { font-size: var(--caption); font-weight: 700; letter-spacing: .16em; }
.content-grid { display: grid; grid-template-columns: minmax(0, 1fr) var(--sidebar); gap: var(--s16); padding: var(--s12) 0 var(--s16); }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: var(--s4); margin-bottom: var(--s6); }
.section-heading h2 { font-size: var(--h3); letter-spacing: var(--tracking); }
.count { font-size: var(--small); color: var(--accent); vertical-align: top; margin-left: var(--s2); }
.search-field { display: flex; align-items: center; gap: var(--s3); padding: var(--s2) var(--s4); background: var(--surface); border: var(--stroke) solid var(--line); border-radius: var(--radius); }
.search-field > span { font-size: var(--h3); color: var(--muted); }
.search-field input { width: 100%; min-width: 0; min-height: var(--s8); border: 0; outline: none; background: transparent; font-size: var(--small); }
.search-field:focus-within { outline: var(--focus) solid var(--accent); outline-offset: var(--s1); }
.search-field input::placeholder { color: var(--muted); }
kbd { font-family: inherit; color: var(--muted); font-size: var(--caption); white-space: nowrap; }
.chips { display: flex; flex-wrap: wrap; gap: var(--s2); margin: var(--s4) 0 var(--s8); }
.chip { display: inline-flex; gap: var(--s2); align-items: center; min-height: var(--touch); background: transparent; border: var(--stroke) solid var(--line); padding: var(--s2) var(--s4); border-radius: var(--pill); font-size: var(--small); }
.chip span { color: var(--muted); font-size: var(--caption); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.chip[aria-pressed="true"] span { color: inherit; }
.month-group + .month-group { margin-top: var(--s8); }
.month-label { display: flex; justify-content: space-between; align-items: baseline; font-size: var(--small); font-weight: 650; padding-bottom: var(--s3); border-bottom: var(--stroke) solid var(--ink); }
.month-label span { font-size: var(--caption); font-weight: 400; letter-spacing: .08em; color: var(--muted); }
.post-card { padding: var(--s6) 0; border-bottom: var(--stroke) solid var(--line); }
.post-meta { display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; font-size: var(--caption); color: var(--muted); }
.example-label { padding: 0 var(--s2); border: var(--stroke) solid var(--line); border-radius: var(--radius); }
.post-category { color: var(--accent); }
.post-card h4 { font-size: var(--h3); letter-spacing: var(--tracking); line-height: 1.4; margin: var(--s3) 0; word-break: keep-all; }
.post-card h4 a { display: flex; justify-content: space-between; gap: var(--s4); align-items: baseline; }
.post-arrow { color: var(--muted); font-weight: 400; flex: none; }
.post-card h4 a:hover .post-arrow { color: var(--accent); }
.post-card p { font-size: var(--small); line-height: var(--reading); color: var(--muted); max-width: 90%; }
.post-tags { display: flex; flex-wrap: wrap; gap: var(--s3); margin-top: var(--s4); }
.tag { font-size: var(--caption); color: var(--muted); }
.sidebar { padding-top: var(--s2); }
.archive-panel { border-top: var(--focus) solid var(--accent); padding-top: var(--s6); margin-bottom: var(--s8); }
.archive-panel h2 { font-size: var(--h3); letter-spacing: var(--tracking); margin: var(--s4) 0 var(--s6); }
.archive-panel h3 { font-size: var(--small); color: var(--muted); margin-top: var(--s6); }
.archive-link { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); min-height: var(--touch); border-bottom: var(--stroke) solid var(--line); font-size: var(--small); }
.archive-panel .chips { margin-bottom: 0; }
.archive-panel .chip { padding: var(--s2) var(--s3); font-size: var(--caption); }
.archive-panel [aria-current="page"] { color: var(--accent); font-weight: 700; }
#list-title { overflow-wrap: anywhere; }
.about-panel { border-top: var(--focus) solid var(--accent); padding-top: var(--s6); scroll-margin-top: var(--s6); }
.about-panel h2 { font-size: var(--h3); line-height: 1.5; letter-spacing: var(--tracking); margin: var(--s4) 0 var(--s6); }
.about-panel > p:not(.eyebrow) { font-size: var(--small); line-height: var(--reading); color: var(--muted); margin-bottom: var(--s4); word-break: keep-all; }
.about-signature { display: flex; align-items: center; gap: var(--s3); padding: var(--s6) 0; border-bottom: var(--stroke) solid var(--line); }
.signature-mark { display: grid; place-items: center; width: var(--touch); height: var(--touch); background: var(--ink); color: var(--paper); font-size: var(--h3); font-weight: 750; border-radius: var(--radius); }
.about-signature strong { font-size: var(--small); display: block; }
.about-signature div > span { color: var(--muted); font-size: var(--caption); }
.note-panel { background: var(--accent-soft); padding: var(--s6); margin-top: var(--s8); }
.note-panel .eyebrow { color: var(--accent); }
.note-panel p { margin-top: var(--s3); font-size: var(--small); line-height: var(--reading); }
.note-arrow { display: block; margin-top: var(--s3); font-size: var(--h3); color: var(--accent); }
.sidebar-footer { display: flex; gap: var(--s2); align-items: center; color: var(--muted); font-size: var(--caption); margin-top: var(--s6); }
.sidebar-footer .status-dot { background: var(--success); }
.site-footer { padding: var(--s6) 0 var(--s8); border-top: var(--stroke) solid var(--line); display: flex; justify-content: space-between; gap: var(--s4); font-size: var(--caption); color: var(--muted); }
.site-footer strong { font-size: var(--h4); color: var(--ink); margin-right: var(--s2); }
.empty-state { padding: var(--s16) var(--s4); text-align: center; color: var(--muted); }
.empty-state h1, .empty-state h3 { color: var(--ink); font-size: var(--h3); }
.empty-state p { margin: var(--s3) 0 var(--s6); }
.reading-shell { max-width: var(--reading-width); margin: auto; padding: var(--s12) 0 var(--s16); }
.back-link { color: var(--muted); font-size: var(--small); display: inline-block; padding: var(--s2) 0; }
.post-header { padding: var(--s8) 0; border-bottom: var(--stroke) solid var(--line); margin-bottom: var(--s8); }
.post-header h1 { font-size: var(--mobile-h1); margin: var(--s4) 0 var(--s6); line-height: 1.35; }
.post-header > p { color: var(--muted); line-height: var(--reading); }
.prose { line-height: var(--reading); overflow-wrap: anywhere; }
.prose > * + * { margin-top: var(--s6); }
.prose h1 { font-size: var(--h2); }
.prose h2 { font-size: var(--h3); margin-top: var(--s12); }
.prose h3 { font-size: var(--h4); }
.prose h4, .prose h5, .prose h6 { font-size: var(--body); }
.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: var(--s1); }
.prose ul, .prose ol { padding-left: var(--s6); }
.prose li + li { margin-top: var(--s2); }
.prose blockquote { margin-left: 0; margin-right: 0; border-left: var(--s1) solid var(--accent); padding: var(--s4) var(--s6); background: var(--accent-soft); font-size: var(--small); }
.prose code { background: var(--accent-soft); padding: var(--s1); border-radius: var(--radius); font-size: var(--small); }
.prose pre { background: var(--surface); padding: var(--s6); overflow-x: auto; border: var(--stroke) solid var(--line); border-radius: var(--radius); }
.prose pre code { background: transparent; padding: 0; }
.table-wrap { overflow-x: auto; }
.prose table { width: 100%; border-collapse: collapse; font-size: var(--small); }
.prose td, .prose th { border-bottom: var(--stroke) solid var(--line); padding: var(--s3) var(--s4); text-align: left; }
.prose th { background: var(--surface); }
.post-pagination { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s6); border-top: var(--stroke) solid var(--line); margin-top: var(--s16); padding-top: var(--s6); }
.post-pagination a:last-child { text-align: right; }
.post-pagination span { color: var(--muted); display: block; font-size: var(--small); margin-bottom: var(--s2); }
.post-pagination strong { font-size: var(--small); }
.visually-hidden { position: absolute; width: var(--stroke); height: var(--stroke); padding: 0; margin: calc(-1 * var(--stroke)); overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.skip-link { position: fixed; top: var(--s2); left: var(--s2); transform: translateY(-200%); padding: var(--s3); background: var(--ink); color: var(--paper); z-index: 10; }
.skip-link:focus { transform: none; }
@media (max-width: 1000px) {
  .brand-note { display: none; }
  .hero h1 { font-size: var(--mobile-h1); }
  .content-grid { gap: var(--s8); }
}
@media (max-width: 800px) {
  .page-shell { padding: 0 var(--s5); }
  .site-header { min-height: var(--s16); gap: var(--s4); }
  .header-nav { gap: var(--s4); font-size: var(--caption); }
  .theme-toggle { padding: 0; min-width: var(--touch); }
  #theme-label { display: none; }
  .hero { padding: var(--s12) 0; }
  .hero-stamp { display: none; }
  .hero .eyebrow { font-size: var(--caption); margin-bottom: var(--s5); }
  .hero h1 { font-size: var(--mobile-h1); line-height: 1.25; }
  .hero h1 span { display: block; }
  .hero-description { font-size: var(--small); }
  .desktop-break { display: none; }
  .content-grid { grid-template-columns: minmax(0, 1fr); padding-top: var(--s8); gap: var(--s12); }
  .section-heading > .eyebrow { display: none; }
  .section-heading h2 { font-size: var(--h3); }
  .chip { padding: var(--s2) var(--s3); font-size: var(--caption); }
  .post-card h4 { font-size: var(--h4); }
  .post-card p { max-width: 100%; }
  .site-footer { flex-direction: column; gap: var(--s2); }
  .post-header h1 { font-size: var(--h2); }
  .post-pagination { gap: var(--s4); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
