/* Rankstar public site — reading pages: articles, blog, legal, prose blocks, 404/thanks. Loaded only on pages that need it (see partials/head.html). */
@layer components {
  .rs-avatar { display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: 50%; background: var(--sf); color: var(--ac); font-weight: 600; box-shadow: var(--rim); flex: none; }
  .rs-prose { font-size: 1.125rem; line-height: 1.65; max-width: var(--measure); --promise: inherit; }
  .rs-prose > * + * { margin-top: 1.1em; }
  .rs-prose > :first-child { margin-top: 0; }
  .rs-prose a { color: var(--ac); text-underline-offset: 3px; }
  .rs-prose a:hover { text-underline-offset: 2px; color: var(--ah); }
  .rs-prose strong { font-weight: 600; color: var(--tx); }
  .rs-prose :is(ul, ol) { padding-left: 1.4em; }
  .rs-prose li + li { margin-top: .45em; }
  .rs-prose li::marker { color: var(--ac); font-variant-numeric: tabular-nums; }
  .rs-prose dl { display: grid; grid-template-columns: max-content 1fr; gap: .5rem 1.5rem; }
  .rs-prose dt { font-weight: 600; } .rs-prose dd { margin: 0; }
  .rs-prose h2 { font-size: 1.75rem; font-weight: 600; letter-spacing: -.015em; line-height: 1.25; margin-top: 2.2em; scroll-margin-top: 6.5rem; }
  .rs-prose h3 { font-size: 1.3125rem; font-weight: 600; letter-spacing: -.015em; margin-top: 1.8em; scroll-margin-top: 6.5rem; }
  .rs-prose h4 { font-size: 1.125rem; font-weight: 600; margin-top: 1.6em; }
  .rs-prose :is(h2, h3, h4) + * { margin-top: .6em; }
  .rs-prose code { font: .88em/1.4 ui-monospace, "SF Mono", Menlo, Consolas, monospace; background: var(--s2); padding: .12em .38em; border-radius: 6px; }
  .rs-prose pre { background: var(--s2); border-radius: 14px; padding: 1rem 1.25rem; overflow-x: auto; box-shadow: inset 3px 0 0 var(--ac); }
  .rs-prose pre code { background: none; padding: 0; font-size: .875rem; }
  .rs-prose blockquote { background: var(--s2); padding: 1.25rem 1.5rem; border-radius: 14px; box-shadow: inset 3px 0 0 var(--ac); font-size: 1.1875rem; }
  .rs-prose table { display: block; overflow-x: auto; border-collapse: collapse; font-size: .9375rem; line-height: 1.5; font-variant-numeric: tabular-nums; }
  .rs-prose :is(th, td) { padding: .75rem 1rem; text-align: left; border-bottom: 1px solid var(--bd); }
  .rs-prose th { background: var(--s2); font-weight: 600; }
  .rs-prose img { border-radius: 14px; }
  .rs-prose hr { border: 0; border-top: 1px dashed var(--bs); margin-block: 2.5em; }
  .rs-prose mark { background: var(--aw); color: inherit; padding: 0 .15em; border-radius: 3px; }
  .rs-figure { margin-block: 1.5rem; }
  .rs-figure img { border-radius: 14px; width: 100%; }
  .rs-figure figcaption { font-size: .875rem; color: var(--t3); margin-top: .75rem; }
  .rs-note { display: grid; grid-template-columns: 1.5rem 1fr; gap: 1rem; padding: 1.25rem 1.5rem; border-radius: 14px; background: var(--aw); font-size: 1rem; line-height: 1.55; }
  .rs-note__icon { color: var(--ac); width: 1.5rem; height: 1.5rem; }
  .rs-note--tip { background: var(--gw); } .rs-note--tip .rs-note__icon { color: var(--gn); }
  .rs-note--warning { background: color-mix(in oklab, var(--color-warning) 12%, var(--sf)); } .rs-note--warning .rs-note__icon { color: var(--color-warning); }
  .rs-note__body > * + * { margin-top: .5rem; } .rs-note__body ul { padding-left: 1.2em; }
  .rs-note__body li + li { margin-top: .25rem; }
  .rs-reel { display: block; margin-block: 1.5rem; }
  .rs-reel__play { position: relative; display: grid; align-content: end; gap: .25rem; width: 100%; aspect-ratio: 16 / 9; padding: 1.5rem; border-radius: 20px; overflow: hidden; isolation: isolate; color: #fff; text-align: left; }
  .rs-reel__poster { position: absolute; inset: 0; z-index: -1; }
  .rs-reel__poster .rs-strata { height: 42%; }
  .rs-reel__btn { position: absolute; left: 50%; top: 42%; translate: -50% -50%; display: grid; place-items: center; width: 4.5rem; height: 4.5rem; border-radius: 50%; background: #fff; color: var(--violet-600); box-shadow: 0 16px 40px -10px rgb(5 3 20 / .6); transition: transform var(--dur-fast) var(--ease-out); }
  .rs-reel__btn .rs-i { width: 1.75rem; height: 1.75rem; translate: 2px 0; }
  .rs-reel__play:hover .rs-reel__btn { transform: scale(1.06); }
  .rs-reel__title { font-size: 1.25rem; font-weight: 600; }
  .rs-reel__note { font-size: .8125rem; color: var(--lilac-300); }
  .rs-reel iframe { width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; border-radius: 20px; background: #000; }
  .rs-toc__title { font-size: .875rem; font-weight: 600; margin-bottom: .75rem; }
  .rs-toc ol { list-style: none; padding: 0; display: grid; }
  .rs-toc a { display: block; padding: .375rem 0 .375rem 1rem; font-size: .875rem; color: var(--t2); text-decoration: none; background: linear-gradient(var(--bs) 50%, transparent 0) left top / 1px 6px repeat-y; transition: color var(--dur-fast); }
  .rs-toc a:hover { color: var(--tx); }
  .rs-toc a[aria-current="true"] { color: var(--ac); background: linear-gradient(var(--ac), var(--ac)) left top / 2px 100% no-repeat; }
  .rs-toc__l3 a { padding-left: 2rem; font-size: .8125rem; }
  .rs-toc--side { display: block; padding: 1.25rem 1.5rem; border-radius: 20px; background: var(--sf); box-shadow: var(--rim); }
  .rs-toc--inline { padding: 1.25rem 1.5rem; border-radius: 20px; background: var(--sf); box-shadow: var(--rim); }
  .rs-toc--mobile { margin-bottom: 2.5rem; border-radius: 14px; background: var(--sf); box-shadow: var(--rim); }
  .rs-toc--mobile summary { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.25rem; font-weight: 600; list-style: none; cursor: pointer; }
  .rs-toc--mobile summary::-webkit-details-marker { display: none; }
  .rs-toc--mobile[open] summary .rs-i { transform: rotate(180deg); }
  .rs-toc--mobile ol { padding: 0 1.25rem 1rem; }
  .rs-journal-head { padding-top: .75rem; }
  .rs-journal-head__panel { position: relative; overflow: hidden; padding: clamp(2rem, 1rem + 5vw, 4.5rem); border-radius: 28px; background: var(--color-bg-sunken); }
  .rs-journal-head__draw { position: absolute; right: 2rem; top: 50%; translate: 0 -50%; width: min(16rem, 34%); height: auto; aspect-ratio: 1; color: var(--ac); opacity: .3; stroke-width: .4; }
  .rs-journal-head__title { font-size: var(--fs-h1); margin-block: 1rem; }
  .rs-journal-head__page { color: var(--t3); font-weight: 400; font-size: .5em; }
  .rs-page-notice .rs-prose + .rs-prose { margin-top: 2.5rem; }
  .rs-chips { margin-bottom: 3rem; }
  .rs-chips ul { display: flex; flex-wrap: wrap; gap: .5rem; }
  .rs-chip { display: inline-flex; align-items: center; gap: .5rem; min-height: 2.5rem; padding: 0 1rem; border-radius: 999px; background: var(--sf); box-shadow: inset 0 0 0 1px var(--bd); font-size: .875rem; font-weight: 500; text-decoration: none; transition: box-shadow var(--dur-fast); }
  .rs-chip:hover { box-shadow: inset 0 0 0 1px var(--al); }
  .rs-chip span { color: var(--t3); font-variant-numeric: tabular-nums; }
  .rs-chip[aria-current] { background: var(--color-action-strong); color: var(--color-on-action-strong); box-shadow: none; }
  .rs-chip[aria-current] span { color: inherit; opacity: .7; }
  .rs-journal__sub { font-size: var(--fs-h3); margin: 4rem 0 1.5rem; }
  .rs-pager { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 1rem; margin-top: 5rem; max-width: 100%; }
  .rs-pager ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: .25rem; min-width: 0; }
  .rs-pager :is(a, span[aria-current]) { display: grid; place-items: center; min-width: 2.75rem; height: 2.75rem; border-radius: 10px; text-decoration: none; font-variant-numeric: tabular-nums; font-weight: 500; }
  .rs-pager ol a:hover { background: var(--s2); }
  .rs-pager span[aria-current] { background: var(--color-action-strong); color: var(--color-on-action-strong); }
  .rs-pager__gap { display: grid; place-items: center; min-width: 1.25rem; height: 2.75rem; color: var(--t3); }
  .rs-pager__step { display: inline-flex !important; gap: .5rem; padding-inline: .75rem; }
  /* Phones: the numbers get their own row; prev/next sit under it at either end. */
  @media (max-width: 719px) {
    .rs-pager { justify-content: space-between; gap: .75rem .5rem; margin-top: 3.5rem; }
    .rs-pager ol { order: -1; flex-basis: 100%; gap: .125rem; }
    .rs-pager ol :is(a, span[aria-current]) { min-width: 2.25rem; }
    .rs-pager__step--next { margin-left: auto; }
  }
  .rs-empty { display: grid; justify-items: center; gap: .75rem; text-align: center; padding: 5rem 1rem; color: var(--t2); }
  .rs-empty__draw { width: 4rem; height: 4rem; color: var(--ac); stroke-width: 1.25; }
  .rs-empty__title { font-size: var(--fs-h3); color: var(--tx); }
  .rs-article__head { padding-block: clamp(1.5rem, 1rem + 3vw, 3.5rem) 2.5rem; }
  .rs-article__head .rs-wrap { max-width: 60rem; margin-left: max(var(--gutter), (100% - var(--container)) / 2); }
  .rs-article__cat { margin-top: 1.5rem; }
  .rs-article__title { font-size: clamp(2.375rem, 1.9rem + 2vw, 3.5rem); max-width: 20ch; margin-top: 1rem; }
  .rs-article__dek { font-size: var(--fs-lead); color: var(--t2); max-width: 58ch; margin-top: 1.25rem; }
  .rs-article__byline { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; margin-top: 2.5rem; padding-bottom: 1.5rem; background: linear-gradient(90deg, var(--bs) 50%, transparent 0) left bottom / 8px 1px repeat-x; }
  .rs-avatar { background: var(--aw); box-shadow: none; font-size: .875rem; width: 2.75rem; height: 2.75rem; }
  .rs-avatar--lg { width: 3.5rem; height: 3.5rem; font-size: 1rem; }
  .rs-article__who { display: grid; margin-right: auto; }
  .rs-share { list-style: none; padding: 0; display: flex; gap: .25rem; }
  .rs-share .rs-tool { color: var(--t2); }
  .rs-article__grid { display: grid; gap: 3rem; align-items: start; }
  .rs-article__body { min-width: 0; }
  .rs-article__body > * + * { margin-top: 1.5rem; }
  .rs-article__aside { display: grid; gap: 1.25rem; }
  .rs-article__aside .rs-toc--side { display: none; }
  .rs-sidecard { display: grid; gap: .75rem; justify-items: start; padding: .5rem .5rem 1.5rem; border-radius: 20px; background: var(--sf); box-shadow: var(--rim); }
  .rs-sidecard .rs-vista { width: 100%; aspect-ratio: 2; margin-bottom: .5rem; }
  .rs-sidecard > :not(.rs-vista) { margin-inline: 1rem; }
  .rs-sidecard__title { font-size: 1.25rem; font-weight: 600; }
  .rs-sidecard__text { font-size: .875rem; color: var(--t2); }
  @media (min-width: 1024px) {
    .rs-article__grid { grid-template-columns: minmax(0, 1fr) 18.5rem; gap: 6rem; }
    .rs-article__aside { position: sticky; top: calc(var(--rs-mast) + 1rem); }
    .rs-article__aside .rs-toc--side { display: block; }
    .rs-toc--mobile { display: none; }
  }
  .rs-legal__stamp { margin-top: 1.25rem; }
  .rs-article__foot { margin-block: 4rem 1.5rem; }
  .rs-authorbox { display: flex; gap: 1.25rem; align-items: center; max-width: var(--container-prose); padding: 1.5rem; border-radius: 20px; background: var(--sf); box-shadow: var(--rim); }
  .rs-authorbox__name { font-weight: 600; }
  .rs-authorbox__text { color: var(--t2); font-size: .9375rem; margin-top: .25rem; }
  .rs-legal { display: grid; gap: 2.5rem; align-items: start; padding-bottom: var(--section-y); }
  .rs-legal__body > * + * { margin-top: 1.5rem; }
  @media (min-width: 1024px) { .rs-legal { grid-template-columns: 16rem minmax(0, 1fr); gap: 6rem; } .rs-legal__toc { position: sticky; top: calc(var(--rs-mast) + 1rem); } }
  .rs-lost { padding-block: 2.5rem var(--section-y); }
  .rs-lost__grid { display: grid; gap: 3rem; align-items: center; margin-bottom: 5rem; }
  .rs-lost__code { font-size: .875rem; font-weight: 600; color: var(--ac); font-variant-numeric: tabular-nums; }
  .rs-lost__actions { display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: center; margin-top: 2.5rem; }
  .rs-lost__scene { position: relative; overflow: hidden; aspect-ratio: 4 / 3; border-radius: 28px; isolation: isolate; }
  .rs-lost__scene .rs-strata { height: 44%; } .rs-lost__scene .rs-vista__halo { top: 84%; }
  .rs-lost__mark { position: absolute; left: 50%; top: 70%; width: 24%; translate: -50% -50%; }
  .rs-lost__scene .rs-strata { z-index: 1; }
  .rs-lost__sub { font-size: 1.25rem; font-weight: 600; margin-bottom: 1.25rem; }
  .rs-lost__links { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: .75rem 1.5rem; }
  @media (min-width: 900px) { .rs-lost__grid { grid-template-columns: 1.1fr .9fr; } }
  .rs-thanks { padding-top: .75rem; }
  .rs-thanks__panel { --promise: var(--lilac-400); position: relative; isolation: isolate; overflow: clip; display: grid; justify-items: center; text-align: center; gap: 1.25rem; color: #fff; padding: clamp(3rem, 2rem + 5vw, 6rem) var(--gutter) clamp(9rem, 7rem + 6vw, 12rem); border-radius: 28px; }
  .rs-thanks__panel > .rs-strata { height: 8rem; z-index: -1; }
  .rs-thanks__halo { position: absolute; z-index: -1; left: 50%; top: 4rem; width: 36rem; aspect-ratio: 1; translate: -50% -40%; background: var(--halo); }
  .rs-thanks__seal { display: grid; place-items: center; width: 4rem; height: 4rem; border-radius: 50%; background: var(--mint-300); color: var(--n-900); box-shadow: 0 0 0 10px rgb(158 240 196 / .16); }
  .rs-thanks__seal .rs-i { width: 2rem; height: 2rem; stroke-width: 2; }
  .rs-thanks__title { font-size: var(--fs-h1); max-width: 18ch; }
  .rs-thanks__lead { color: var(--lilac-200); font-size: var(--fs-lead); max-width: 46ch; }
  .rs-thanks__actions { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 1rem 2rem; margin-top: 1rem; }
}

/* author photo in the byline and author box, and the author page */
@layer components {
  .rs-avatar--photo { padding: 0; overflow: hidden; background: var(--s2); box-shadow: 0 0 0 2px var(--color-bg), 0 0 0 3px var(--bd); }
  .rs-avatar--photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
  .rs-article__author { color: inherit; text-decoration: none; } .rs-article__author:hover b { color: var(--ac); }
  .rs-authorbox__name a { color: inherit; text-decoration: none; } .rs-authorbox__name a:hover { color: var(--ac); }
  .rs-authorbox__role { display: block; font-weight: 500; font-size: .875rem; color: var(--t3); }
  .rs-authorbox__links { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; margin-top: .625rem; font-size: .875rem; font-weight: 600; }
  .rs-authorbox__links a { display: inline-flex; align-items: center; gap: .375rem; color: var(--ac); text-decoration: none; }
  .rs-authorbox__links .rs-i { width: 1rem; height: 1rem; }
  .rs-author { padding-top: calc(var(--rs-mast) + 1.5rem); }
  .rs-author__card { display: grid; gap: 1.5rem; align-items: center; margin-top: 1.5rem; padding: clamp(1.5rem, 1rem + 2vw, 2.5rem); border-radius: 24px;
    background: var(--glass-fill, var(--sf)); box-shadow: inset 0 1px 0 var(--glass-hl, #fff), inset 0 0 0 1px var(--glass-rim, var(--bd)), var(--glass-shadow, none); }
  @media (min-width: 720px) { .rs-author__card { grid-template-columns: auto 1fr; gap: 2.25rem; } }
  .rs-author__photo { width: 9rem; height: 9rem; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 4px var(--color-bg), 0 0 0 5px var(--bd), 0 18px 36px -18px rgb(42 13 92 / .5); }
  .rs-author__name { font-size: var(--fs-h2); letter-spacing: -.02em; line-height: 1.1; }
  .rs-author__role { margin-top: .25rem; color: var(--ac); font-weight: 600; }
  .rs-author__bio { margin-top: .875rem; max-width: 60ch; color: var(--t2); line-height: 1.55; }
  .rs-author__links { display: flex; align-items: center; flex-wrap: wrap; gap: 1rem; margin-top: 1.25rem; }
  .rs-author__count { color: var(--t3); font-size: .875rem; }
  .rs-author__allhead { margin-top: 2.5rem; }
  .rs-author__all { list-style: none; padding: 0; columns: 2 22rem; column-gap: 2.5rem; }
  .rs-author__all li { break-inside: avoid; display: flex; justify-content: space-between; gap: 1rem; padding: .5rem 0; border-bottom: 1px solid var(--bd); font-size: .9375rem; }
  .rs-author__all a { color: var(--tx); text-decoration: none; } .rs-author__all a:hover { color: var(--ac); }
  .rs-author__all time { flex: none; color: var(--t3); font-size: .8125rem; }
}

/* phones: calmer article headings (owner, Nov 5) */
@layer components {
  @media (max-width: 639.98px) {
    .rs-article__title { font-size: 1.75rem; line-height: 1.15; }
    .rs-article__dek { font-size: 1rem; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
    .rs-prose h2 { font-size: 1.375rem; margin-top: 2rem; } .rs-prose h3 { font-size: 1.125rem; }
    .rs-prose h2:first-child, .rs-article__body > .rs-prose:first-child h2:first-of-type { margin-top: .5rem; }
  }
}

/* phones: the blog header is a large panel and the author box a card, on the one left line (see site-sections.css) */
@layer components {
  @media (max-width: 639.98px) {
    .rs-journal-head__panel { margin-inline: calc(var(--nav-inset) - var(--gutter)); padding: 1.75rem var(--rs-band-pad); border-radius: 24px; }
    .rs-author__card { padding: 1.125rem; }
  }

  /* ---------------------------------------------------------------- article sidebar + phone CTA (owner, Nov 7):
     prices / contact card above a compact contents list (H2 only); on phones a bar rides the bottom of the article */
  .rs-sidecta { display: grid; gap: .5rem; justify-items: start; padding: 1.25rem; border-radius: 20px; color: #fff;
    background: radial-gradient(120% 90% at 100% 0%, rgb(176 75 234 / .55), transparent 60%), linear-gradient(160deg, #2A0B55, #4A1590 60%, #6A22C2); box-shadow: 0 18px 40px -24px rgb(42 11 85 / .7); }
  .rs-sidecta__k { font-size: .6875rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #D9C3FF; }
  .rs-sidecta__title { font-size: 1.125rem; font-weight: 650; line-height: 1.25; letter-spacing: -.01em; }
  .rs-sidecta__text { font-size: .8125rem; color: #E9DAFF; margin-bottom: .25rem; }
  .rs-sidecta .rs-beacon { width: 100%; }
  .rs-sidecta__alt { display: inline-flex; align-items: center; gap: .3rem; font-size: .8125rem; font-weight: 600; color: #fff; text-decoration: none; opacity: .9; }
  .rs-sidecta__alt .rs-i { width: .85rem; height: .85rem; }
  .rs-sidecta__alt:hover { opacity: 1; text-decoration: underline; text-underline-offset: 3px; }
  .rs-article__aside .rs-toc--side { padding: 1rem 1.125rem; max-height: calc(100svh - var(--rs-mast) - 21rem); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
  .rs-article__aside .rs-toc__title { margin-bottom: .375rem; font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; color: var(--t3); }
  .rs-article__aside .rs-toc a { padding: .25rem 0 .25rem .75rem; font-size: .8125rem; line-height: 1.35; }
  .rs-mobcta { position: sticky; bottom: .75rem; z-index: 5; display: flex; gap: .5rem; margin-top: 2rem; padding: .375rem; border-radius: 16px; background: color-mix(in oklab, var(--sf) 88%, transparent); backdrop-filter: blur(10px); box-shadow: var(--rim), 0 14px 30px -16px rgb(30 10 60 / .45); }
  .rs-mobcta a { display: inline-flex; align-items: center; justify-content: center; gap: .35rem; min-height: 2.75rem; padding: 0 1rem; border-radius: 12px; font-size: .9375rem; font-weight: 650; text-decoration: none; }
  .rs-mobcta__main { flex: 1; background: var(--ac); color: #fff; }
  .rs-mobcta__main .rs-i { width: 1rem; height: 1rem; }
  .rs-mobcta__alt { color: var(--tx); box-shadow: inset 0 0 0 1px var(--bs); }
  @media (min-width: 1024px) { .rs-mobcta { display: none; } }

  /* ---------------------------------------------------------------- agency ranking (blocks/agencies.html) */
  .rs-agencies { margin-block: 2.5rem; }
  .rs-agencies__title { font-size: var(--fs-h3, 1.5rem); font-weight: 650; letter-spacing: -.015em; line-height: 1.2; scroll-margin-top: calc(var(--rs-mast) + 1rem); }
  .rs-agencies__lead { margin-top: .5rem; color: var(--t2); font-size: .9375rem; }
  .rs-agencies__scroll { margin-top: 1rem; border-radius: 16px; background: var(--sf); box-shadow: var(--rim); overflow: hidden; }
  .rs-agencies__table { width: 100%; border-collapse: collapse; font-size: .875rem; line-height: 1.4; }
  .rs-agencies__table thead th { position: sticky; top: 0; padding: .625rem .75rem; background: var(--s2); color: var(--t3); font-size: .6875rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; text-align: left; }
  .rs-agencies__table td, .rs-agencies__table tbody th { padding: .75rem; border-top: 1px solid var(--bd); vertical-align: middle; text-align: left; font-weight: 400; }
  .rs-agencies__n span { display: grid; place-items: center; width: 1.75rem; height: 1.75rem; border-radius: 50%; background: var(--s2); color: var(--t2); font-size: .8125rem; font-weight: 700; font-variant-numeric: tabular-nums; }
  .rs-agencies__name { min-width: 10rem; }
  .rs-agencies__name, .rs-agencies__who { display: flex; align-items: center; gap: .6rem; }
  .rs-agencies__who { flex-direction: column; align-items: flex-start; gap: .1rem; }
  .rs-agencies__who b { font-weight: 650; color: var(--tx); }
  .rs-agencies__ours { display: block; margin-top: .1rem; font-size: .6875rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ac); }
  .rs-agencies__who .rs-agencies__site, .rs-agencies__who em { font-size: .75rem; font-style: normal; color: var(--t3); }
  .rs-agencies__best { color: var(--t2); }
  .rs-agencies__facts { color: var(--t2); font-size: .8125rem; }
  .rs-agencies__city { color: var(--t3); white-space: nowrap; font-size: .8125rem; }
  .rs-agencies__mark { flex: none; display: grid; place-items: center; width: 1.9rem; height: 1.9rem; border-radius: 30%; background: linear-gradient(135deg, #8B5CF6, #5B21B6); box-shadow: 0 4px 10px -4px rgb(91 33 182 / .6); }
  .rs-agencies__mark svg { width: 60%; height: 60%; fill: #fff; }
  .rs-agencies__table tr.is-ours { background: linear-gradient(90deg, color-mix(in oklab, var(--ac) 10%, var(--sf)), var(--sf)); }
  .rs-agencies__table tr.is-ours .rs-agencies__n span { background: var(--ac); color: #fff; }
  .rs-agencies__table tr.is-ours .rs-agencies__who em { color: var(--ac); font-weight: 600; }
  .rs-agencies__table tr.is-ours .rs-agencies__best { color: var(--tx); }
  .rs-agencies__cta { display: inline-flex; align-items: center; gap: .25rem; margin-left: .35rem; padding: .2rem .6rem; border-radius: 99px; background: var(--ac); color: #fff; font-size: .75rem; font-weight: 650; text-decoration: none; white-space: nowrap; }
  .rs-agencies__cta .rs-i { width: .75rem; height: .75rem; }
  .rs-agencies__cta:hover { background: var(--ah); }
  .rs-agencies__note { margin-top: .625rem; font-size: .75rem; color: var(--t3); }
  .rs-agencies__table tr[hidden] { display: none; }
  .rs-agencies__clutch, .rs-agencies__budget { white-space: nowrap; }
  .rs-agencies__clutch > *, .rs-agencies__budget > * { display: block; }
  .rs-agencies__stars { font-weight: 650; color: var(--tx); font-variant-numeric: tabular-nums; }
  .rs-agencies__stars b { color: #F5A524; font-weight: 400; }
  .rs-agencies__clutch small, .rs-agencies__budget small { font-size: .75rem; color: var(--t3); white-space: normal; }
  .rs-agencies__budget span { font-size: .8125rem; color: var(--tx); font-variant-numeric: tabular-nums; }
  .rs-agencies__table small.is-muted { color: var(--t3); opacity: .8; }
  /* toolbar (full table, 8+ rows): search, sort, city, reviewed only, live count */
  .rs-agencies__tools { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: 1rem; }
  .rs-agencies__search { flex: 1 1 13rem; display: flex; align-items: center; gap: .5rem; min-height: 2.5rem; padding: 0 .75rem; border-radius: 12px; background: var(--sf); box-shadow: var(--rim); }
  .rs-agencies__search .rs-i { width: 1rem; height: 1rem; color: var(--t3); flex: none; }
  .rs-agencies__search input { flex: 1; min-width: 0; border: 0; background: none; font: inherit; font-size: .875rem; color: var(--tx); outline: none; }
  .rs-agencies__search:focus-within { box-shadow: var(--rim), 0 0 0 2px var(--ac); }
  .rs-agencies__sel { display: inline-flex; align-items: center; gap: .4rem; min-height: 2.5rem; padding: 0 .4rem 0 .75rem; border-radius: 12px; background: var(--sf); box-shadow: var(--rim); font-size: .75rem; font-weight: 600; color: var(--t3); }
  .rs-agencies__sel select { border: 0; background: none; font: inherit; font-size: .875rem; font-weight: 600; color: var(--tx); padding: .25rem; cursor: pointer; max-width: 11rem; }
  .rs-agencies__sel:focus-within { box-shadow: var(--rim), 0 0 0 2px var(--ac); }
  .rs-agencies__chk { display: inline-flex; align-items: center; gap: .45rem; min-height: 2.5rem; padding: 0 .75rem; border-radius: 12px; background: var(--sf); box-shadow: var(--rim); font-size: .8125rem; font-weight: 600; color: var(--tx); cursor: pointer; }
  .rs-agencies__chk input { accent-color: var(--ac); width: 1rem; height: 1rem; }
  .rs-agencies__count { margin-left: auto; font-size: .8125rem; color: var(--t3); }
  .rs-agencies__count b { color: var(--tx); font-variant-numeric: tabular-nums; }
  .rs-agencies__empty { padding: 1rem; font-size: .875rem; color: var(--t2); border-top: 1px solid var(--bd); }
  .rs-agencies__empty button { border: 0; background: none; color: var(--ac); font: inherit; font-weight: 650; cursor: pointer; text-decoration: underline; }
  .rs-agencies--glance .rs-agencies__scroll { box-shadow: var(--rim), 0 20px 44px -30px rgb(40 12 100 / .45); }
  /* phones: each row is a small card (rank + name on top, then the details) */
  @media (max-width: 639.98px) {
    .rs-agencies__scroll { background: none; box-shadow: none; overflow: visible; }
    .rs-agencies__table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .rs-agencies__table, .rs-agencies__table tbody { display: block; }
    .rs-agencies__table tr { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: .25rem .75rem; margin-bottom: .625rem; padding: .875rem; border-radius: 14px; background: var(--sf); box-shadow: var(--rim); }
    .rs-agencies__table td, .rs-agencies__table tbody th { padding: 0; border: 0; }
    .rs-agencies__n { grid-row: span 5; }
    .rs-agencies__best, .rs-agencies__facts, .rs-agencies__city, .rs-agencies__clutch, .rs-agencies__budget { grid-column: 2; }
    .rs-agencies__clutch, .rs-agencies__budget { display: flex; flex-wrap: wrap; align-items: baseline; gap: .15rem .5rem; white-space: normal; }
    .rs-agencies__clutch > *, .rs-agencies__budget > * { display: inline; }
    .rs-agencies__clutch::before, .rs-agencies__budget::before { content: attr(data-k); flex-basis: 100%; font-size: .625rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--t3); }
    .rs-agencies__tools > * { flex: 1 1 100%; }
    .rs-agencies__count { margin-left: 0; }
    .rs-agencies__city { white-space: normal; }
  }
  /* FAQ inside an article (blocks/faq.html, article flow) */
  .rs-faqlite { margin-block: 2.5rem; }
  .rs-faqlite__title { margin-bottom: .75rem; font-size: var(--fs-h3, 1.5rem); font-weight: 650; letter-spacing: -.015em; scroll-margin-top: calc(var(--rs-mast) + 1rem); }
  .rs-faqlite .rs-faq__item summary { font-size: 1rem; }
}

/* case studies: the services behind the numbers (post.html), a quiet card before the story */
@layer components {
  .rs-casemix { display: grid; gap: .7rem; padding: 1.15rem 1.25rem 1.2rem; border-radius: 20px; color: #fff;
    background: linear-gradient(160deg, #1A1058 0%, #3A1C9E 100%); box-shadow: inset 0 1px 0 rgb(255 255 255 / .12); }
  .rs-casemix > * { margin: 0; }
  .rs-casemix__k { font-size: .6875rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #D9C3FF; }
  .rs-casemix__sum { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .35rem; padding: 0; list-style: none; }
  .rs-casemix__sum li { display: inline-flex; align-items: center; gap: .35rem; margin: 0; font-size: .9375rem; font-weight: 600; line-height: 1.2; }
  .rs-casemix__sum li { padding: .38rem .7rem; border-radius: 99px; background: rgb(255 255 255 / .1); box-shadow: inset 0 0 0 1px rgb(255 255 255 / .16); }
  .rs-casemix__sum li + li { margin-left: 1.15rem; position: relative; }
  .rs-casemix__sum li + li::before { content: "+"; position: absolute; left: -1.05rem; top: 50%; translate: 0 -52%; font-weight: 500; color: #D9C3FF; }
  .rs-casemix__t { font-size: .9375rem; line-height: 1.55; color: rgb(255 255 255 / .86); max-width: 62ch; }
  .rs-casemix__t a { color: #fff; font-weight: 600; text-underline-offset: 3px; white-space: nowrap; }
}
