/* Halftone dots: gray images with a dot screen that clears on hover, dotted dividers. */
:root { --dot: var(--accent); }

/* images: gray + dot screen, original on hover */
.dotimg { position: relative; display: block; width: fit-content; max-width: 100%; margin: 1.25rem 0; }
.dotimg img { display: block; margin: 0 !important; max-width: 100%; height: auto; filter: grayscale(1) contrast(1.05); transition: filter .3s; }
.dotimg::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; transition: opacity .3s;
  background: radial-gradient(circle, rgba(0,0,0,.5) .8px, transparent 1.3px) 0 0 / 4px 4px;
}
.dotimg:hover img { filter: none; }
.dotimg:hover::after { opacity: 0; }
/* wide screenshots stay readable on small screens: no screen on touch */
@media (hover: none) { .dotimg::after { opacity: .5; } }

/* Dot fields: standalone strips (see rosecurify.js). Size comes from the variant class. */
.dot-field { display: block; pointer-events: none; }
.dot-thin { height: 12px; }
.dot-wide { height: 48px; }
.dot-block { width: 100%; max-width: 1136px; margin: 1.25rem auto;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent); }
.dot-header { width: 100%; margin: 0;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent); }
header::after { display: none !important; }
header.site { border-bottom: 0 !important; }
.site-footer { border-top: 0 !important; margin-top: 2rem !important; }
.site-footer .dot-block { margin-top: 0; }

/* header uses the exact page background (index.css tinted it cream/warm black) */
body header.site, body.light header.site, body:not(.light) header.site { background: var(--bg) !important; backdrop-filter: none; -webkit-backdrop-filter: none; }

/* header and footer match: page background, thin dot strip, same spacing */
header.site { padding-bottom: 0 !important; }
.dot-header { margin-top: 28px !important; }
.site-footer, footer.site-footer { background: var(--bg) !important; padding: 0 0 1.5rem !important; margin-top: 2rem !important; }
.site-footer .dot-block { margin: 0 0 28px; max-width: none; }

/* reading time / link count sits in the date + tags row */
.post-meta .rt { color: var(--muted); }
.post-meta .rt b { color: var(--fg); font-weight: 500; }

/* single dot row under the title block */
.dot-block.dot-one { height: 4px; margin-top: 12px; }
.post-hero { padding-bottom: 0 !important; }
.post-hero .wrap > :last-child { margin-bottom: 0 !important; }

/* Agave (SIL OFL, see /fonts/Agave-LICENSE.txt): body text. Headings, nav and code keep the mono face. */
@font-face { font-family: 'Agave'; src: url('/fonts/AgaveCode.ttf') format('truetype'); font-weight: 400; font-style: normal; font-display: swap; }
:root { --sans: 'Agave', 'Inter', system-ui, -apple-system, sans-serif; }
#postBody, article { font-size: 18px; line-height: 1.7; }

/* title scramble: hide the glitch overlay layers while the text resolves */
h1.scrambling .glitch::before, h1.scrambling .glitch::after { display: none !important; }
