:root {
  color-scheme: light;
  --paper: #f8f8f3;
  --ink: #1e322b;
  --muted: #53645a;
  --line: #c9d0c4;
  --serif: "Iowan Old Style", Georgia, "Noto Serif SC", "Songti SC", SimSun, serif;
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: var(--paper);
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 3px solid #a34c23; outline-offset: 5px; }
.wrap { width: min(100% - 3rem, 65rem); margin-inline: auto; }
.skip { position: absolute; left: 1rem; top: -8rem; background: white; padding: .6rem; z-index: 5; }
.skip:focus { top: 1rem; }
.mast, .mast nav, .brand, footer { display: flex; align-items: center; }
.mast { justify-content: space-between; min-height: 5rem; border-bottom: 1px solid var(--line); }
.brand { font-family: var(--serif); font-size: 1.15rem; font-weight: 700; gap: .65rem; }
.book-mark { width: .85rem; height: 1.25rem; background: #a5472d; clip-path: polygon(0 0,100% 0,100% 100%,50% 77%,0 100%); }
.mast nav { gap: clamp(1rem, 4vw, 2.2rem); font-size: .95rem; }
nav a:hover, .back:hover { text-decoration: underline; text-underline-offset: .28em; }
main { flex: 1; }
.cover { display: grid; grid-template-columns: 1.18fr 1fr; align-items: center; gap: 2rem; padding: clamp(2.75rem, 6.8vw, 5rem) 0; }
h1, h2, h3 { font-family: var(--serif); margin: 0; }
.intro h1 { font-size: clamp(2.8rem, 5.5vw, 4.7rem); line-height: 1.2; letter-spacing: -.055em; }
.intro h1 span { font-weight: 500; font-style: italic; }
.intro p, .entry p { color: var(--muted); line-height: 1.8; }
.intro p { margin: 1rem 0 0; font-size: 1.06rem; }
.still-life {
  position: relative; display: grid; place-items: center; isolation: isolate; overflow: hidden;
  min-height: 12rem; aspect-ratio: 1.92;
  background-color: #e3e6d8;
  background-image: repeating-linear-gradient(0deg, transparent 0 21px, #53645a10 21px 22px),
                    repeating-linear-gradient(90deg, transparent 0 21px, #53645a10 21px 22px);
}
.notebook {
  position: relative; width: 35%; aspect-ratio: .78; transform: rotate(-15deg) skewY(2deg);
  border: 1px solid #253c32; border-radius: 3px 7px 7px 2px;
  background: linear-gradient(90deg, #213e32 0 4%, #516b51 5%, #314e40 8%, #3d5947 60%, #344e3f);
  box-shadow: 1px 2px #cad1ba, 2px 4px #e8e6cd, 3px 6px #acb39e, 3px 8px #304b3b, 8px 13px 13px #30473345;
}
.notebook::before {
  content: ""; position: absolute; inset: 4% 5% 5% 10%; border: 1px solid #c4ccad47; border-radius: 2px;
}
.elastic { position: absolute; top: -1%; bottom: -4%; right: 14%; width: 5%; background: #243e32; box-shadow: 1px 0 2px #16281f99; }
.ribbon { position: absolute; width: 8%; height: 15%; left: 24%; top: 99%; background: #a34f34; clip-path: polygon(0 0,100% 0,100% 100%,50% 73%,0 100%); }
.pencil { position: absolute; top: 21%; left: 72%; width: 1.55%; height: 57%; transform: rotate(15deg); background: linear-gradient(90deg,#86512a,#cb945f 45%,#9f683c 70%); box-shadow: 2px 2px 3px #32433230; }
.pencil::after { content: ""; position: absolute; top: 100%; width: 100%; height: 10%; background: linear-gradient(#d9b891 65%,#26332b 66%); clip-path: polygon(0 0,100% 0,50% 100%); }
.archive { margin: 0 0 clamp(4rem, 9vw, 7rem); scroll-margin-top: 1.5rem; }
.archive h2 { font-size: 1.45rem; padding-bottom: 1rem; border-bottom: 2px solid var(--ink); }
.entries { list-style: none; padding: 0; margin: 0; }
.entry { display: grid; grid-template-columns: 8.25rem 1fr; gap: 1rem; align-items: baseline; padding: 1.7rem 0; border-bottom: 1px solid var(--line); }
time { font-family: ui-monospace, Consolas, monospace; font-size: .9rem; color: var(--muted); }
.entry h3 { font-size: 1.5rem; }
.entry:hover h3 { text-decoration: underline; text-underline-offset: .2em; }
.entry p { margin: .45rem 0 0; }
footer { justify-content: space-between; padding: 1.4rem 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .88rem; }
.post { max-width: 42rem; margin: clamp(3rem, 8vw, 6.5rem) auto; }
.post header { padding-bottom: 1.5rem; border-bottom: 1px solid var(--line); }
.post h1 { font-size: clamp(2.4rem, 6vw, 3.75rem); margin: .7rem 0 0; line-height: 1.24; }
.prose { font-family: var(--serif); font-size: 1.13rem; line-height: 1.95; overflow-wrap: anywhere; padding: 1rem 0; }
.prose img { max-width: 100%; height: auto; }
.prose pre { overflow-x: auto; background: #e9ece2; padding: 1rem; }
.prose a, .back { text-decoration: underline; text-underline-offset: .25em; }
.back { display: inline-block; margin-top: 1.25rem; }
@media (max-width: 650px) {
  .wrap { width: calc(100% - 2.5rem); }
  .mast { min-height: 4.2rem; }
  .cover { grid-template-columns: 1fr; gap: 1.7rem; padding: 2.5rem 0; }
  .still-life { aspect-ratio: 2.2; min-height: auto; }
  .notebook { width: 29%; }
  .entry { grid-template-columns: 1fr; gap: .55rem; padding: 1.25rem 0; }
}
