/* Pokemon NNN 2026 — character sheet surfaces: Elite Four badge row + horde
   trophies (inside the hero), NNN status strip (points / lifetime earned / rank
   tier / panties / coupons), weekly tasks (past weeks folded, current week in two
   columns, future weeks locked), NNN leaderboard with rank tiers, guest teaser, toast.
   Colours come from nnn-tokens.css (day values on :root, night values under
   html[data-jg-theme="dark"]). The hero is a fixed dark card in both themes, so
   its chips are white-on-translucent like .jgcs-drole. PKMN pixel font only on
   short labels/numbers (no " $ @ + … – — glyphs in that font). */

[hidden].jg-nnn-toast,
.jg-nnn-toast[hidden] { display: none !important; }

/* ================================================================ hero: badge row */
.jg-nnn-badges {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-left: auto;
	padding: 5px 6px;
	position: relative;
	z-index: 2;
	border-radius: 12px;
	background: rgba(8, 6, 18, .38);
	border: 1px solid rgba(255, 255, 255, .14);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08);
}
.jg-nnn-badge {
	position: relative;
	flex: 0 0 36px;
	width: 36px;
	height: 36px;
	display: grid;
	place-items: center;
	border-radius: 9px;
	border: 1px solid rgba(255, 255, 255, .2);
	background: rgba(255, 255, 255, .1);
	background: radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--nnn-badge, var(--nnn-gold)) 48%, transparent) 0%, transparent 72%),
		linear-gradient(180deg, rgba(255, 255, 255, .18), rgba(255, 255, 255, .05));
	box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .28);
	outline: none;
	cursor: default;
	transition: transform .15s ease, box-shadow .15s ease;
}
/* glossy sheen over the top half */
.jg-nnn-badge::after {
	content: "";
	position: absolute;
	left: 2px;
	right: 2px;
	top: 2px;
	height: 46%;
	border-radius: 7px 7px 12px 12px / 7px 7px 5px 5px;
	background: linear-gradient(180deg, rgba(255, 255, 255, .38), rgba(255, 255, 255, 0));
	pointer-events: none;
	z-index: 2;
}
.jg-nnn-badge img {
	position: relative;
	z-index: 1;
	display: block;
	width: 32px;
	height: 32px;
	max-width: none;
	filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .45));
}
.jg-nnn-badge.is-locked { background: rgba(255, 255, 255, .06); border-style: dashed; }
.jg-nnn-badge.is-locked img { filter: grayscale(1); opacity: .3; }
.jg-nnn-badge.is-earned:hover,
.jg-nnn-badge.is-earned:focus-visible,
.jg-nnn-badge.is-earned.is-tip { transform: translateY(-2px); }
.jg-nnn-badge:focus-visible { box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .28), 0 0 0 2px var(--nnn-yellow); }

/* tooltip: opens DOWNWARD (the hero clips with overflow:hidden) and is
   right-aligned to the badge row (--nnn-r = tiles to the right of this one) */
.jg-nnn-badge-tip {
	position: absolute;
	top: calc(100% + 10px);
	right: calc(var(--nnn-r, 0) * -42px - 6px);
	z-index: 6;
	display: flex;
	flex-direction: column;
	gap: 2px;
	width: max-content;
	max-width: 240px;
	padding: 8px 11px 9px;
	border-radius: var(--nnn-radius);
	background: var(--nnn-card);
	color: var(--nnn-text);
	border: 2px solid var(--nnn-frame);
	box-shadow: inset 0 0 0 2px var(--nnn-frame2), 0 10px 24px rgba(0, 0, 0, .35);
	font-size: 12px;
	font-weight: 600;
	line-height: 1.4;
	text-align: left;
	white-space: normal;
	opacity: 0;
	visibility: hidden;
	transform: translateY(-4px);
	pointer-events: none;
	transition: opacity .12s ease, transform .12s ease, visibility 0s linear .12s;
}
.jg-nnn-badge:hover .jg-nnn-badge-tip,
.jg-nnn-badge:focus-visible .jg-nnn-badge-tip,
.jg-nnn-badge.is-tip .jg-nnn-badge-tip {
	opacity: 1;
	visibility: visible;
	transform: none;
	transition: opacity .12s ease, transform .12s ease, visibility 0s;
}
.jg-nnn-badge-name {
	font-family: var(--nnn-font-pixel);
	font-weight: 400;
	font-size: 12px;
	letter-spacing: .3px;
	color: var(--nnn-text);
}
.jg-nnn-badge-sub { color: var(--nnn-muted); font-weight: 500; }
.jg-nnn-badge.is-locked .jg-nnn-badge-tip span:not(.jg-nnn-badge-name) { color: var(--nnn-muted); }

/* ================================================================ hero: trophy chips */
.jg-nnn-trophies {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	margin-top: 10px;
	position: relative;
	z-index: 2;
}
.jg-nnn-trophies-lab {
	font-family: var(--nnn-font-pixel);
	font-size: 10px;
	letter-spacing: .06em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, .72);
	margin-right: 2px;
}
.jg-nnn-trophy {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	padding: 3px 10px 3px 8px;
	border-radius: 999px;
	font-size: 11.5px;
	font-weight: 700;
	line-height: 1.4;
	color: #fff;
	background: rgba(8, 6, 18, .42);
	border: 1px solid rgba(255, 255, 255, .18);
	box-shadow: inset 3px 0 0 var(--nnn-trophy, var(--nnn-gold));
}
.jg-nnn-trophy b { color: var(--nnn-yellow); font-weight: 800; }

@media (max-width: 860px) {
	/* the hero turns into a centred column: let the row centre instead of hugging the right */
	.jgcs-hero-top .jg-nnn-badges { margin-left: 0; }
	.jg-nnn-trophies { justify-content: center; }
}

/* ================================================================ weekly tasks */
.jg-nnn-tasks { margin: 26px 0 10px; color: var(--nnn-text); }
.jg-nnn-tasks .jg-nnn-tasks-h { flex-wrap: wrap; align-items: center; row-gap: 8px; }
.jg-nnn-tasks .jg-nnn-lb-link {
	margin-left: auto;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 7px 13px;
	border-radius: 6px;
	background: var(--nnn-blue);
	color: #fff !important;
	border: 2px solid var(--nnn-frame);
	box-shadow: 0 3px 0 var(--nnn-blue2);
	font-size: 13px;
	font-weight: 800;
	text-decoration: none !important;
	line-height: 1.1;
}
.jg-nnn-tasks .jg-nnn-lb-link:hover { transform: translateY(1px); box-shadow: 0 2px 0 var(--nnn-blue2); }
.jg-nnn-tasks-note { margin: 0 0 14px; font-size: 13.5px; color: var(--nnn-muted); line-height: 1.5; }
.jg-nnn-tasks-rule { font-weight: 700; color: var(--nnn-text); }

/* SUPER MOVES wording, wherever task text / copy mentions them */
.jg-nnn-sm { font-weight: 800; letter-spacing: .02em; color: var(--nnn-red2); }
html[data-jg-theme="dark"] .jg-nnn-sm { color: var(--nnn-yellow); }

/* ---------------- status strip: points / earned / rank / panties / coupons */
.jg-nnn-strip {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
	gap: 10px;
	margin: 0 0 14px;
}
.jg-nnn-stat {
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
	padding: 9px 12px 10px;
	background: var(--nnn-card);
	color: var(--nnn-text);
	border: 3px solid var(--nnn-frame);
	border-radius: 10px;
	box-shadow: inset 0 0 0 2px var(--nnn-frame2), var(--nnn-shadow);
}
.jg-nnn-stat-k {
	font-family: var(--nnn-font-pixel);
	font-size: 10px;
	line-height: 1.3;
	letter-spacing: .06em;
	text-transform: uppercase;
	color: var(--nnn-muted);
}
.jg-nnn-stat-v {
	display: flex;
	align-items: center;
	gap: 6px;
	min-height: 28px;
	font-family: var(--nnn-font-pixel);
	font-weight: 400;
	font-size: 22px;
	line-height: 1.15;
	color: var(--nnn-text);
}
.jg-nnn-stat small { font-size: 12px; font-weight: 600; line-height: 1.35; color: var(--nnn-muted); }
.jg-nnn-stat small[hidden] { display: none !important; }
/* the ranking-basis line under the Rank card (visible text, not only the tooltip) */
.jg-nnn-stat small.jg-nnn-stat-note { font-size: 11px; font-weight: 500; line-height: 1.35; color: var(--nnn-muted); }
.jg-nnn-stat-ico { font-family: initial; font-size: 19px; line-height: 1; }
/* the points card keeps round 1's yellow chip look (same yellow in both themes) */
.jg-nnn-stat.is-pts { background: var(--nnn-yellow); color: var(--nnn-frame); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .55), var(--nnn-shadow); }
.jg-nnn-stat.is-pts .jg-nnn-stat-k,
.jg-nnn-stat.is-pts small,
.jg-nnn-stat.is-pts .jg-nnn-stat-v { color: var(--nnn-frame); }
.jg-nnn-stat.is-pts .jg-nnn-stat-k,
.jg-nnn-stat.is-pts small { opacity: .78; }
.jg-nnn-stat.is-pts .jg-nnn-sm { color: inherit; }
.jg-nnn-stat.is-rank .jg-nnn-stat-v { font-size: 13px; }

/* ---------------- rank tier pills (PKMN font; colours from the type tokens) */
.jg-nnn-tier {
	display: inline-block;
	padding: 3px 8px 2px;
	border-radius: var(--nnn-radius-pill);
	border: 2px solid var(--nnn-frame);
	background: var(--nnn-blue);
	color: #fff;
	box-shadow: 0 2px 0 var(--nnn-frame);
	font-family: var(--nnn-font-pixel);
	font-size: 10px;
	line-height: 14px;
	letter-spacing: .05em;
	text-transform: uppercase;
	white-space: nowrap;
}
.jg-nnn-tier.is-big { padding: 4px 10px 3px; font-size: 13px; line-height: 18px; }
.jg-nnn-tier.is-champion { background: var(--nnn-gold); color: var(--nnn-frame); }
.jg-nnn-tier.is-arceus { background: var(--type-normal); color: var(--nnn-frame); }
.jg-nnn-tier.is-giratina { background: var(--type-ghost); }
.jg-nnn-tier.is-dialga { background: var(--type-dragon); }
.jg-nnn-tier.is-palkia { background: var(--type-fairy); color: var(--nnn-frame); }
.jg-nnn-tier.is-none { background: transparent; color: var(--nnn-muted); border-color: var(--nnn-line); border-style: dashed; box-shadow: none; }

/* ---------------- prize coupons */
.jg-nnn-coupons { display: flex; flex-wrap: wrap; gap: 5px; min-height: 28px; align-items: center; }
.jg-nnn-coupon {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 3px 8px;
	border-radius: 6px;
	border: 2px dashed var(--nnn-frame);
	background: var(--nnn-card2);
	color: var(--nnn-text);
	font-size: 12px;
	font-weight: 800;
	line-height: 1.3;
	white-space: nowrap;
}
.jg-nnn-coupon b { color: var(--nnn-red2); }
html[data-jg-theme="dark"] .jg-nnn-coupon b { color: var(--nnn-yellow); }
.jg-nnn-coupon.is-free-choice { border-color: var(--nnn-red); }
.jg-nnn-coupon.is-first-dibs { border-color: var(--nnn-blue); }
.jg-nnn-coupon.is-panty-collector { border-color: var(--nnn-st-lov); }

/* ---------------- weeks: past folded, current open, future locked cards */
.jg-nnn-weeks { display: flex; flex-direction: column; gap: 12px; }
.jg-nnn-week {
	min-width: 0;
	overflow: hidden;
	background: var(--nnn-card);
	color: var(--nnn-text);
	border: 3px solid var(--nnn-frame);
	border-radius: 10px;
	box-shadow: inset 0 0 0 2px var(--nnn-frame2), var(--nnn-shadow);
}
details.jg-nnn-week > summary { list-style: none; cursor: pointer; }
details.jg-nnn-week > summary::-webkit-details-marker { display: none; }
details.jg-nnn-week > summary::marker { content: ""; }
details.jg-nnn-week > summary:focus-visible { outline: 3px solid var(--nnn-yellow); outline-offset: -3px; }
.jg-nnn-week-head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 12px;
	padding: 9px 14px 8px;
	background: var(--nnn-blue);
	color: #fff;
}
details[open].jg-nnn-week > .jg-nnn-week-head,
.jg-nnn-week.is-future > .jg-nnn-week-head { border-bottom: 3px solid var(--nnn-frame); }
.jg-nnn-week.is-current .jg-nnn-week-head { background: var(--nnn-red); }
.jg-nnn-week.is-past .jg-nnn-week-head { background: var(--nnn-card2); color: var(--nnn-text); }
.jg-nnn-week.is-grace .jg-nnn-week-head { background: var(--nnn-gold); color: var(--nnn-frame); } /* week over, Horde Battle tasks still open */
.jg-nnn-week.is-grace > summary:focus-visible { outline-color: var(--nnn-frame); } /* yellow focus ring would vanish on the gold header */
.jg-nnn-week-kicker {
	font-family: var(--nnn-font-pixel);
	font-size: 13px;
	letter-spacing: .06em;
	text-transform: uppercase;
}
.jg-nnn-week-title { font-size: 15px; font-weight: 800; line-height: 1.25; }
.jg-nnn-week-dates { font-size: 12px; font-weight: 700; opacity: .85; }
.jg-nnn-week-sum { margin-left: auto; display: inline-flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12.5px; font-weight: 700; }
.jg-nnn-week-sum b { font-family: var(--nnn-font-pixel); font-weight: 400; font-size: 13px; }
.jg-nnn-week-frozen {
	padding: 1px 7px;
	border-radius: var(--nnn-radius-pill);
	border: 1px solid var(--nnn-line);
	font-size: 11px;
	font-weight: 700;
	color: var(--nnn-muted);
}
.jg-nnn-week-frozen.is-grace { border-color: var(--nnn-frame); background: var(--nnn-card); color: var(--nnn-text); }
.jg-nnn-task.is-closed:not(.is-done) .jg-nnn-task-text { opacity: .7; } /* frozen rows of a week in grace */
.jg-nnn-week-chev {
	flex: 0 0 auto;
	width: 9px;
	height: 9px;
	margin: -4px 2px 0 2px;
	border: solid currentColor;
	border-width: 0 3px 3px 0;
	transform: rotate(45deg);
	transition: transform .15s ease;
}
details[open] > summary .jg-nnn-week-chev { transform: rotate(-135deg); margin-top: 4px; }

.jg-nnn-week-body { position: relative; flex: 1; display: flex; flex-direction: column; }
.jg-nnn-task-list {
	list-style: none;
	margin: 0;
	padding: 12px;
	display: flex;
	flex-direction: column;
	gap: 8px;
}
/* ten tasks a week: two columns from tablet width up (row order = task number) */
.jg-nnn-task-list.is-cols { display: grid; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 760px) {
	.jg-nnn-task-list.is-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.jg-nnn-task {
	display: flex;
	align-items: stretch;
	gap: 8px;
	min-width: 0;
	padding: 9px 10px;
	border-radius: 8px;
	background: var(--nnn-card2);
	border: 1px solid var(--nnn-line);
	transition: background .15s ease, border-color .15s ease;
}
.jg-nnn-task.is-done {
	background: var(--nnn-card2);
	background: color-mix(in srgb, var(--nnn-hp-hi) 18%, var(--nnn-card));
	border-color: var(--nnn-hp-hi);
}
.jg-nnn-task.is-busy { opacity: .7; }
.jg-nnn-task-main { display: flex; align-items: flex-start; gap: 8px; flex: 1; min-width: 0; margin: 0; cursor: pointer; font-weight: inherit; }
.jg-nnn-task-no {
	flex: 0 0 auto;
	min-width: 22px;
	height: 20px;
	margin-top: 1px;
	padding: 0 4px;
	display: grid;
	place-items: center;
	border-radius: 4px;
	background: var(--nnn-frame);
	color: #fff;
	font-family: var(--nnn-font-pixel);
	font-size: 11px;
	line-height: 1;
}
.jg-nnn-task.is-done .jg-nnn-task-no { background: var(--nnn-hp-hi); color: var(--nnn-frame); }
.jg-nnn-task-text { flex: 1; min-width: 0; align-self: stretch; display: flex; flex-direction: column; }
.jg-nnn-task-label { display: block; font-size: 13.5px; font-weight: 700; line-height: 1.4; color: var(--nnn-text); overflow-wrap: anywhere; }
.jg-nnn-task-hint { display: block; margin-top: 3px; font-size: 12px; font-weight: 500; line-height: 1.45; color: var(--nnn-muted); overflow-wrap: anywhere; }
.jg-nnn-task-text a { color: var(--nnn-blue); font-weight: 800; text-decoration: underline; }
html[data-jg-theme="dark"] .jg-nnn-task-text a { color: var(--nnn-yellow); }
/* un-tick refused (points already spent): the rule, pinned under the row */
.jg-nnn-task-refusal { display: block; margin-top: 4px; font-size: 11.5px; font-weight: 700; line-height: 1.4; color: var(--nnn-red2); }
html[data-jg-theme="dark"] .jg-nnn-task-refusal { color: var(--nnn-yellow); }
.jg-nnn-task-cb {
	appearance: none;
	-webkit-appearance: none;
	flex: 0 0 20px;
	width: 20px;
	height: 20px;
	margin: 1px 0 0;
	display: grid;
	place-items: center;
	border: 2px solid var(--nnn-frame);
	border-radius: 4px;
	background: var(--nnn-card);
	box-shadow: inset 0 -2px 0 var(--nnn-line);
	cursor: pointer;
}
.jg-nnn-task-cb::after {
	content: "";
	width: 5px;
	height: 10px;
	margin-top: -2px;
	border: solid transparent;
	border-width: 0 3px 3px 0;
	transform: rotate(45deg);
}
.jg-nnn-task-cb:checked { background: var(--nnn-hp-hi); box-shadow: none; }
.jg-nnn-task-cb:checked::after { border-color: var(--nnn-frame); }
.jg-nnn-task-cb:focus-visible { outline: 2px solid var(--nnn-blue); outline-offset: 2px; }
.jg-nnn-task-cb:disabled { cursor: default; }
.jg-nnn-task-cb:disabled:not(:checked) { opacity: .55; }
.jg-nnn-task.is-ro .jg-nnn-task-main { cursor: default; }
.jg-nnn-task-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin-top: auto; padding-top: 7px; }
.jg-nnn-cat {
	display: inline-block;
	padding: 2px 6px 1px;
	border-radius: var(--nnn-radius-pill);
	border: 1px solid rgba(0, 0, 0, .35);
	color: #fff;
	font-family: var(--nnn-font-pixel);
	font-size: 9px;
	line-height: 13px;
	letter-spacing: .05em;
	text-transform: uppercase;
	white-space: nowrap;
}
.jg-nnn-cat.is-pokemon { background: var(--nnn-red); }
.jg-nnn-cat.is-nsfw { background: var(--nnn-st-lov); }
.jg-nnn-cat.is-discord { background: var(--type-dragon); }
.jg-nnn-cat.is-stream { background: var(--nnn-blue); }
.jg-nnn-cat.is-auto { background: var(--nnn-gold); color: var(--nnn-frame); }
.jg-nnn-task-pts {
	margin-left: auto;
	font-family: var(--nnn-font-pixel);
	font-size: 12px;
	color: var(--nnn-text);
	white-space: nowrap;
}
.jg-nnn-task-pts::after { content: " pts"; font-size: 9px; color: var(--nnn-muted); }

.jg-nnn-week-empty {
	margin: 0;
	padding: 22px 16px;
	text-align: center;
	font-size: 13.5px;
	font-style: italic;
	color: var(--nnn-muted);
}

/* locked (future) weeks: compact cards in a row, placeholder rows only — the
   real text never reaches the page */
.jg-nnn-weeks-locked { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; }
.jg-nnn-week.is-future { display: flex; flex-direction: column; min-height: 168px; }
.jg-nnn-week.is-future .jg-nnn-week-head { align-items: baseline; }
.jg-nnn-week.is-future .jg-nnn-week-dates { margin-left: auto; }
.jg-nnn-week.is-future .jg-nnn-week-title { flex: 1 0 100%; font-size: 14px; }
.jg-nnn-task-list.is-blur { filter: blur(6px); opacity: .5; pointer-events: none; user-select: none; }
.jg-nnn-task.is-fake { align-items: center; }
.jg-nnn-fake-box { flex: 0 0 18px; height: 18px; border: 2px solid var(--nnn-frame); border-radius: 4px; }
.jg-nnn-fake-bar { height: 12px; border-radius: 6px; background: var(--nnn-muted); opacity: .6; }
.jg-nnn-fake-pill { margin-left: auto; flex: 0 0 42px; height: 14px; border-radius: 4px; background: var(--nnn-red); opacity: .7; }
.jg-nnn-week-lock {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 8px;
	pointer-events: none;
}
.jg-nnn-week-lock-ico { font-size: 28px; line-height: 1; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .35)); }
.jg-nnn-week-lock-txt {
	padding: 5px 11px;
	border-radius: 6px;
	background: var(--nnn-card);
	color: var(--nnn-text);
	border: 2px solid var(--nnn-frame);
	box-shadow: 0 3px 0 var(--nnn-line);
	font-size: 13px;
	font-weight: 800;
}

@media (max-width: 640px) {
	.jg-nnn-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
	.jg-nnn-stat { padding: 8px 10px 9px; }
	.jg-nnn-stat-v { font-size: 18px; }
	.jg-nnn-week-head { padding: 8px 11px 7px; }
	.jg-nnn-week-sum { margin-left: 0; flex: 1 0 auto; }
	.jg-nnn-task-list { padding: 9px; }
}

/* ================================================================ guest teaser */
.jgcs.jg-nnn-teaser-wrap { padding-top: 0; }
.jg-nnn-teaser {
	max-width: 560px;
	margin: 16px auto;
	padding: 16px 18px 18px;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 8px;
	background: var(--nnn-card);
	color: var(--nnn-text);
	border: 3px solid var(--nnn-frame);
	border-radius: 10px;
	box-shadow: inset 0 0 0 2px var(--nnn-frame2), var(--nnn-shadow);
	font-size: 14px;
	line-height: 1.5;
}
.jg-nnn-teaser strong { font-size: 16px; color: var(--nnn-text); }
.jg-nnn-teaser span { color: var(--nnn-muted); }
.jg-nnn-teaser .jg-nnn-teaser-kicker {
	font-family: var(--nnn-font-pixel);
	font-size: 11px;
	letter-spacing: .06em;
	text-transform: uppercase;
	color: var(--nnn-red);
}
html[data-jg-theme="dark"] .jg-nnn-teaser .jg-nnn-teaser-kicker { color: var(--nnn-yellow); }
.jg-nnn-teaser .jg-nnn-btn { margin-top: 4px; color: #fff !important; text-decoration: none !important; }

/* ================================================================ toast */
.jg-nnn-toast {
	position: fixed;
	left: 50%;
	bottom: 24px;
	z-index: 100001;
	max-width: calc(100vw - 32px);
	padding: 10px 16px;
	border-radius: 8px;
	background: var(--nnn-card);
	color: var(--nnn-text);
	border: 3px solid var(--nnn-frame);
	box-shadow: inset 0 0 0 2px var(--nnn-frame2), 0 10px 30px rgba(0, 0, 0, .35);
	font-size: 14px;
	font-weight: 700;
	line-height: 1.4;
	opacity: 0;
	transform: translate(-50%, 16px);
	transition: opacity .18s ease, transform .18s ease;
	pointer-events: none;
}
.jg-nnn-toast.is-on { opacity: 1; transform: translate(-50%, 0); }
.jg-nnn-toast.is-err { border-left-width: 9px; border-left-color: var(--nnn-red); }
.jg-nnn-toast.is-ok { border-left-width: 9px; border-left-color: var(--nnn-hp-hi); }

/* ================================================================ NNN leaderboard */
.jg-nnn-lb .jgcs-lb-head { margin-bottom: 18px; }
.jg-nnn-lb-kicker {
	display: inline-block;
	margin-bottom: 6px;
	font-family: var(--nnn-font-pixel);
	font-size: 12px;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--nnn-red);
}
html[data-jg-theme="dark"] .jg-nnn-lb-kicker { color: var(--nnn-yellow); }
.jgcs.jg-nnn-lb .jgcs-lb-head h1 { color: var(--nnn-text); }
.jgcs.jg-nnn-lb .jgcs-lb-head p { color: var(--nnn-muted); max-width: 640px; margin: 0 auto; }
.jg-nnn-lb-you {
	max-width: 980px;
	margin: 0 auto 14px;
	padding: 9px 14px;
	border-radius: 8px;
	background: var(--nnn-card2);
	color: var(--nnn-text);
	border: 2px solid var(--nnn-frame);
	font-size: 14px;
	text-align: center;
}
.jg-nnn-lb-you b { font-family: var(--nnn-font-pixel); font-weight: 400; }
.jg-nnn-lb-you a { color: var(--nnn-blue); font-weight: 800; }
html[data-jg-theme="dark"] .jg-nnn-lb-you a { color: var(--nnn-yellow); }
.jg-nnn-lb-next {
	display: inline-block;
	margin-left: 6px;
	padding: 1px 8px;
	border-radius: var(--nnn-radius-pill);
	border: 1px solid var(--nnn-line);
	font-size: 12px;
	font-weight: 700;
	color: var(--nnn-muted);
	white-space: nowrap;
}

/* rank tiers legend */
.jg-nnn-lb-tiers {
	max-width: 980px;
	margin: 0 auto 12px;
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px 16px;
}
.jg-nnn-lb-tierkey { display: inline-flex; align-items: center; gap: 6px; }
.jg-nnn-lb-tierkey small { font-size: 12px; font-weight: 700; color: var(--nnn-muted); white-space: nowrap; }

.jg-nnn-lb-card {
	max-width: 980px;
	margin: 0 auto;
	padding: 10px 12px 12px;
	background: var(--nnn-card);
	color: var(--nnn-text);
	border: 3px solid var(--nnn-frame);
	border-radius: 10px;
	box-shadow: inset 0 0 0 2px var(--nnn-frame2), var(--nnn-shadow);
}
.jg-nnn-lb-empty { text-align: center; padding: 22px 18px; }
.jg-nnn-lb-empty p { margin: 0 0 12px; color: var(--nnn-muted); }
.jg-nnn-lb-empty .jg-nnn-btn { color: #fff !important; text-decoration: none !important; }
.jg-nnn-lb-headrow,
.jgcs.jg-nnn-lb .jg-nnn-lb-row {
	display: grid;
	grid-template-columns: 44px minmax(0, 1fr) 108px 74px 74px 96px 62px 50px;
	align-items: center;
	gap: 8px;
}
.jg-nnn-lb-headrow {
	padding: 6px 8px 9px;
	border-bottom: 3px solid var(--nnn-frame);
	font-family: var(--nnn-font-pixel);
	font-size: 11px;
	letter-spacing: .05em;
	text-transform: uppercase;
	color: var(--nnn-muted);
}
.jg-nnn-lb-headrow span:first-child,
.jg-nnn-lb-headrow span:nth-child(n+3) { text-align: center; }
.jg-nnn-lb-headrow .is-basis { color: var(--nnn-text); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }
.jg-nnn-lb-headrow .is-ico { font-family: initial; font-size: 15px; line-height: 1; }
.jg-nnn-lb-list { margin: 6px 0 0 !important; }
.jgcs.jg-nnn-lb .jg-nnn-lb-row {
	padding: 7px 8px;
	border-radius: 6px;
	background: transparent;
	color: var(--nnn-text);
	font-size: 14px;
	outline: 0;
}
.jgcs.jg-nnn-lb .jg-nnn-lb-row:nth-child(odd) { background: var(--nnn-card2); }
.jgcs.jg-nnn-lb .jg-nnn-lb-row.is-me {
	background: rgba(255, 210, 74, .3);
	background: color-mix(in srgb, var(--nnn-yellow) 30%, var(--nnn-card));
	outline: 2px solid var(--nnn-red);
}
html[data-jg-theme="dark"] .jgcs.jg-nnn-lb .jg-nnn-lb-row.is-me {
	background: rgba(255, 210, 74, .16);
	background: color-mix(in srgb, var(--nnn-yellow) 20%, var(--nnn-card));
	outline-color: var(--nnn-yellow);
}
.jgcs.jg-nnn-lb .jgcs-lb-rank { width: auto; font-family: var(--nnn-font-pixel); font-weight: 400; font-size: 14px; color: var(--nnn-text); text-align: center; }
.jg-nnn-lb-who { display: flex; align-items: center; gap: 8px; min-width: 0; }
.jgcs.jg-nnn-lb .jgcs-lb-name { flex: 0 1 auto; color: var(--nnn-text); }
.jgcs.jg-nnn-lb .jgcs-lb-ava { width: 26px; height: 26px; box-shadow: 0 0 0 2px var(--nnn-frame); }
.jgcs.jg-nnn-lb .jgcs-lb-ava.is-empty { background: var(--nnn-line); }
.jg-nnn-lb-num { flex: 0 0 auto; font-style: normal; font-size: 12px; font-weight: 700; color: var(--nnn-muted); }
.jg-nnn-lb-medal { font-family: initial; font-size: 19px; line-height: 1; }
.jg-nnn-lb-tier { display: flex; justify-content: center; min-width: 0; }
.jg-nnn-lb-earned,
.jg-nnn-lb-pts { text-align: center; font-family: var(--nnn-font-pixel); font-size: 13px; color: var(--nnn-muted); white-space: nowrap; }
.jg-nnn-lb-earned.is-basis,
.jg-nnn-lb-pts.is-basis { font-size: 16px; color: var(--nnn-text); }
.jg-nnn-lb-badges { display: flex; justify-content: center; gap: 3px; min-height: 20px; }
.jg-nnn-lb-badges img { width: 20px; height: 20px; display: block; }
.jg-nnn-lb-badges i { font-style: normal; color: var(--nnn-muted); }
.jg-nnn-lb-tro,
.jg-nnn-lb-tasks { text-align: center; font-family: var(--nnn-font-pixel); font-size: 13px; color: var(--nnn-text); }
.jg-nnn-lb-br { display: none; }
.jg-nnn-lb-foot { max-width: 980px; margin: 14px auto 0; text-align: center; font-size: 13px; color: var(--nnn-muted); }
.jg-nnn-lb-foot a { color: var(--nnn-blue); font-weight: 700; }
html[data-jg-theme="dark"] .jg-nnn-lb-foot a { color: var(--nnn-yellow); }

@media (max-width: 760px) {
	.jg-nnn-lb-headrow { display: none; }
	/* every line of a row starts past the rank, wrapped counters included */
	.jgcs.jg-nnn-lb .jg-nnn-lb-row { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 5px 8px; padding-left: 44px; }
	.jgcs.jg-nnn-lb .jgcs-lb-rank { position: absolute; left: 6px; top: 9px; width: 30px; order: 1; }
	.jg-nnn-lb-who { flex: 1 1 0; order: 2; }
	.jg-nnn-lb-earned.is-basis,
	.jg-nnn-lb-pts.is-basis { flex: 0 0 auto; order: 3; }
	.jg-nnn-lb-br { display: block; flex: 0 0 100%; height: 0; order: 4; }
	.jg-nnn-lb-tier { order: 5; }
	.jg-nnn-lb-earned,
	.jg-nnn-lb-pts { order: 6; font-size: 12px; }
	/* the header row is gone: every number carries its unit, the basis one included */
	.jg-nnn-lb-earned::after { content: " earned"; }
	.jg-nnn-lb-pts::after { content: " pts"; }
	.jg-nnn-lb-earned.is-basis::after,
	.jg-nnn-lb-pts.is-basis::after { font-size: 11px; color: var(--nnn-muted); }
	.jg-nnn-lb-badges { order: 7; justify-content: flex-start; }
	.jg-nnn-lb-tro { order: 8; }
	.jg-nnn-lb-tasks { order: 9; }
	.jg-nnn-lb-tro::before { content: "🏆 "; font-family: initial; }
	.jg-nnn-lb-tasks::before { content: "✓ "; font-family: initial; }
	.jg-nnn-lb-tro,
	.jg-nnn-lb-tasks { font-size: 12px; }
}
