:root {
  --paper: #FDFCFA;
  --ink: #43342D;
  --ink-soft: #94827A;
  --ink-cold: #D3CFCC;
  --ember: #EDC1A8;
  --rule: rgba(67, 52, 45, .12);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "Gowun Dodum", sans-serif;
  font-size: 17px;
  line-height: 1.85;
  word-break: keep-all;
  -webkit-text-size-adjust: 100%;
}

a { color: inherit; text-underline-offset: 5px; text-decoration-thickness: 1px; text-decoration-color: var(--ember); }
a:focus-visible { outline: 2px solid var(--ember); outline-offset: 3px; border-radius: 2px; }

.col { max-width: 600px; margin: 0 auto; padding: 0 24px; }

/* 머리 */
.site-header { padding: 40px 0 0; display: flex; align-items: center; gap: 10px; font-size: 16px; }
.site-header a { text-decoration: none; }
.ember {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--ember);
  box-shadow: 0 0 0 5px rgba(237, 193, 168, .22);
}

/* 첫 화면 */
.hero { padding: 26vh 0 22vh; }
.hero h1 {
  margin: 0;
  font-weight: 400;
  font-size: clamp(30px, 5.4vw, 44px);
  line-height: 1.5;
  letter-spacing: -.01em;
}
.hero p { margin: 32px 0 0; color: var(--ink-soft); max-width: 26em; }
/* 보조 문구가 비어 있어도 두 줄만큼 자리를 지켜 첫 화면 배치가 바뀌지 않게 */
.hero-sub { min-height: 3.7em; }

/* 섹션 */
section { padding: 72px 0; border-top: 1px solid var(--rule); }
h2 { font-weight: 400; font-size: 15px; color: var(--ink-soft); margin: 0 0 28px; }
p { margin: 0 0 1em; }

/* 소개 */
.profile { display: flex; align-items: center; gap: 20px; margin-bottom: 28px; }
.portrait {
  width: 88px; height: 88px; border-radius: 50%; flex: none;
  background: #F3ECE7; color: #A89890; font-size: 12px;
  display: grid; place-items: center; overflow: hidden;
}
.portrait img { width: 100%; height: 100%; object-fit: cover; }
.names { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 0; padding: 0; list-style: none; font-size: 15px; color: var(--ink-soft); }
.names li:first-child { color: var(--ink); }
.lede { font-size: 21px; line-height: 1.6; margin-bottom: 20px; }

/* 연도 목록 (책, 수상) */
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline > li { display: grid; grid-template-columns: 64px 1fr; gap: 16px; padding: 10px 0; }
.timeline .y { color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.timeline .t { font-size: 19px; }
a.t { text-decoration: none; }
a.t:hover { text-decoration: underline; text-decoration-color: var(--ember); }
.timeline.grouped a.t { width: fit-content; }
.timeline .d { display: block; font-size: 14px; color: var(--ink-soft); line-height: 1.6; }
.timeline.books > li { grid-template-columns: 64px auto 1fr; align-items: center; padding: 12px 0; }
.timeline.grouped > li { padding: 14px 0; }
.timeline.grouped ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.timeline.grouped .t { font-size: 17px; display: block; line-height: 1.6; }

/* 책 표지: 평소엔 종이색 막을 덮어 옅게, 마우스를 올리면(모바일은 화면 위 35% 지점에 오면) 원래 색으로 */
.cover {
  position: relative; flex: none;
  width: 56px; aspect-ratio: 2 / 3;
  background: var(--c); border-radius: 2px;
  box-shadow: inset 0 0 0 1px rgba(80, 60, 50, .06);
  overflow: hidden;
}
.cover img { display: block; width: 100%; height: 100%; object-fit: cover; }
.cover::after {
  content: ""; position: absolute; inset: 0;
  background: var(--paper); opacity: .42;
  transition: opacity .6s ease;
}
li:hover > .cover::after,
li:focus-within > .cover::after,
li.in-view > .cover::after { opacity: 0; }

/* 연락 */
.links { list-style: none; margin: 0; padding: 0; display: flex; gap: 28px; flex-wrap: wrap; }

.site-footer { padding: 72px 0 56px; font-size: 13px; color: var(--ink-soft); }

/* 데워지는 글: 화면에 들어온 블록이 차가운 옅은 회색에서 따뜻한 잉크색으로.
   .blk 클래스는 스크립트가 붙이므로 스크립트가 없으면 처음부터 잉크색으로 보인다. */
.blk { color: var(--ink-cold); transition: color 1.4s ease; transition-delay: var(--d, 0s); }
.blk * { color: inherit !important; }
.blk .cover { filter: grayscale(1) opacity(.5); transition: filter 1.4s ease; transition-delay: var(--d, 0s); }
.blk .portrait { filter: grayscale(1) opacity(.5); }
.blk.on { color: var(--ink); }
.blk.on .cover, .blk.on .portrait { filter: none; }
.blk.on :is(h2, .y, .d, .names li:not(:first-child)) { color: var(--ink-soft) !important; }
:is(h2, .hero p).blk.on { color: var(--ink-soft); }

@media (max-width: 600px) {
  .col { padding: 0 16px; }
  .hero { padding: 18vh 0 16vh; }
  .timeline > li { grid-template-columns: 48px 1fr; }
  .timeline.books > li { grid-template-columns: 40px auto 1fr; gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .blk, .blk .cover, .cover::after { transition: none; }
}
