/* Altered Book Artists. Palette paper-grey-brass (newsprint ground, near-black ink, brass accent), Bricolage Grotesque / Figtree.
   Signature: the guides hang as manila shipping tags from a line of twine. */
:root {
  --bg: #e8e8e3; --surface: #dcdcd6; --ink: #181715; --muted: #5c5b56; --line: #c9c9c2;
  --accent: #bfb21a; --deep: #181715; --deep-2: #242321; --on-deep: #e8e8e3; --on-deep-muted: #91908d;
  --manila: #e9dcb4; --twine: #8a7a55;
  --display: "Bricolage Grotesque", system-ui, sans-serif; --sans: "Figtree", system-ui, sans-serif;
  --wrap: 1200px; --gut: clamp(16px, 4vw, 40px); --radius: 8px;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 24px; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 18px/1.6 var(--sans); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--accent); text-decoration-thickness: 3px; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; box-shadow: 0 0 0 6px var(--accent); }
h1, h2, h3 { font-family: var(--display); font-weight: 500; font-stretch: 94%; letter-spacing: -0.03em; line-height: 1.04; margin: 0; text-wrap: balance; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--accent); color: var(--ink); padding: 10px 14px; z-index: 10; }
.skip:focus { left: 8px; }
.eyebrow { font: 500 13px/1.4 var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.eyebrow a { text-decoration: none; }
.lede { font-size: 20px; line-height: 1.55; color: var(--ink); max-width: 38em; }

/* masthead */
.masthead { border-bottom: 1px solid var(--line); background: var(--bg); }
.masthead .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 72px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font: 600 22px/1 var(--display); font-stretch: 90%; letter-spacing: -0.02em; text-decoration: none; }
.mark { width: 32px; height: 32px; }
.nav { display: flex; gap: 6px 22px; flex-wrap: wrap; font-size: 16px; }
.nav a { text-decoration: none; padding: 10px 0; }
.nav a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 3px; }

/* buttons */
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; font: 500 16px/1 var(--sans); text-decoration: none;
       border: 1.5px solid var(--ink); border-radius: var(--radius); transition: transform .15s, background .15s; }
.btn:hover { transform: translateY(-1px); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-solid { background: var(--ink); color: var(--bg); }
.btn-solid:hover { background: #2c2a26; }
.textlink { font-weight: 500; text-underline-offset: 5px; align-self: center; padding: 12px 4px; }

/* hero: the page beneath. The altered copy of the spread shows through an oval that follows the pointer;
   touch screens develop into it once; reduced motion shows it still. */
.hero-reveal { --mx: 66%; --my: 52%; position: relative; overflow: hidden; display: flex; min-height: calc(100svh - 73px);
               background: var(--deep); color: var(--on-deep); }
.hr-plain, .hr-altered { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hr-altered { -webkit-mask-image: radial-gradient(closest-side, #000 58%, transparent 100%); mask-image: radial-gradient(closest-side, #000 58%, transparent 100%);
              -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-size: 480px 400px; mask-size: 480px 400px;
              -webkit-mask-position: calc(var(--mx) - 240px) calc(var(--my) - 200px); mask-position: calc(var(--mx) - 240px) calc(var(--my) - 200px); }
.hr-scrim { position: absolute; inset: 0; pointer-events: none;
            background: linear-gradient(180deg, rgba(24, 23, 21, .8) 0%, rgba(24, 23, 21, .42) 32%, rgba(24, 23, 21, .1) 54%, rgba(24, 23, 21, .82) 100%); }
.hr-content { position: relative; z-index: 2; display: flex; flex-direction: column; justify-content: space-between; gap: 40px; width: 100%;
              padding-top: clamp(32px, 5vw, 64px); padding-bottom: clamp(28px, 4vw, 52px); pointer-events: none; }
.hr-content a { pointer-events: auto; }
.hr-big { display: block; font-size: clamp(50px, 7vw, 116px); line-height: .94; letter-spacing: -0.045em; max-width: 11ch; text-shadow: 0 2px 28px rgba(0, 0, 0, .35); }
.hr-sub { display: block; margin-top: 20px; font: 500 clamp(16px, .9vw + 11px, 20px)/1.4 var(--sans); letter-spacing: .01em; color: var(--on-deep); text-shadow: 0 1px 12px rgba(0, 0, 0, .5); }
.hr-sub::before { content: ""; display: inline-block; width: 32px; height: 3px; margin-right: 12px; vertical-align: middle; background: var(--accent); }
.hr-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; }
.hr-foot .lede { max-width: 30em; color: var(--on-deep); font-size: 18px; }
.hr-foot .actions { margin-top: 0; flex: none; }
.hero-reveal .btn-solid { background: var(--accent); border-color: var(--accent); color: var(--ink); }
.hero-reveal .btn-solid:hover { background: #d3c62c; }
.hero-reveal .textlink { color: var(--on-deep); }
.hero-reveal :focus-visible { outline-color: var(--on-deep); }
@media (prefers-reduced-motion: no-preference) {
  .hr-content { animation: rise .7s ease-out both; }
  @keyframes rise { from { opacity: 0; transform: translateY(14px); } }
}
@media (hover: none), (pointer: coarse) {
  .hr-altered { -webkit-mask-image: none; mask-image: none; opacity: 0; animation: develop 2.4s 1s ease-out forwards; }
  @keyframes develop { to { opacity: 1; } }
}
@media (prefers-reduced-motion: reduce) { .hr-altered { -webkit-mask-image: none; mask-image: none; opacity: 1 !important; } }

/* contents: the guides numbered like a book's contents page */
.contents { list-style: none; margin: 28px 0 0; padding: 0; border-top: 2px solid var(--ink); }
.contents a { display: grid; grid-template-columns: 76px minmax(0, 1fr) auto; gap: 6px 24px; align-items: baseline; padding: 22px 0;
              border-bottom: 1px solid var(--line); text-decoration: none; }
.c-no { font: 500 clamp(28px, 1.6vw + 14px, 40px)/1 var(--display); font-variant-numeric: tabular-nums; color: var(--muted); transition: color .2s; }
.c-title { font: 500 clamp(22px, 1.1vw + 15px, 30px)/1.15 var(--display); font-stretch: 94%; letter-spacing: -0.02em; text-decoration: underline;
           text-decoration-color: transparent; text-decoration-thickness: 3px; text-underline-offset: 5px; transition: text-decoration-color .2s; }
.c-meta { font-size: 14px; color: var(--muted); white-space: nowrap; }
.contents a:hover .c-title { text-decoration-color: var(--accent); }
.contents a:hover .c-no { color: var(--ink); }

/* sections */
.section { padding: clamp(48px, 6vw, 96px) 0; }
.section + .section { padding-top: 0; }
.section h2, .more h2 { font-size: clamp(32px, 2vw + 18px, 52px); }
.head-row { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.head-row a { font-weight: 500; padding: 12px 0; }

/* three crafts */
.crafts { list-style: none; margin: 36px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 28px; }
.craft-pic { display: block; overflow: hidden; border-radius: var(--radius); background: var(--surface); }
.craft-pic img { aspect-ratio: 3 / 2; object-fit: cover; transition: transform .3s; }
.craft:hover .craft-pic img { transform: scale(1.025); }
.craft h3 { margin-top: 10px; font-size: 30px; }
.craft h3 a { display: inline-block; padding: 7px 0; text-decoration: none; }
.craft p { margin-top: 10px; color: var(--muted); font-size: 17px; }
.craft .latest { color: var(--ink); font-size: 16px; }

/* cards (related guides, 404) */
.cards { list-style: none; margin: 32px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 40px 28px; }
.no { color: var(--ink); font-weight: 600; }
.card .thumb { display: block; overflow: hidden; margin-bottom: 16px; background: var(--surface); border-radius: var(--radius); }
.card .thumb img { aspect-ratio: 16 / 9; object-fit: cover; transition: transform .3s; }
.card:hover .thumb img { transform: scale(1.025); }
.card h3 { margin-top: 8px; font-size: 26px; line-height: 1.12; }
.card h3 a { text-decoration: none; }
.card h3 a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 3px; }
.rows { list-style: none; margin: 0; padding: 0; }
.rows li { padding: 14px 0; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 16px; align-items: baseline; }
.rows li a { font: 500 22px/1.25 var(--display); font-stretch: 94%; letter-spacing: -0.015em; text-decoration: none; }
.rows li a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 3px; }
.rows li .eyebrow { white-space: nowrap; text-transform: none; letter-spacing: 0; font-size: 14px; }

/* Sponsor (Wordfully): a band on the home page only, after the three crafts. */
.supporter { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px 32px; max-width: 52rem; margin: 0 auto;
             padding: 22px 26px; background: var(--surface); border: 1px solid var(--line); border-top: 4px solid var(--accent); border-radius: var(--radius); }
.supporter__label { grid-column: 1 / -1; font: 600 12px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.supporter__logo { display: inline-block; line-height: 0; }
.supporter__logo img { width: 132px; height: auto; }
.supporter__text { font-size: 16px; line-height: 1.55; }
.supporter__text a { text-decoration-color: var(--accent); text-decoration-thickness: 2px; }
.supporter__cta { white-space: nowrap; }

/* pages */
.crumbs { font-size: 15px; color: var(--muted); padding-top: 28px; }
.section > .wrap > .crumbs:first-child { padding-top: 0; }
.crumbs a { color: var(--muted); }
.section:has(> .wrap > .crumbs:first-child) { padding-top: 32px; }
.page-title { margin-top: 18px; font-size: clamp(42px, 3vw + 20px, 68px); }
.section .lede { margin-top: 14px; }
.browse { margin-top: 48px; font-size: clamp(28px, 1.4vw + 18px, 36px); }
.groups { display: grid; gap: 56px; margin-top: 36px; }
.group { scroll-margin-top: 24px; }
.group .intro { margin-top: 8px; color: var(--muted); max-width: 40em; }
.group .rows { margin-top: 18px; }

/* article */
.article-head { padding-bottom: 28px; }
.article-head .eyebrow { margin-top: 28px; }
.article-head h1 { margin-top: 10px; font-size: clamp(40px, 3.2vw + 16px, 70px); max-width: 22ch; }
.meta { margin-top: 18px; font-size: 15px; color: var(--muted); }
.author-head { margin-top: 28px; }
.author-profile { display: flex; align-items: center; gap: 24px; margin-top: 20px; }
.author-avatar { width: 100px; height: 100px; border-radius: 50%; object-fit: cover; border: 2px solid var(--line); flex-shrink: 0; box-shadow: 0 4px 12px rgba(24, 23, 21, .08); }
.author-info h1 { margin-top: 4px; }
.author-email { margin-top: 6px; font-size: 15px; color: var(--muted); }
.author-email a { color: var(--ink); font-weight: 500; text-decoration: underline; text-underline-offset: 3px; }
.author-email a:hover { text-decoration-color: var(--accent); }
.author-head .bio { margin-top: 20px; max-width: 44em; font-size: 19px; line-height: 1.6; }
.entries { list-style: none; margin: 48px 0 0; padding: 0; display: grid; gap: 40px; }
.entry { display: grid; grid-template-columns: minmax(0, 380px) minmax(0, 1fr); gap: 32px; align-items: center; }
.entry .thumb { display: block; overflow: hidden; background: var(--surface); border-radius: var(--radius); }
.entry .thumb img { aspect-ratio: 16 / 9; object-fit: cover; transition: transform .3s; }
.entry:hover .thumb img { transform: scale(1.025); }
.entry h2 { margin-top: 8px; font-size: clamp(24px, 1vw + 18px, 32px); line-height: 1.12; }
.entry h2 a { text-decoration: none; }
.entry h2 a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 3px; }
.entry .excerpt { margin-top: 10px; color: var(--muted); max-width: 46em; }
.entry .meta { margin-top: 10px; }
.toc { margin-top: 28px; padding: 18px 20px; background: var(--surface); border-radius: var(--radius); }
.toc ol { margin: 10px 0 0; padding-left: 1.3em; columns: 2 18rem; column-gap: 32px; font-size: 16px; }
.toc li { break-inside: avoid; }
.toc a { display: inline-block; padding: 10px 0; line-height: 1.4; text-decoration: none; }
.toc a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 3px; }
.prose h2 { scroll-margin-top: 20px; }
.hero-img img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius); }
.prose { padding-top: 40px; padding-bottom: 64px; font-size: 19px; line-height: 1.7; }
.prose > * + * { margin-top: 1em; }
.prose h2 { margin-top: 1.9em; font-size: clamp(28px, 1.3vw + 20px, 36px); line-height: 1.1; }
.prose h3 { margin-top: 1.5em; font-size: 25px; }
.prose ul, .prose ol { padding-left: 1.2em; }
.prose li + li { margin-top: .4em; }
.prose blockquote { margin: 1.5em 0; padding: 4px 0 4px 22px; border-left: 4px solid var(--accent); font-style: italic; }
.prose figure { margin: 2em 0; }
.prose figure img { border-radius: var(--radius); }
.prose a { text-decoration-color: color-mix(in srgb, var(--ink) 45%, transparent); }
.prose a:hover { text-decoration-color: var(--accent); }
.more { background: var(--surface); padding: clamp(48px, 6vw, 80px) 0; }

/* footer */
.footer { background: var(--deep); color: var(--on-deep); padding: 48px 0 40px; }
.footer .wrap { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 40px; align-items: start; }
.footer p { margin-top: 10px; color: var(--on-deep-muted); font-size: 16px; }
.footer nav { display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 16px; }
.footer nav a { padding: 10px 0; }
.footer .legal { grid-column: 1 / -1; font-size: 14px; }

@media (max-width: 1023px) {
  .hr-foot { flex-direction: column; align-items: flex-start; }
  .crafts { grid-template-columns: minmax(0, 1fr); }
  .craft { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 0 24px; align-items: start; }
  .craft-pic { grid-row: span 3; }
  .craft h3 { margin-top: 0; }
  .supporter { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 639px) {
  .author-profile { gap: 16px; }
  .author-avatar { width: 80px; height: 80px; }
  .entry { grid-template-columns: 1fr; gap: 14px; }
  .contents a { grid-template-columns: 44px minmax(0, 1fr); }
  .c-meta { grid-column: 2; }
  .hr-foot .actions { width: 100%; }
  body { font-size: 17px; }
  .masthead .wrap { padding-block: 8px; gap: 2px 16px; min-height: 0; }
  .brand { font-size: 20px; }
  .nav { display: grid; grid-template-columns: repeat(2, auto); justify-content: start; gap: 0 24px; font-size: 15px; width: 100%; }
  .nav a { padding: 12px 0; }
  .craft { display: block; }
  .craft h3 { margin-top: 16px; }
  .rows li { flex-direction: column; gap: 4px; }
  .prose { font-size: 18px; }
  .footer .wrap { grid-template-columns: minmax(0, 1fr); }
  .actions .btn, .supporter__cta { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
