/* Shared navigation and a quiet reading layout. No scripts to load. */
@font-face { font-family: "Caveat"; src: url("/assets/fonts/caveat-latin.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
:focus-visible { outline: 2px solid #124f8b; outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.skip-link { position: fixed; z-index: 100; left: 1rem; top: 1rem; padding: .65rem 1rem; border: 2px solid #124f8b; background: #fffdf8; color: #124f8b; font: 700 1rem/1.4 system-ui, sans-serif; transform: translateY(-200%); }
.skip-link:focus { transform: none; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto !important; } }
.site-nav { display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: center; font-size: .92rem; font-weight: 650; }
.site-nav a[aria-current="page"] { text-decoration-thickness: 2px; }

/* The journal keeps the homepage's paper, ink and blue links, but uses less furniture. */
.journal-body { margin: 0; background: #f8f6f1; color: #111418; font: 17px/1.65 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
.journal-page, .journal-page * { box-sizing: border-box; }
.journal-page { --post-columns: 5rem minmax(0, 1fr) 6.5rem; --post-gap: 1.5rem; width: min(100% - 40px, 760px); margin: auto; min-height: 100vh; display: flex; flex-direction: column; }
.journal-page a { color: #124f8b; text-decoration-color: #8ca9bd; text-underline-offset: .2em; }
.journal-page a:hover { text-decoration-color: currentColor; }
.journal-header { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 2rem; padding: 2.5rem 0 1.3rem; border-bottom: 1px solid #cbd7df; }
.journal-header .brand { font-size: 1.15rem; font-weight: 750; color: #111418; text-decoration: none; }
.journal-page main { flex: 1; }
.journal-intro { padding: 2.8rem 0 1.75rem; }
.eyebrow { display: block; margin: 0 0 .6rem; color: #0e5f42 !important; font-size: .77rem; font-weight: 750; letter-spacing: .07em; text-transform: uppercase; }
.journal-intro h1 { margin: 0; color: #0f1822; font-size: clamp(2.2rem, 5vw, 3.2rem); line-height: 1.12; letter-spacing: -.035em; }
.journal-intro > p:last-child { max-width: 38rem; margin: 1rem 0 0; color: #45504d; }
.post-list { padding: 0; margin: 0 0 5rem; list-style: none; }
.post-list li { display: grid; grid-template-columns: var(--post-columns); align-items: center; gap: var(--post-gap); padding: 1.5rem 0; border-top: 1px dotted #cbd7df; }
.post-list time, .article-header time { color: #5f6865; font-size: .9rem; }
.post-list .post-date { display: flex; flex-direction: column; line-height: 1.5; overflow-wrap: anywhere; }
.post-list .post-date > span:first-child { font-weight: 700; color: #45504d; }
.post-list .post-copy { min-width: 0; }
.post-list .post-meta { display: flex; flex-direction: column; align-items: center; gap: .35rem; text-align: center; }
.post-list .post-category-icon { display: block; width: 30px; height: 30px; flex: 0 0 auto; }
.post-list .post-category { color: #45504d; font-size: .78rem; font-weight: 650; line-height: 1.25; }
.post-list a.post-category { text-decoration: none; }
.post-list a.post-category:is(:hover, :focus-visible) { text-decoration: underline; }
/* Motion stays inside the icon's box, so dates and titles never shift.
   Thoughts, tools and experiments animate their details inside the SVG files. */
.post-category-icon { transform-origin: center; }
.post-category-icon[src$="/projects.svg"], .post-category-icon[src$="/photography.svg"] { animation: gentle-tilt 4s ease-in-out infinite; }
.post-category-icon[src$="/travel.svg"] { animation: gentle-float 4s ease-in-out infinite; }
.post-category-icon[src$="/hobbies.svg"] { animation: gentle-tilt 4.5s ease-in-out infinite; }
.post-category-icon[src$="/learning.svg"] { animation: spring-grow 4.5s ease-in-out infinite; transform-origin: center bottom; }
.post-list li:nth-child(3n + 2) .post-category-icon { animation-delay: -1.3s; }
.post-list li:nth-child(3n) .post-category-icon { animation-delay: -2.5s; }
@keyframes gentle-tilt { 0%, 42%, 100% { transform: rotate(0); } 62% { transform: rotate(-7deg); } 82% { transform: rotate(5deg); } }
@keyframes spring-grow { 0%, 44%, 100% { transform: scale(1); } 70% { transform: scale(1.09); } }
@keyframes gentle-float { 0%, 42%, 100% { transform: translateY(0); } 70% { transform: translateY(-2px); } }
@media (prefers-reduced-motion: reduce) { .post-category-icon { animation: none !important; } }
.post-list h2 { margin: 0; font-family: "Caveat", "Segoe Print", cursive; font-weight: 600; font-size: 1.75rem; line-height: 1.2; overflow-wrap: anywhere; }
.post-list h2 a { color: #111418; text-decoration: none; }
.post-list h2 a:hover, .post-list h2 a:focus-visible { color: #124f8b; text-decoration: underline; }
.post-list h3 { margin: 0; font-family: "Caveat", "Segoe Print", cursive; font-weight: 600; font-size: 1.75rem; line-height: 1.2; overflow-wrap: anywhere; }
.post-list h3 a { color: #111418; text-decoration: none; }
.post-list h3 a:hover, .post-list h3 a:focus-visible { color: #124f8b; text-decoration: underline; }
.post-list p { margin: .35rem 0 0; color: #45504d; font-size: .9rem; line-height: 1.5; }
.empty-note { padding: 1.5rem 0 5rem; border-top: 1px solid #cbd7df; color: #45504d; }
.article-header { padding: 2.5rem 0 1.5rem; border-bottom: 1px solid #cbd7df; }
.article-header h1 { max-width: 30ch; margin: .5rem 0 .75rem; color: #0f1822; font-size: clamp(1.75rem, 4vw, 2.25rem); line-height: 1.2; letter-spacing: -.02em; }
.article-header > p { max-width: 40rem; margin: 1rem 0 0; color: #45504d; font-size: 1.1rem; }
.prose { max-width: 68ch; padding: 1.3rem 0 4rem; font-size: 1.07rem; line-height: 1.76; overflow-wrap: break-word; }
.prose p, .prose ul, .prose ol, .prose blockquote, .prose pre, .prose table { margin: 1.4em 0; }
.prose h2, .prose h3, .prose h4 { margin: 2em 0 .65em; line-height: 1.3; }
.prose h2 { font-size: 1.55rem; }.prose h3 { font-size: 1.23rem; }
.prose img { display: block; max-width: 100%; height: auto; }
.prose blockquote { padding: .1rem 0 .1rem 1.2rem; margin-left: 0; border-left: 3px solid #0e5f42; color: #45504d; }
.prose code { padding: .12em .3em; background: #e9eef0; font-size: .85em; }
.prose pre { overflow-x: auto; padding: 1rem 1.2rem; background: #e9eef0; font-size: .88em; line-height: 1.5; }
.prose pre code { padding: 0; background: none; font-size: inherit; }
.prose table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; }
.prose th, .prose td { padding: .4rem .75rem; border-bottom: 1px solid #cbd7df; text-align: left; }
.photo-gallery { padding: 0 0 4rem; border-top: 1px solid #cbd7df; }
.photo-gallery h2 { margin: 1.5rem 0 1.2rem; font-size: 1.55rem; }
.gallery-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; align-items: start; }
.gallery-grid figure { margin: 0; }
.gallery-grid figure:only-child { grid-column: 1 / -1; }
.gallery-grid img { display: block; width: 100%; height: auto; }
.gallery-grid figcaption { margin-top: .4rem; color: #5f6865; font-size: .85rem; line-height: 1.4; }
.journal-footer { display: flex; justify-content: space-between; gap: 1rem; padding: 1.3rem 0 2.5rem; border-top: 1px solid #cbd7df; font-size: .93rem; }

/* A small illustrated notebook, rather than a landing-page-sized headline. */
.post-page { width: min(100% - 48px, 720px); }
.post-page .journal-header { padding-top: 2rem; }
.post-page .brand { display: inline-flex; align-items: center; gap: .6rem; }
.post-page .brand::before { content: ""; width: 7px; height: 7px; background: #1b6599; box-shadow: 4px -4px 0 #8ca9bd; }
.post-page .article-header { position: relative; padding-bottom: 1.6rem; }
.post-page .article-header::after { content: ""; position: absolute; bottom: -1px; left: 0; width: 42px; height: 3px; background: #1b6599; }
.article-category { display: flex; align-items: center; gap: .6rem; color: #0e5f42; font-size: .85rem; font-weight: 650; }
.article-category .post-category-icon { width: 32px; height: 32px; animation: none; transition: transform .2s ease; }
.article-category a { color: inherit; text-decoration: none; }
.article-category a:is(:hover, :focus-visible) { text-decoration: underline; }
.article-category:hover .post-category-icon { transform: rotate(-8deg); }
.post-page .article-header h1 { font-family: "Caveat", "Segoe Print", cursive; font-weight: 600; font-size: clamp(2rem, 4.5vw, 2.5rem); line-height: 1.15; letter-spacing: 0; overflow-wrap: anywhere; text-wrap: pretty; }
.post-page .article-header > p { font-size: 1rem; line-height: 1.65; }
.article-toc { margin: 1.25rem 0 .5rem; font-size: .93rem; }
.article-toc summary { width: fit-content; min-height: 44px; padding: .55rem .25rem .55rem 0; color: #124f8b; font-weight: 650; cursor: pointer; }
.article-toc summary::marker { color: #1b6599; }
.article-toc nav { padding: 0 0 .75rem; }
.article-toc ul { padding-left: 1.3rem; margin: .25rem 0; list-style-type: square; }
.article-toc li { padding: .15rem 0; overflow-wrap: anywhere; }
.article-toc li::marker { color: #8ca9bd; }
.article-toc a { display: inline-block; padding: .2rem 0; }
.post-page .prose { max-width: 68ch; padding-top: .75rem; padding-bottom: 1.5rem; }
.post-page .prose:empty { padding: 0; }
.post-page .prose h2 { font-size: 1.4rem; letter-spacing: -.015em; }
.post-page .prose h3 { font-size: 1.15rem; }
.post-page .prose :is(h4, h5, h6) { font-size: 1rem; line-height: 1.3; }
.post-page .prose h1 { font-size: 1.6rem; line-height: 1.25; }
.post-page .prose :is(h1, h2, h3, h4, h5, h6) { overflow-wrap: anywhere; scroll-margin-top: 1.5rem; }
.post-page .prose blockquote { border-color: #8ca9bd; }
.post-page .prose pre { border-radius: 6px; }
.post-page .prose pre code.language-mermaid { white-space: pre-wrap; overflow-wrap: anywhere; }
.post-page .prose figure { margin: 1.75rem 0; }
.post-page .prose figcaption { margin-top: .6rem; color: #5f6865; font-size: .85rem; line-height: 1.5; }
.post-page .prose a { text-decoration-thickness: 1px; }
.post-page .prose a:hover { text-decoration-thickness: 2px; }
.post-page ::selection { color: #0f1822; background: #dbeaf4; }
.article-end { display: flex; justify-content: center; align-items: center; gap: 7px; padding: .75rem 0 2.75rem; }
.article-end span { width: 5px; height: 5px; background: #8ca9bd; }
.article-end span:nth-child(2) { width: 7px; height: 7px; background: #1b6599; transform: rotate(45deg); }
.post-page .photo-gallery { padding-bottom: 1.5rem; }
.post-page .photo-gallery h2 { font-size: 1.4rem; }
.post-page .journal-footer { margin-top: 2.5rem; }
@media (prefers-reduced-motion: reduce) { .article-category .post-category-icon, .article-category:hover .post-category-icon { transition: none; transform: none; } }

/* About-page reading content shares the journal's typography and rules. */
.home-body { font-size: 17px; }
.home-page .page { width: 100%; margin: 0; padding: 0; }
.home-page .about-me > h2 { margin: 0; font-size: 1.9rem; line-height: 1.25; letter-spacing: -.02em; }
.home-page .about-me { padding: 3.2rem 0 0; }
.home-page .sections { margin-top: 1rem; }
.home-page .section { display: grid; grid-template-columns: 9rem minmax(0, 1fr); gap: 1.5rem; align-items: start; padding: 1.7rem 0; }
.home-page .section:first-child { padding-top: 1.7rem; border-top: 1px solid #cbd7df; }
.home-page .section-label { display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: .55rem; min-height: 0; color: var(--accent); text-align: center; }
.home-page .section-label h3 { margin: 0; font-size: 1.05rem; font-weight: 700; line-height: 1.5; text-transform: none; }
.home-page .icon { display: block; width: 36px; height: 36px; }
.home-page .section-summary { margin: 0 0 .9rem; color: #45504d; }
.home-page .bullet-list { display: block; list-style: disc; padding-left: 1.2rem; }
.home-page .bullet-list li { padding-left: 0; margin: .65rem 0; }
.home-page .bullet-list li::before { display: none; }
.home-page .footer { padding: 1.5rem 0 2.5rem; }
.home-page .email-button { box-shadow: none; border-radius: 2px; }
.home-page .copyright { margin: 0; }
@media (max-width: 600px) {
  .journal-page { --post-columns: min(3.1rem, 16%) minmax(0, 1fr) min(4.8rem, 26%); --post-gap: min(.65rem, 3vw); width: min(100% - 28px, 760px); }
  .journal-header { padding-top: 1.4rem; }
  .post-page .journal-header { padding-top: 1.4rem; gap: 1rem; }
  .post-page .site-nav { gap: 1rem; }
  .journal-intro { padding-top: 2.8rem; }
  .article-header { padding-top: 2rem; }
  .post-list .post-date { font-size: .8rem; }
  .post-list .post-meta { gap: .35rem; }
  .post-list .post-category { font-size: .72rem; overflow-wrap: anywhere; }
  .post-list .post-category-icon { width: 23px; height: 23px; }
  .post-list h2, .post-list h3 { font-size: 1.6rem; }
  .home-page .section { display: block; }
  .home-page .section-label { flex-direction: row; align-items: center; justify-content: flex-start; margin-bottom: .5rem; text-align: left; }
  .home-page .icon { width: 30px; height: 30px; }
  .gallery-grid { grid-template-columns: 1fr; }
}
@media (max-width: 360px) {
  .post-page .prose table { font-size: .92em; }
  .post-page .prose :is(th, td) { padding: .35rem .45rem; }
}
