/* Count history blocks (lib/profile-history.js) and the pages built on them: creator stats
   sections, /top/ extras, /top/fastest-growing/, /milestones/ and /vs/.
   Creator pages each have their own theme, so the stats block only uses inherited text
   colors and neutral see-through lines that work on light and dark backgrounds alike. */

.lc-stats { --lc-line: #3987e5; --lc-rule: rgba(127, 127, 127, 0.28); }
.lc-stats h3 { margin: 18px 0 8px; font-size: 1.05rem; }
.lc-meta { display: flex; flex-wrap: wrap; gap: 2px 16px; margin: 0 0 14px; font-size: 0.875rem; }
.lc-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 0 0 16px; }
.lc-kpi { border: 1px solid var(--lc-rule); border-radius: 10px; padding: 10px 12px; margin: 0; }
.lc-kpi dt { font-size: 0.8125rem; }
.lc-kpi dd { margin: 0; }
.lc-kpi-v { font-size: clamp(1.125rem, 5vw, 1.375rem); font-weight: 700; line-height: 1.3; direction: ltr; unicode-bidi: isolate; }
[dir="rtl"] .lc-kpi-v { text-align: right; }
.lc-kpi-s { font-size: 0.8125rem; }

/* Chart: SVG stretches, labels and the end dot are HTML so they keep their shape */
.lc-chart { margin: 0 0 16px; --lc-line: #3987e5; }
.lc-chart-box { display: flex; gap: 8px; }
.lc-chart-y { position: relative; flex: none; width: 4.2em; height: 180px; font-size: 0.75rem; font-variant-numeric: tabular-nums; }
.lc-chart-y span { position: absolute; right: 0; transform: translateY(-50%); white-space: nowrap; line-height: 1; }
.lc-chart-plot { position: relative; flex: 1; min-width: 0; height: 180px; touch-action: pan-y; }
.lc-chart-plot:focus-visible { outline: 2px solid var(--lc-line); outline-offset: 4px; }
.lc-chart-plot svg { display: block; width: 100%; height: 100%; overflow: visible; }
.lc-grid line { stroke: currentColor; stroke-opacity: 0.16; stroke-width: 1; vector-effect: non-scaling-stroke; shape-rendering: crispEdges; }
.lc-line { fill: none; stroke: var(--lc-line); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.lc-area { fill: var(--lc-line); fill-opacity: 0.1; stroke: none; }
.lc-dot { position: absolute; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: var(--lc-line); pointer-events: none; }
.lc-cross { position: absolute; top: 0; bottom: 0; width: 0; border-left: 1px solid currentColor; opacity: 0.35; pointer-events: none; }
.lc-tip { position: absolute; top: 0; z-index: 2; padding: 6px 9px; border-radius: 8px; background: #16171a; color: #fff; font-size: 0.8125rem; line-height: 1.35; white-space: nowrap; pointer-events: none; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25); }
.lc-tip strong { display: block; font-size: 0.9375rem; font-variant-numeric: tabular-nums; }
.lc-chart-x { display: flex; justify-content: space-between; margin: 6px 0 0 calc(4.2em + 8px); font-size: 0.75rem; }
.lc-chart figcaption { margin-top: 6px; font-size: 0.8125rem; }

.lc-table-wrap { overflow-x: auto; }
.lc-table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
.lc-table th, .lc-table td { padding: 6px 8px; border-bottom: 1px solid var(--lc-rule, rgba(127, 127, 127, 0.28)); text-align: end; white-space: nowrap; font-variant-numeric: tabular-nums; }
.lc-table th:first-child, .lc-table td:first-child { text-align: start; }
.lc-table thead th { font-weight: 600; font-size: 0.8125rem; }
.lc-table tbody th { font-weight: 400; }
.lc-ms { list-style: none; margin: 0; padding: 0; }
.lc-ms li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 12px; padding: 6px 0; border-bottom: 1px solid var(--lc-rule); }
.lc-ms-n { font-weight: 700; font-variant-numeric: tabular-nums; direction: ltr; unicode-bidi: isolate; }
.lc-note { margin: 8px 0 0; font-size: 0.8125rem; }
.lc-more { margin: 12px 0 0; font-size: 0.875rem; }
.lc-more a { margin-inline-end: 12px; }

/* ---- pages on the site stylesheet (/top/, /milestones/, /vs/) ---- */
.page-top .lc-stats, .band .lc-stats { --lc-rule: var(--line); }
.lc-rank small { display: block; color: var(--muted); font-size: 0.8125rem; font-weight: 400; }
.rank-rest tbody tr:nth-child(-n+3) .r-pos { color: var(--muted); font-weight: 400; }
.rank-ad { margin: 16px 0; }
@media (max-width: 560px) { .lc-hide-s { display: none; } }

/* "More live counters" block the server puts under the tables */
.wrap > .creator-spotlight.more-tools, .band .creator-spotlight.more-tools { margin: 8px 0 32px; }
.more-tools h2 { font-size: 1.375rem; margin-bottom: 12px; }
.more-tools h3 { font-size: 1.0625rem; margin: 18px 0 10px; }
.more-tools .creator-links { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0; }
.more-tools .creator-links a { display: inline-flex; align-items: center; min-height: 34px; padding: 4px 12px; border-radius: 8px; background: var(--surface); border: 1px solid var(--line); color: var(--text); font-size: 0.9063rem; text-decoration: none; }
.more-tools .creator-links a:hover { border-color: var(--line-strong); background: var(--surface-2); }

/* ---- /vs/ ---- */
.vs-duel { display: grid; gap: 12px; margin-top: 18px; }
@media (min-width: 720px) { .vs-duel { grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: stretch; } }
.vs-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 18px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.vs-card.is-ahead { border-color: var(--line-strong); }
.vs-dot { width: 12px; height: 12px; border-radius: 50%; }
.vs-a .vs-dot { background: #3987e5; }
.vs-b .vs-dot { background: #e0622d; }
.vs-name { font-size: 1.25rem; font-weight: 700; }
.vs-count { font-size: clamp(1.9rem, 7vw, 2.75rem); font-weight: 800; line-height: 1.15; font-variant-numeric: tabular-nums; direction: ltr; unicode-bidi: isolate; letter-spacing: -0.01em; }
.vs-sub { color: var(--muted); font-size: 0.875rem; }
.vs-card a { margin-top: 8px; font-weight: 600; font-size: 0.9375rem; }
.vs-sep { align-self: center; justify-self: center; font-weight: 800; color: var(--muted); font-size: 1.125rem; }
.vs-gap { margin-top: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 16px 18px; }
.vs-gap-num { font-size: 1.5rem; font-weight: 800; font-variant-numeric: tabular-nums; direction: ltr; unicode-bidi: isolate; }
.vs-gap p { color: var(--muted); margin-top: 6px; }
.vs-gap p.vs-lead { color: var(--text); font-weight: 600; margin-top: 0; }
.vs-live { font-size: 0.8125rem; color: var(--muted); margin-top: 10px; }
.vs-live[data-state="live"]::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #1baf7a; margin-inline-end: 6px; vertical-align: 1px; }
.vs-intro { max-width: 75ch; margin-top: 12px; color: var(--muted); }
.vs-list { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 8px; }
@media (min-width: 720px) { .vs-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.vs-list li { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 12px 14px; }
.vs-list a { color: var(--text); font-weight: 600; text-decoration: none; }
.vs-list a:hover { text-decoration: underline; }
.vs-list .vs-list-gap { display: block; color: var(--muted); font-size: 0.875rem; margin-top: 2px; }
.vs-links { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; list-style: none; padding: 0; }
.vs-chart { margin-top: 16px; }
.vs-chart .lc-chart { --lc-line: #3987e5; }
