/* Prompt library. Layered on styles.css; reuses its tokens.
   Preview-only stylesheet: styles.css is untouched. */

.lib-hero { padding: 0 0 22px; max-width: 720px; margin: 0; }
.lib-hero__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(30px, 4vw, 42px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
}
.lib-hero__lede {
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink-soft);
  max-width: 62ch;
  margin: 0;
}
.lib-hero__logos {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 22px;
  color: var(--ink-mute);
  font-size: 12px;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.lib-hero__logos span {
  padding: 5px 11px;
  border: 1px dashed var(--line);
  border-radius: 0;
}

/* ---------- list ---------- */

.lib-list { max-width: 940px; margin: 0 auto; padding: 8px 24px 80px; }

.pl-group { padding-top: 44px; scroll-margin-top: 215px; }
.pl-group__head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 18px;
}
.pl-group__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 25px;
  letter-spacing: -0.01em;
  margin: 0;
}
.pl-group__count {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-mute);
}
.pl-group__items { display: flex; flex-direction: column; gap: 12px; }

/* ---------- prompt card ---------- */

.pl {
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--bg-elev);
  padding: 15px 17px 13px;
  box-shadow: var(--shadow-card);
  scroll-margin-top: 215px;
  transition: border-color 130ms, box-shadow 130ms;
}
.pl:hover { border-color: var(--line); }

.pl__head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.pl__head--bare { margin-bottom: 6px; }
.pl__title {
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: -0.005em;
  margin: 0;
  color: var(--ink);
}
.pl__tool {
  margin-left: auto;
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 8px;
  border-radius: 0;
  border: 1px solid var(--line);
  color: var(--ink-mute);
  background: var(--bg-tint);
}

/* the documented weak phrasing */
.pl__weak {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 8px;
  padding-left: 11px;
  border-left: 2px solid var(--line);
}
.pl__weak-tag {
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-mute);
}
.pl__weak-text {
  font-size: 13px;
  color: var(--ink-mute);
  text-decoration: line-through;
  text-decoration-color: var(--line);
}

.pl__prompt {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 11px 13px;
  background: var(--bg-tint);
  border-left: 2px solid var(--accent-soft);
  border-radius: 0;
}
.pl__prompt-text {
  flex: 1;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.65;
  color: var(--ink);
  white-space: pre-wrap;
  word-break: break-word;
}
.pl__prompt .copy { opacity: 0; margin-top: -2px; }
.pl:hover .pl__prompt .copy,
.pl__prompt .copy:focus-visible { opacity: 1; }

.pl__code-wrap { position: relative; }
.codeblock--sm { padding: 12px 14px; }
.codeblock--sm code { font-size: 12px; }
.pl__shell { margin-top: 10px; }

.pl__src {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 11px;
  font-size: 11.5px;
  color: var(--ink-mute);
  text-decoration: none;
}
.pl__src:hover { color: var(--accent-ink); }
.pl__src svg { width: 11px; height: 11px; }

.empty {
  padding: 70px 0;
  text-align: center;
  color: var(--ink-mute);
  font-size: 14px;
}

@media (max-width: 720px) {
  .filters { padding: 12px 20px 10px; }
  .lib-list { padding-left: 20px; padding-right: 20px; }
  .lib-hero { padding-left: 20px; padding-right: 20px; }
  .chip-row__label { display: none; }
  .pl__prompt .copy { opacity: 1; }
  .search__count { display: none; }
}

/* The shared header is translucent by design on the tips page. Over a dense
   prompt list, card text ghosts through it, so opt this page out. */
.site-header { background: var(--bg); backdrop-filter: none; }

/* ---------- expanded templates ---------- */

.pl--template { border-color: var(--line); }

.pl__tags { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 9px; }
.tag {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 3px 8px;
  border-radius: 0;
  border: 1px solid var(--line);
  color: var(--ink-mute);
}
.tag--req { color: var(--ink-mute); border-color: var(--line); background: var(--bg); }
.tag--seq { color: var(--accent-ink); border-color: var(--wash-line); background: var(--accent-soft); }
.tag--any { color: var(--accent-ink); border-color: var(--wash-line); background: var(--accent-soft); }

.pl__prompt--template { border-left-color: var(--accent); background: var(--accent-soft); }

/* the parts you replace */
.slot {
  background: var(--accent-soft);
  color: var(--accent-ink);
  border-radius: 0;
  padding: 0 2px;
  font-weight: 500;
}

.pl__why {
  margin: 9px 0 0;
  font-size: 12.5px;
  font-style: italic;
  line-height: 1.5;
  color: var(--ink-mute);
  padding-left: 10px;
  border-left: 2px solid var(--line);
}

.pl__orig { margin-top: 10px; }
.pl__orig summary {
  font-size: 11.5px;
  color: var(--ink-mute);
  cursor: pointer;
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  user-select: none;
}
.pl__orig summary::-webkit-details-marker { display: none; }
.pl__orig summary::before { content: "\25B8"; font-size: 9px; transition: transform 120ms; }
.pl__orig[open] summary::before { transform: rotate(90deg); }
.pl__orig summary:hover { color: var(--accent-ink); }
.pl__orig-body {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 8px;
  padding: 9px 12px;
  background: var(--bg-tint);
  border-radius: 0;
}
.pl__orig-text {
  flex: 1;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.6;
  color: var(--ink-mute);
  white-space: pre-wrap;
  word-break: break-word;
}

/* copy is this page's whole purpose: always reachable, not hover-only */
.pl__prompt .copy, .pl__orig-body .copy { opacity: 0.55; }
.pl:hover .pl__prompt .copy,
.pl__prompt .copy:focus-visible,
.pl__orig-body .copy:focus-visible,
.pl:hover .pl__orig-body .copy { opacity: 1; }

.chip.is-empty { opacity: 0.4; }

/* ---------- tool marks ---------- */

.marks {
  margin-left: auto;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--ink-mute);
}
.mark {
  display: grid;
  place-items: center;
  width: 21px; height: 21px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--bg-tint);
}
.mark svg { width: 13px; height: 13px; display: block; }
.marks__note {
  font-family: var(--font-mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-mute);
  margin-left: 3px;
}

/* why now leads the card */
.pl--template .pl__why {
  margin: 0 0 11px;
  padding-left: 0;
  border-left: none;
  font-style: normal;
  font-size: 13px;
  color: var(--ink-soft);
  line-height: 1.55;
}

.pl--template .pl__tags { margin-bottom: 9px; }
.pl--template .pl__src { margin-top: 10px; }

@media (max-width: 720px) {
  .marks__note { display: none; }
}
.pl__src-pub { color: var(--ink-mute); }
.pl__src:hover .pl__src-pub { color: var(--accent-ink); }

/* ---------- works-in row + source logo ---------- */

.marks__label {
  font-family: var(--font-mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--ink-mute);
  margin-right: 2px;
}
.marks .mark { background: var(--bg-elev); }

.pl__srcrow { display: flex; align-items: center; gap: 8px; margin-top: 11px; }
.pl--template .pl__src { margin-top: 0; }

.src-mark {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 22px; height: 22px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--bg-elev);
  cursor: pointer;
}
.src-mark svg { width: 13px; height: 13px; display: block; }
.src-mark:hover { border-color: var(--accent); background: var(--accent-soft); }
/* The source mark filters, but never reflects filter state: it identifies
   where the prompt came from, so highlighting it reads as a data change. */
.src-mark.is-on, .src-mark.is-empty { background: none; opacity: 1; }
.src-mark.is-on:hover { background: var(--accent-soft); }


/* Official brand marks supply their own colour and shape. */
.mark, .src-mark {
  border: none;
  background: none;
  width: 18px; height: 18px;
}
.mark svg, .src-mark svg { width: 18px; height: 18px; }
.src-mark { width: 20px; height: 20px; border-radius: 0; }
.src-mark svg { width: 16px; height: 16px; }
.src-mark:hover { background: var(--accent-soft); }
.marks { gap: 7px; }
.marks .mark { background: none; }

/* ================= docs shell: sidebar + content ================= */

.shell {
  max-width: 1320px;
  margin: 0 auto;
  padding: 42px 28px 90px;
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  gap: 40px;
  align-items: start;
}

.side { position: sticky; top: calc(var(--header-h) + 22px); }
.side__inner {
  max-height: calc(100vh - var(--header-h) - 44px);
  overflow-y: auto;
  padding-right: 6px;
  padding-bottom: 8px;
}

.hero-search {
  position: relative;
  display: flex;
  align-items: center;
  margin-top: 22px;
  max-width: 480px;
  background: var(--bg-tint);
  border: 1px solid var(--line);
  border-radius: 0;
  transition: border-color 130ms, background 130ms, box-shadow 130ms;
}
.hero-search:focus-within {
  border-color: var(--accent);
  background: var(--bg-elev);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.hero-search__icon {
  width: 17px; height: 17px;
  margin-left: 13px;
  flex-shrink: 0;
  color: var(--ink-mute);
}
.hero-search:focus-within .hero-search__icon { color: var(--accent-ink); }
.hero-search input {
  flex: 1;
  min-width: 0;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink);
  background: none;
  border: none;
  padding: 11px 10px;
  outline: none;
}
.hero-search input::placeholder { color: var(--ink-mute); }
.hero-search input::-webkit-search-cancel-button { display: none; }

.hero-search__clear {
  flex-shrink: 0;
  width: 24px; height: 24px;
  display: grid;
  place-items: center;
  margin-right: 8px;
  border: none;
  border-radius: 0;
  background: none;
  color: var(--ink-mute);
  cursor: pointer;
}
.hero-search__clear:hover { background: var(--line-soft); color: var(--ink); }
.hero-search__clear svg { width: 13px; height: 13px; }
.hero-search__clear[hidden] { display: none; }

.hero-search__kbd {
  flex-shrink: 0;
  margin-right: 11px;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1;
  color: var(--ink-mute);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 0;
  padding: 4px 7px;
}
.hero-search__kbd[hidden] { display: none; }



.nav__label {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink-mute);
  margin: 0 0 7px;
  padding-left: 9px;
}
.nav__list { list-style: none; margin: 0 0 22px; padding: 0; }
.nav__list li { margin: 0; }

.nav__item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: inherit;
  font-size: 13.5px;
  text-align: left;
  color: var(--ink-soft);
  background: none;
  border: none;
  border-left: 2px solid transparent;
  border-radius: 0;
  padding: 6px 9px 6px 9px;
  cursor: pointer;
  transition: color 120ms, background 120ms, border-color 120ms;
}
.nav__text { flex: 1; min-width: 0; }
.nav__item:hover { color: var(--ink); background: var(--bg-tint); }
.nav__item.is-on {
  color: var(--accent-ink);
  font-weight: 500;
  border-left-color: var(--accent);
  background: var(--accent-soft);
}
.nav__item .chip__n {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--ink-mute);
  flex-shrink: 0;
}
.nav__item.is-on .chip__n { color: var(--accent-ink); }
.nav__list li[hidden] { display: none; }


.clear {
  font-family: inherit;
  font-size: 12.5px;
  color: var(--accent-ink);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 9px;
}
.clear:hover { text-decoration: underline; }

/* ---------- content column ---------- */

.content__bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 2px 14px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 6px;
}
.content__count {
  font-family: var(--font-mono);
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-mute);
}
.content__count b { color: var(--ink); font-weight: 500; }
.expandall {
  margin-left: auto;
  font-family: inherit;
  font-size: 12.5px;
  color: var(--ink-soft);
  background: none;
  border: 1px solid var(--line);
  border-radius: 0;
  padding: 5px 11px;
  cursor: pointer;
}
.expandall:hover { border-color: var(--ink-mute); color: var(--ink); }

.lib-list { max-width: none; margin: 0; padding: 0; }

.pl-group:first-child { padding-top: 26px; }
.pl-group { padding-top: 34px; scroll-margin-top: 90px; }
.pl-group__head { padding-bottom: 12px; margin-bottom: 16px; }
.pl-group__title { font-size: 22px; }

/* three across, collapsing down */
.pl-group__items {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  /* stretch, not start: cards in a row match the tallest one, so the
     footer rules line up instead of stepping. */
  align-items: stretch;
}

/* ---------- collapsed card ---------- */

.pl {
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.pl__toggle {
  display: block;
  width: 100%;
  flex: 1;
  text-align: left;
  background: none;
  border: none;
  font: inherit;
  color: inherit;
  cursor: pointer;
  padding: 14px 15px 12px;
  position: relative;
}
.pl__toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }

.pl__head { display: flex; align-items: flex-start; gap: 9px; margin-bottom: 8px; }
.pl__title {
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.005em;
  color: var(--ink);
  flex: 1;
  min-width: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: calc(2 * 1.35em);
}
.pl__toggle .marks { margin-left: 0; margin-top: 1px; }
.pl__toggle .marks__label { display: none; }

.pl--template .pl__why,
.pl__why {
  margin: 0;
  padding: 0;
  border: none;
  font-style: normal;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--ink-soft);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: calc(3 * 1.5em);
}

.pl--template .pl__tags,
.pl__tags { margin: 9px 0 0; }

/* ---------- always-visible footer ---------- */

.pl__srcrow {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: auto;
  padding: 10px 13px 10px 12px;
  border-top: 1px solid var(--line-soft);
}
.pl__src { margin-top: 0; font-size: 11px; min-width: 0; flex: 1; }
.pl__src-pub { display: none; }
.pl__slots {
  margin-left: auto;
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-mute);
}

/* ---------- responsive ---------- */

@media (max-width: 1100px) {
  .pl-group__items { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; gap: 0; padding: 26px 20px 70px; }
  .pl-group__items { grid-template-columns: 1fr; }

  /* the nav becomes a sheet: inline, it would sit below every card */
  .side {
    position: fixed;
    /* top must be cleared: the desktop sticky rule sets it, and with both top
       and bottom the sheet stretches and only translates part of the way off */
    top: auto;
    left: 0; right: 0; bottom: 0;
    z-index: 95;
    max-height: 78vh;
    background: var(--bg-elev);
    border-top: 1px solid var(--line);
    border-radius: 0;
    box-shadow: 0 -18px 50px -20px rgba(7,7,10,0.3);
    transform: translateY(101%);
    transition: transform 220ms cubic-bezier(0.2,0.9,0.3,1);
    display: flex;
    flex-direction: column;
  }
  .side.is-open { transform: none; }
  .side__bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px 12px;
    border-bottom: 1px solid var(--line);
  }
  .side__bar-title { font-weight: 600; font-size: 14px; }
  .side__done {
    margin-left: auto;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    color: var(--accent-ink);
    background: none;
    border: none;
    padding: 4px 2px;
    cursor: pointer;
  }
  .side__inner { max-height: none; overflow-y: auto; padding: 16px 12px 26px; }
  .side-scrim {
    position: fixed;
    inset: 0;
    z-index: 94;
    background: rgba(7,7,10,0.4);
  }
  .side-scrim[hidden] { display: none; }
  body.has-sheet { overflow: hidden; }

  .filterbtn { display: inline-flex; }
  .lib-hero__title { font-size: 30px; }
  .content__bar { position: sticky; top: var(--header-h); background: var(--bg); z-index: 20; padding-top: 10px; }
}


/* ================= dialog ================= */

body.has-dialog { overflow: hidden; }

.dlg { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 24px; }
.dlg[hidden] { display: none; }

.dlg__scrim {
  position: absolute;
  inset: 0;
  background: rgba(7, 7, 10, 0.42);
  backdrop-filter: blur(2px);
  animation: dlg-fade 140ms ease;
}

.dlg__panel {
  position: relative;
  width: min(780px, 100%);
  max-height: min(86vh, 900px);
  display: flex;
  flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 0;
  box-shadow: 0 24px 70px -20px rgba(7, 7, 10, 0.34), 0 2px 6px rgba(7, 7, 10, 0.05);
  animation: dlg-rise 170ms cubic-bezier(0.2, 0.9, 0.3, 1);
}

@keyframes dlg-fade { from { opacity: 0; } }
@keyframes dlg-rise { from { opacity: 0; transform: translateY(10px) scale(0.985); } }
@media (prefers-reduced-motion: reduce) {
  .dlg__scrim, .dlg__panel { animation: none; }
}

.dlg__close {
  position: absolute;
  top: 12px; right: 12px;
  z-index: 2;
  width: 30px; height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 0;
  background: var(--bg-elev);
  color: var(--ink-mute);
  cursor: pointer;
}
.dlg__close:hover { background: var(--bg-tint); color: var(--ink); }
.dlg__close:focus-visible { outline: none; border-color: var(--accent); }
.dlg__close svg { width: 15px; height: 15px; }

.dlg__body { overflow-y: auto; padding: 24px 26px 22px; }

.dlg__head { margin-bottom: 16px; padding-right: 34px; }
.dlg__headline { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 9px; }
.dlg__title {
  flex: 1;
  min-width: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 23px;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0;
}
.dlg__headline .marks { margin-left: 0; margin-top: 5px; }
.dlg__headline .marks__label { display: none; }
.dlg__why { margin: 0; font-size: 14px; line-height: 1.55; color: var(--ink-soft); }
.dlg__head .pl__tags { margin: 12px 0 0; }

/* the reason the dialog exists: room for a long prompt */
.dlg .pl__prompt-text { font-size: 13.5px; line-height: 1.7; }
.dlg .pl__prompt .copy, .dlg .codeblock .copy { opacity: 1; }

.dlg__foot {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.dlg__foot .pl__src { font-size: 12px; }
.dlg__foot .pl__src-pub { display: inline; }
.dlg__foot .pl__slots { margin-left: auto; }

@media (max-width: 640px) {
  .dlg { padding: 0; place-items: end stretch; }
  .dlg__panel { width: 100%; max-height: 92vh; border-radius: 0; }
  .dlg__body { padding: 22px 20px 20px; }
}

/* cards are always collapsed now; the chevron cue moves to the whole card */
.pl__toggle { padding-bottom: 14px; }
.pl__toggle:hover .pl__title { color: var(--accent-ink); }

.empty { padding: 64px 0; text-align: center; }
.empty__msg { margin: 0 0 14px; font-size: 14px; color: var(--ink-mute); }
.empty__reset {
  font-family: inherit;
  font-size: 13px;
  color: var(--accent-ink);
  background: none;
  border: 1px solid var(--accent-soft);
  border-radius: 0;
  padding: 7px 14px;
  cursor: pointer;
}
.empty__reset:hover { background: var(--accent-soft); }

/* ---------- load more ---------- */

.more {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 44px;
  padding-top: 34px;
  border-top: 1px solid var(--line);
}
.more[hidden] { display: none; }
.more__btn {
  display: inline-flex;
  align-items: center;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  background: none;
  border: 1px solid var(--line);
  border-radius: 0;
  padding: 11px 22px;
  cursor: pointer;
  transition: border-color 130ms, color 130ms, background 130ms;
}
.more__btn:hover { border-color: var(--accent); color: var(--accent-ink); background: var(--accent-soft); }
.more__btn:focus-visible { outline: none; border-color: var(--accent); }

/* filter trigger: only on small screens, the sidebar is always there above 900 */
.side__bar { display: none; }
.side-scrim { display: none; }
.filterbtn {
  display: none;
  margin-left: auto;
  align-items: center;
  gap: 7px;
  font-family: inherit;
  font-size: 13px;
  color: var(--ink-soft);
  background: none;
  border: 1px solid var(--line);
  border-radius: 0;
  padding: 7px 14px;
  cursor: pointer;
}
.filterbtn svg { width: 15px; height: 15px; }
.filterbtn.is-active { color: var(--accent-ink); border-color: var(--accent); background: var(--accent-soft); }
.filterbtn__n {
  font-family: var(--font-mono);
  font-size: 10.5px;
  background: var(--accent);
  color: #fff;
  border-radius: 0;
  min-width: 16px;
  padding: 1px 5px;
  text-align: center;
}

/* these must come last: the base rules above are what they override */
@media (max-width: 900px) {
  .side__bar { display: flex; }
  .side-scrim { display: block; }
  .side-scrim[hidden] { display: none; }
  .filterbtn { display: inline-flex; }
}

/* ---------- tool names in the lede ---------- */

.inline-tool { white-space: nowrap; }
.inline-tool__mark {
  display: inline-block;
  width: 1em;
  height: 1em;
  vertical-align: -0.14em;
  margin-right: 0.28em;
}
.inline-tool__mark svg { width: 100%; height: 100%; display: block; }


/* ================= brand shell ================= */

/* The wordmark ships as inline SVG so a redeploy cannot drop it. */
.site-header .brand__logo { display: block; height: 20px; width: auto; }
.brand--sm .brand__logo { height: 16px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  padding: 11px 18px;
  border: 1px solid transparent;
  border-radius: 0;
  text-decoration: none;
  cursor: pointer;
  transition: background 120ms var(--ease, ease);
}
.btn--primary { background: var(--accent); color: #FFFFFF; }
.btn--primary:hover { background: var(--accent-ink); }
.site-header .btn { margin-left: auto; }

/* The subscribe pitch, once, after the reader has had real value. */
.band {
  display: flex;
  align-items: center;
  gap: 28px;
  flex-wrap: wrap;
  margin-top: 52px;
  padding: 28px 30px;
  background: var(--accent-soft);
  border: 1px solid var(--wash-line);
}
.band > div { flex: 1; min-width: 260px; }
.band h3 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 21px;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.band p {
  margin: 8px 0 0;
  color: var(--ink-soft);
  font-size: 14.5px;
  max-width: 46ch;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--bg-elev);
  margin-top: 70px;
}
.foot {
  max-width: 1280px;
  margin: 0 auto;
  padding: 34px 28px;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.foot > div { flex: 1; min-width: 240px; }
.foot__tag {
  margin: 12px 0 0;
  font-size: 14px;
  color: var(--ink-mute);
  max-width: 34ch;
}

@media (max-width: 640px) {
  .band { padding: 22px; gap: 18px; }
  .foot { padding: 26px 20px; }
}
