/* Blog index, blog posts and the /tools/ library. Layout and sizes follow the Astryx blog (752px column, centred head, category pills). */
.listing { max-width: 792px; }
.listing.wide { max-width: 1040px; }
.listhead { text-align: center; padding: 56px 0 8px; }
.listhead h1 { margin: 0 0 10px; }
.listhead p { margin: 0 auto; max-width: 56ch; color: var(--mute); font-size: 1rem; line-height: 1.5; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 28px 0 40px; }
.pill { font: 500 .875rem/1 var(--sans); color: var(--ink); background: transparent; border: 0; padding: 9px 12px; border-radius: 999px; cursor: pointer; }
.pill:hover { background: var(--chip); }
.pill[aria-pressed="true"] { background: var(--chip); font-weight: 600; }
.feed { display: flex; flex-direction: column; gap: 48px; }
.feed .pcard.lead .cover { border-radius: 16px; }
.pgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 20px; }
.feed.filtered { gap: 0; }
.feed.filtered .pcard.lead { display: none; }
.feed.filtered .pgrid { margin-top: 0; }
@media (max-width: 640px) { .pgrid { grid-template-columns: 1fr; } }

.search { max-width: 520px; margin: 28px auto 0; }
.search input { width: 100%; font: 400 1rem var(--sans); padding: 14px 20px; border-radius: 999px; border: 1px solid var(--line); background: var(--page); color: var(--ink); }
.search input::placeholder { color: var(--mute); }
.listing .tgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 24px; }
@media (max-width: 900px) { .listing .tgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .listing .tgrid { grid-template-columns: 1fr; } }
.none { text-align: center; color: var(--mute); margin-top: 24px; }

/* article */
.article { max-width: 792px; }
.article h1 { margin-top: 18px; }
.article .lead { margin-bottom: 18px; }
.article .byline { margin: 0 0 28px; }
.hero-cover { margin: 0 0 8px; border-radius: 16px; overflow: hidden; aspect-ratio: 16 / 9; background: var(--card); }
.hero-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.article .prose { margin-top: 32px; max-width: none; font-size: 1.06rem; }
.article .prose h2 { font-weight: 600; letter-spacing: -0.02em; }
.post .cta { margin-top: 48px; padding: 28px 32px; background: var(--tile); color: var(--ink); border-radius: 16px; display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.post .cta b { display: block; font-size: 1.2rem; }
.post .cta small { display: block; color: var(--mute); font-size: .95rem; margin-top: 4px; }
.post .cta .btn { text-decoration: none; display: inline-block; color: var(--bg); }
.article .more .pgrid { gap: 32px 20px; }

/* floating objects around the blog title (motion.js adds pointer parallax; CSS adds the slow bob) */
.listhead.float { position: relative; }
.floaters { position: absolute; inset: 0; pointer-events: none; }
.floaters img { position: absolute; width: 104px; height: 104px; border-radius: 26px; object-fit: cover; box-shadow: 0 18px 36px -20px rgba(0,0,0,.45);
  transform: translate(var(--px, 0), var(--py, 0)) rotate(var(--r, 0deg)); animation: bob 7s ease-in-out infinite; }
.floaters img:nth-child(1) { left: -150px; top: 30px; --r: -8deg; }
.floaters img:nth-child(2) { left: -60px; top: 170px; width: 76px; height: 76px; border-radius: 20px; --r: 6deg; animation-delay: -2s; animation-duration: 8s; }
.floaters img:nth-child(3) { right: -150px; top: 20px; --r: 7deg; animation-delay: -4s; animation-duration: 9s; }
.floaters img:nth-child(4) { right: -50px; top: 160px; width: 80px; height: 80px; border-radius: 20px; --r: -5deg; animation-delay: -1s; }
@keyframes bob { 50% { translate: 0 -14px; } }
@media (max-width: 1100px) { .floaters { display: none; } }
@media (prefers-reduced-motion: reduce) { .floaters img { animation: none; } }
