:root {
	--bg: #f4f8fb;
	--card: #fff;
	--text: #132033;
	--muted: #657489;
	--line: #dce7f1;
	--blue: #0b87d1;
	--blue2: #1db6ff;
	--green: #22b573;
	--shadow: 0 14px 34px rgba(26, 72, 110, .11);
}

* { box-sizing: border-box; }

body {
	margin: 0;
	font-family: Arial, Helvetica, sans-serif;
	color: var(--text);
	background:
		radial-gradient(circle at 10% 0, rgba(29, 182, 255, .18), transparent 30%),
		linear-gradient(180deg, #fff 0, var(--bg) 360px);
}

a { color: var(--blue); text-decoration: none; }
a:hover { color: #005f9d; }

.user-badge {
	position: fixed;
	top: 14px;
	right: 14px;
	z-index: 10;
	display: flex;
	align-items: center;
	gap: 9px;
	max-width: min(280px, calc(100vw - 28px));
	padding: 8px 11px 8px 8px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: rgba(255, 255, 255, .92);
	box-shadow: 0 10px 28px rgba(26, 72, 110, .12);
	backdrop-filter: blur(10px);
}

.user-badge img,
.user-badge span {
	width: 32px;
	height: 32px;
	border-radius: 50%;
	object-fit: cover;
	flex: 0 0 auto;
	background: linear-gradient(135deg, var(--blue), var(--blue2));
	color: #fff;
	display: grid;
	place-items: center;
	font-weight: 800;
}

.user-badge b {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	font-size: 14px;
}

.user-badge .user-logout {
	font-size: 12px;
	color: var(--muted);
	white-space: nowrap;
}
.user-badge .user-logout:hover { color: var(--text); }

.top,
main,
footer {
	width: min(1180px, calc(100% - 32px));
	margin: 0 auto;
}

.legal-footer {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	padding: 24px 0;
	color: var(--muted);
	font-size: 14px;
}

.pdn-cookie {
	position: fixed;
	left: 12px;
	right: 12px;
	bottom: 12px;
	z-index: 50;
	max-width: 920px;
	margin: auto;
	padding: 13px 14px;
	border: 1px solid var(--line);
	border-radius: 16px;
	background: var(--card);
	color: var(--text);
	font-size: 14px;
	line-height: 1.45;
}

.pdn-cookie button {
	float: right;
	margin-left: 14px;
	padding: 8px 12px;
}

.top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 0 8px;
}

.brand {
	font-size: 24px;
	font-weight: 800;
	letter-spacing: -.03em;
	color: var(--text);
}

.brand span {
	margin-left: 6px;
	color: var(--blue);
}

.top nav {
	display: flex;
	gap: 18px;
	font-size: 14px;
}

.hero {
	display: grid;
	grid-template-columns: minmax(0, 1.25fr) minmax(280px, .75fr);
	gap: 28px;
	align-items: end;
	padding: 12px 0 24px;
}

.eyebrow {
	margin: 0 0 12px;
	color: var(--green);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .08em;
	font-size: 13px;
}

h1 {
	margin: 0 0 18px;
	font-size: clamp(36px, 7vw, 68px);
	line-height: .95;
	letter-spacing: -.06em;
}

h1 a { color: inherit; }

.hero-logo {
	width: .86em;
	height: .86em;
	margin-right: .18em;
	border-radius: .22em;
	vertical-align: -.1em;
	object-fit: cover;
}

.hero p {
	max-width: 740px;
	margin: 0;
	color: var(--muted);
	font-size: 18px;
	line-height: 1.55;
}

.search {
	display: flex;
	gap: 10px;
	padding: 8px;
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: 18px;
	box-shadow: var(--shadow);
}

.search input {
	min-width: 0;
	flex: 1;
	border: 0;
	outline: 0;
	padding: 14px 12px;
	font-size: 16px;
	background: transparent;
}

button,
.primary {
	border: 0;
	border-radius: 13px;
	padding: 13px 18px;
	background: linear-gradient(135deg, var(--blue), var(--blue2));
	color: #fff;
	font-weight: 700;
	cursor: pointer;
}

.primary:hover,
button:hover { color: #fff; filter: brightness(.96); }

.categories {
	display: flex;
	gap: 10px;
	overflow-x: auto;
	padding: 4px 0 20px;
	scrollbar-width: thin;
}

.categories a {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	white-space: nowrap;
	padding: 10px 14px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: rgba(255, 255, 255, .78);
	color: var(--text);
}

.categories a.active {
	border-color: transparent;
	background: var(--text);
	color: #fff;
}

.categories small {
	color: var(--muted);
	font-size: 12px;
}

.categories a.active small { color: rgba(255, 255, 255, .72); }

.sort-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 0 0 20px;
}

.sort-tabs a {
	padding: 10px 14px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: rgba(255, 255, 255, .78);
	color: var(--text);
}

.sort-tabs a.active {
	border-color: transparent;
	background: var(--blue);
	color: #fff;
}

.intro {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	margin: 10px 0 24px;
	padding: 18px 20px;
	border: 1px solid var(--line);
	border-radius: 22px;
	background: rgba(255, 255, 255, .72);
}

.intro div {
	display: flex;
	align-items: baseline;
	gap: 8px;
	white-space: nowrap;
}

.intro b {
	font-size: 34px;
	letter-spacing: -.05em;
}

.intro p {
	margin: 0;
	color: var(--muted);
	line-height: 1.45;
}

.grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 18px;
}

.card {
	display: flex;
	flex-direction: column;
	min-height: 285px;
	padding: 20px;
	border: 1px solid var(--line);
	border-radius: 24px;
	background: var(--card);
	box-shadow: 0 8px 24px rgba(26, 72, 110, .07);
	cursor: pointer;
}

.card.my-vote {
	border-color: rgba(34, 181, 115, .55);
	box-shadow: 0 10px 30px rgba(34, 181, 115, .13);
}

.card-head,
.actions,
.auth {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}

.identity {
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
}

.identity img,
.avatar-fallback {
	width: 42px;
	height: 42px;
	border-radius: 14px;
	object-fit: cover;
	flex: 0 0 auto;
	background: linear-gradient(135deg, var(--blue), var(--blue2));
}

.avatar-fallback {
	display: grid;
	place-items: center;
	color: #fff;
	font-weight: 800;
}

.type {
	padding: 6px 10px;
	border-radius: 999px;
	background: #eef8ff;
	color: var(--blue);
	font-size: 13px;
	font-weight: 700;
}

.members {
	color: var(--muted);
	font-size: 13px;
}

.card h2 {
	margin: 18px 0 10px;
	font-size: 22px;
	line-height: 1.16;
	letter-spacing: -.03em;
}

.card h2 a { color: inherit; }

/* РКН / госуслуги snet — бейдж рядом с названием */
.rkn-a-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin-left: 6px;
	padding: 2px 7px;
	font-size: 11px;
	font-weight: 800;
	line-height: 1.15;
	letter-spacing: -0.02em;
	color: #fff;
	background: linear-gradient(180deg, #38a0ff, #1678d8);
	border-radius: 6px;
	vertical-align: middle;
	cursor: help;
	box-shadow: 0 1px 4px rgba(22, 120, 216, .35);
}
.item-page h1 .rkn-a-badge,
.card h2 .rkn-a-badge { vertical-align: 0.12em; }

.card p {
	margin: 0 0 14px;
	color: var(--muted);
	line-height: 1.48;
	overflow-wrap: anywhere;
}

.card h2 { overflow-wrap: anywhere; }

.tags {
	display: flex;
	flex-wrap: wrap;
	gap: 7px;
	margin: auto 0 16px;
}

.tags a {
	padding: 6px 9px;
	border-radius: 999px;
	background: #f2f6fa;
	color: var(--muted);
	font-size: 12px;
}

.tags .tag-add {
	min-width: 28px;
	text-align: center;
	background: #e9f9f1;
	color: var(--green);
	font-weight: 900;
}

.metrics {
	display: grid;
	justify-items: end;
	gap: 3px;
	color: var(--muted);
	font-size: 12px;
	line-height: 1.1;
}

.metrics b {
	color: var(--text);
	font-size: 18px;
}

.card .metrics {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 8px;
}
.card .metrics .vote-line {
	display: inline-flex;
	align-items: center;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: 6px;
	max-width: 100%;
	padding: 6px 10px;
	border-radius: 999px;
	background: #f2f7fb;
	font-size: 13px;
	color: var(--muted);
}
.card .metrics .vote-line.voted {
	background: #dff8eb;
	color: #0b8b55;
}
.card .metrics .vote-line.voted .js-votes {
	color: #0b8b55;
	font-weight: 700;
}
.card .metrics .vote-thumb {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin-left: 0;
	padding: 2px 6px;
	border-radius: 8px;
	font-size: 1.15rem;
	line-height: 1;
	text-decoration: none;
	cursor: pointer;
}
.card .metrics .js-rating { font-size: 12px; color: var(--muted); }
.card .metrics .js-rating b { font-size: 17px; color: var(--text); }

body.modal-open { overflow: hidden; }
.vote-confirm {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	background: rgba(19, 32, 51, .45);
}
/* author display:flex beats UA [hidden]; keep modal off-screen until JS opens it */
.vote-confirm[hidden] {
	display: none !important;
}
.vote-confirm-card {
	position: relative;
	max-width: 420px;
	width: 100%;
	padding: 22px 20px 18px;
	border-radius: 20px;
	background: #fff;
	box-shadow: 0 20px 50px rgba(0, 0, 0, .2);
}
.vote-confirm-card h3 { margin: 0 0 14px; font-size: 18px; }
.vote-confirm-close {
	position: absolute;
	top: 10px;
	right: 12px;
	border: 0;
	background: transparent;
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
	color: var(--muted);
}
.vote-confirm-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
}
.vote-bot-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	padding: 14px 10px;
	border: 1px solid var(--line);
	border-radius: 14px;
	text-align: center;
	color: var(--text);
	font-weight: 700;
}
.vote-bot-card img {
	width: 52px;
	height: 52px;
	border-radius: 16px;
	object-fit: cover;
}
.vote-fallback { margin-top: 14px; color: var(--muted); font-size: 13px; line-height: 1.45; }

/* список репостов: api format=html и модалка #mc-reposts-modal */
.mc-reposts-list {
	border: 1px solid var(--line, #ccc);
	border-radius: 1em;
	max-width: 520px;
	max-height: 70vh;
	overflow-y: auto;
	background: #fff;
	padding: 0.35em 0.75em 0.75em;
	margin: 0;
}
.mc-reposts-empty {
	margin: 0.5em 0 0;
	color: var(--muted);
	font-size: 15px;
}
.mc-reposts-row {
	padding: 0.35em 0;
	border-bottom: 1px solid var(--line);
	font-size: 14px;
	line-height: 1.35;
}
.mc-reposts-row:last-child { border-bottom: none; }
.mc-reposts-peer { font-weight: 600; }
.mc-reposts-peer a { font-weight: 600; }
button.mc-stat-reposts {
	border: none;
	background: none;
	padding: 0;
	font: inherit;
	color: #0066cc;
	cursor: pointer;
	text-decoration: underline;
	text-underline-offset: 2px;
}
button.mc-stat-reposts:hover { color: #004499; }
#mc-reposts-modal .mc-reposts-card {
	max-width: min(520px, 92vw);
	max-height: 85vh;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	padding: 22px 20px 18px;
}
#mc-reposts-modal .mc-reposts-list {
	flex: 1 1 auto;
	min-height: 0;
	max-height: min(60vh, 420px);
	margin-top: 0.5em;
	width: 100%;
	box-sizing: border-box;
}

.auth {
	justify-content: flex-start;
	flex-wrap: wrap;
	margin-top: 16px;
	padding-top: 14px;
	border-top: 1px solid var(--line);
	color: var(--muted);
	font-size: 13px;
}

.auth a {
	padding: 7px 10px;
	border-radius: 10px;
	background: #f2f7fb;
	font-weight: 700;
}

.auth .vote-toggle.voted,
.item-actions .vote-toggle.voted {
	background: #dff8eb;
	color: #0b8b55;
	font-weight: 900;
}

.item-actions .vote-toggle {
	padding: 13px 16px;
	border-radius: 13px;
	background: #f2f7fb;
	font-weight: 700;
}

.empty {
	padding: 46px 20px;
	text-align: center;
	border: 1px dashed var(--line);
	border-radius: 24px;
	background: rgba(255, 255, 255, .65);
}

.category-editor {
	padding-top: 34px;
	max-width: 760px;
}

.category-editor h1 {
	font-size: clamp(34px, 7vw, 58px);
}
.category-editor h1 a {
	display: inline-flex;
	align-items: center;
	gap: 10px;
}

.category-editor h2 {
	margin: 0 0 18px;
	font-size: 28px;
}

.category-form {
	display: grid;
	gap: 10px;
	padding: 18px;
	border: 1px solid var(--line);
	border-radius: 24px;
	background: #fff;
	box-shadow: var(--shadow);
}

.category-form label {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 12px;
	border-radius: 14px;
	background: #f5f9fc;
}

.category-form button {
	margin-top: 10px;
	width: max-content;
}

.category-field-label {
	display: flex;
	flex-direction: column;
	gap: 6px;
	font-size: 14px;
	color: var(--muted);
	font-weight: 600;
}
.category-field-label span { color: var(--text); }
.category-textarea {
	width: 100%;
	min-height: 120px;
	padding: 10px 12px;
	border: 1px solid var(--line);
	border-radius: 12px;
	font-size: 15px;
	font-family: inherit;
	resize: vertical;
}
.category-geo-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 14px;
}
@media (max-width: 560px) {
	.category-geo-row { grid-template-columns: 1fr; }
}
.category-select {
	padding: 9px 11px;
	border: 1px solid var(--line);
	border-radius: 10px;
	font-size: 15px;
	background: #fff;
}
.category-form-h3 {
	margin: 18px 0 8px;
	font-size: 17px;
}
.category-hint {
	margin: 0 0 8px;
	font-size: 13px;
	color: var(--muted);
	line-height: 1.45;
}
.item-cat-ok {
	margin: 0 0 14px;
}
.item-cat-ok a { font-weight: 700; margin-left: 8px; }

.success {
	padding: 12px 14px;
	border-radius: 14px;
	background: #e9f9f1;
	color: #13784a;
}

.item-page {
	max-width: 920px;
	margin: 0 auto;
	padding: 34px 0 20px;
}

.item-page h1 {
	font-size: clamp(28px, 5vw, 42px);
	line-height: 1.08;
	letter-spacing: -.04em;
	margin-bottom: 12px;
}

.item-page .eyebrow a {
	color: inherit;
	text-decoration: none;
}
.item-page .eyebrow a:hover { color: var(--text); }

.breadcrumbs {
	margin: 0 0 12px;
	font-size: 13px;
	color: var(--muted, #5b6b7a);
	line-height: 1.5;
}
.breadcrumbs a { color: var(--link, #0b63d1); text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }

.item-headbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin-bottom: 10px;
	padding: 8px 10px;
	border: 1px solid var(--line);
	border-radius: 14px;
	background: rgba(255, 255, 255, .72);
	position: sticky;
	top: 8px;
	z-index: 4;
	backdrop-filter: blur(8px);
	transition: box-shadow .2s ease, background-color .2s ease;
}

.item-scrolled .item-headbar { box-shadow: 0 8px 20px rgba(26, 72, 110, .12); background: rgba(255, 255, 255, .9); }

.item-brand-top {
	margin: 0;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: .02em;
}

.item-brand-top a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: var(--muted);
}

.item-brand-top a:hover { color: var(--text); }

.item-hero {
	display: grid;
	grid-template-columns: 132px minmax(0, 1fr);
	gap: 24px;
	align-items: center;
	margin-bottom: 26px;
	padding: 24px;
	border: 1px solid var(--line);
	border-radius: 28px;
	background: #fff;
	box-shadow: var(--shadow);
}

.item-avatar img,
.item-avatar {
	width: 132px;
	height: 132px;
	border-radius: 34px;
	object-fit: cover;
	background: linear-gradient(135deg, var(--blue), var(--blue2));
}

.item-hero h1 {
	margin-bottom: 8px;
	font-size: clamp(34px, 6vw, 56px);
}

.item-hero h2 {
	margin: 0;
	font-size: clamp(26px, 5vw, 42px);
	line-height: 1.06;
	letter-spacing: -.04em;
	overflow-wrap: anywhere;
}

.item-type-badge {
	display: inline-block;
	margin: 0 0 10px;
	padding: 7px 12px;
	border-radius: 999px;
	background: rgba(34, 181, 115, .12);
	color: #16975f;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .08em;
	font-size: 12px;
}

.item-type-badge--bot { background: rgba(11, 135, 209, .12); color: #0b87d1; }
.item-type-badge--channel { background: rgba(34, 181, 115, .12); color: #16975f; }
.item-type-badge--chat { background: rgba(124, 90, 255, .12); color: #6b4ce6; }

.item-back {
	display: inline-block;
	padding: 7px 12px;
	border-radius: 999px;
	background: #f2f7fb;
	font-weight: 700;
	color: var(--text);
	font-size: 13px;
}

.item-back:hover { background: #e8f1f8; color: var(--text); }

.item-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 16px;
	color: var(--muted);
}

.item-meta span {
	padding: 8px 11px;
	border-radius: 999px;
	background: #f2f7fb;
}

.vote-line {
	display: inline;
}
.item-meta .vote-line.voted {
	background: #dff8eb;
	color: #0b8b55;
}
.item-meta .vote-line.voted .js-votes { color: #0b8b55; }

.vote-thumb {
	display: inline;
	margin-left: 4px;
	background: transparent;
	color: #6b7280;
	font-weight: 700;
	transition: color .15s ease;
}

.vote-thumb.voted {
	color: #0b8b55;
}

.item-block {
	margin: 18px 0;
	padding: 22px;
	border: 1px solid var(--line);
	border-radius: 24px;
	background: rgba(255, 255, 255, .78);
}

.item-block h2,
.item-block h3 {
	margin: 0 0 12px;
	font-size: 20px;
	line-height: 1.25;
	color: var(--text);
}

.item-block p {
	margin: 0;
	color: var(--muted);
	line-height: 1.6;
	overflow-wrap: anywhere;
}

.item-block p + p,
.item-block p + .add-bot-grid,
.item-block .add-bot-grid + p,
.item-block p + .add-steps,
.item-block h3 + .add-steps { margin-top: 14px; }

.muted {
	font-size: 14px;
	color: var(--muted);
	line-height: 1.5;
}

.item-type-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin-bottom: 6px;
}

.item-type-badge {
	display: inline-flex;
	align-items: center;
	padding: 4px 10px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 700;
	line-height: 1;
	margin: 0;
}

.item-type-badge--bot { background: #ede9fe; color: #5b21b6; }
.item-type-badge--channel { background: #dbeafe; color: #1d4ed8; }
.item-type-badge--chat { background: #dcfce7; color: #166534; }
.item-entity-id-wrap {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
	justify-content: flex-end;
}
.item-entity-id {
	color: #6b7280;
	font-size: 13px;
	font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}
.item-src-bot {
	display: inline-flex;
	align-items: center;
	border-radius: 6px;
	overflow: hidden;
	border: 1px solid var(--line, #e5e7eb);
	line-height: 0;
	transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.item-src-bot:hover {
	transform: scale(1.06);
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}
.item-src-bot img {
	display: block;
	width: 22px;
	height: 22px;
	object-fit: cover;
}
.item-src-bot--stale {
	display: inline-flex;
	align-items: center;
	padding: 2px 7px;
	font-size: 11px;
	line-height: 1.2;
	color: #9a3412;
	background: #fff7ed;
	border: 1px solid #fdba74;
	border-radius: 6px;
	cursor: help;
	white-space: nowrap;
}
.item-src-bot--stale:hover {
	transform: none;
	box-shadow: none;
}

.analytics-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 10px;
	margin: 8px 0 14px;
}
.analytics-grid--channel { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.analytics-grid--other { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.analytics-card {
	border: 1px solid var(--line);
	border-radius: 10px;
	padding: 10px 12px;
	background: #fff;
	min-height: 74px;
}
.analytics-card b {
	display: block;
	font-size: 14px;
	margin-bottom: 6px;
	color: var(--text);
	line-height: 1.25;
}
.analytics-card > span {
	display: block;
	font-size: 19px;
	font-weight: 700;
	line-height: 1.1;
	color: var(--text);
}
.analytics-card small {
	display: block;
	margin-top: 4px;
	color: var(--muted);
	font-size: 13px;
	line-height: 1.2;
}
.metric-help { cursor: help; color: var(--muted); }
.err-rows { display: grid; gap: 3px; }
.err-row { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; }
.err-row span { font-size: 14px; font-weight: 400; color: var(--text); }
.err-row strong { font-size: 16px; font-weight: 700; color: var(--text); }

.analytics-table-toolbar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 8px;
	margin: 10px 0 8px;
}
.analytics-table-title { font-size: 16px; }
.analytics-export-btn {
	border: 1px solid var(--line);
	background: #fff;
	border-radius: 8px;
	padding: 7px 11px;
	color: var(--text);
}

.analytics-controls-row {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 10px;
}
.analytics-controls {
	flex: 1;
	min-width: 180px;
	display: flex;
	flex-wrap: wrap;
	gap: 10px 14px;
	align-items: center;
}
.analytics-controls label { margin: 0; white-space: nowrap; }
.analytics-range-wrap { flex-shrink: 0; }
.analytics-range-wrap label { font-size: 14px; white-space: nowrap; }
.analytics-range-select {
	margin-left: 6px;
	padding: 4px 8px;
	border-radius: 6px;
	border: 1px solid var(--line);
}

.analytics-chart-wrap { position: relative; width: 100%; height: 250px; margin: 8px 0 10px; }
.analytics-table-wrap { overflow: auto; }
.analytics-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.analytics-table th,
.analytics-table td {
	border-bottom: 1px solid var(--line);
	padding: 8px 10px;
	text-align: left;
	white-space: nowrap;
	vertical-align: middle;
}
.analytics-table th {
	background: #f9fafb;
	font-weight: 600;
	position: sticky;
	top: 0;
	z-index: 1;
}
.growth-bc { color: #6b7280; font-weight: normal; font-size: 0.92em; }
.growth-net-pos { color: #16a34a; font-weight: 600; }
.growth-net-neg { color: #dc2626; font-weight: 600; }
.growth-muted { color: #9ca3af; }
.analytics-table td.plus .growth-a { color: #16a34a; font-weight: 600; }
.analytics-table td.minus .growth-a { color: #dc2626; font-weight: 600; }

.hist-load-block { margin-top: 14px; padding-top: 8px; border-top: 1px dashed var(--line); }
.hist-load-label { margin: 0 0 8px; color: #374151; font-weight: 600; }
.hist-load-form .hist-load-actions { display: inline-flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.regional-load-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; }
.regional-load-form label { display: flex; flex-direction: column; gap: 4px; font-size: 14px; color: #374151; }
.regional-load-form input,
.regional-load-form select {
	min-width: 90px;
	height: 34px;
	border: 1px solid var(--line);
	border-radius: 8px;
	padding: 0 8px;
}
.regional-load-form button {
	height: 36px;
	border: 0;
	border-radius: 18px;
	background: linear-gradient(135deg, var(--blue), var(--blue2));
	color: #fff;
	padding: 0 18px;
	cursor: pointer;
	font-weight: 600;
}

.vote-cmd-clickable {
	display: block;
	margin-top: 8px;
	cursor: pointer;
	user-select: all;
	padding: 10px 12px;
	border-radius: 8px;
	background: #1f2937;
	color: #f9fafb;
	font-size: 15px;
	line-height: 1.4;
}
.vote-cmd-clickable:hover { background: #374151; }
.vote-copy-toast {
	position: fixed;
	bottom: 32px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 100001;
	padding: 10px 20px;
	background: #111827;
	color: #fff;
	border-radius: 10px;
	font-size: 14px;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
	pointer-events: none;
	opacity: 0;
	transition: opacity .2s;
}
.vote-copy-toast.vote-copy-toast--on { opacity: 1; }

.add-page-header {
	margin-bottom: 8px;
	padding: 0 2px;
}

.add-lead {
	font-size: 17px;
	line-height: 1.55;
	margin: 0;
	color: var(--muted);
	max-width: 720px;
}

.add-step-num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 1.65em;
	height: 1.65em;
	margin-right: 8px;
	padding: 0 6px;
	border-radius: 999px;
	background: rgba(11, 135, 209, .12);
	color: var(--blue);
	font-size: 14px;
	font-weight: 800;
	vertical-align: middle;
}

.add-bot-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 14px;
}

.add-bot-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	padding: 20px 14px;
	border: 1px solid var(--line);
	border-radius: 20px;
	text-align: center;
	text-decoration: none;
	color: var(--text);
	background: #fff;
	box-shadow: 0 4px 18px rgba(26, 72, 110, .06);
	transition: border-color .15s, box-shadow .15s, transform .15s;
}

.add-bot-card:hover {
	border-color: var(--blue);
	box-shadow: 0 10px 28px rgba(11, 99, 209, .14);
	transform: translateY(-2px);
}

.add-bot-card img {
	width: 64px;
	height: 64px;
	border-radius: 18px;
	object-fit: cover;
}

.add-bot-card b { font-size: 16px; }
.add-bot-card span { font-size: 13px; color: var(--muted); line-height: 1.4; }
.add-bot-card em {
	font-size: 13px;
	color: var(--blue);
	font-style: normal;
	font-weight: 700;
	margin-top: 2px;
}

.add-steps {
	margin: 0;
	padding-left: 1.35em;
	color: var(--muted);
	line-height: 1.6;
}

.add-steps-ul { list-style: disc; padding-left: 1.25em; }
.add-steps li { margin-bottom: 10px; }
.add-steps li:last-child { margin-bottom: 0; }

.add-actions {
	margin-top: 4px;
	padding-top: 4px;
}

.item-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 20px 0 42px;
}

.item-actions a:not(.primary) {
	padding: 13px 16px;
	border-radius: 13px;
	background: #f2f7fb;
	font-weight: 700;
}

.secondary-primary {
	background: linear-gradient(135deg, var(--green), #64d8a3);
}

#load-more {
	margin: 28px auto 6px;
	padding: 14px 18px;
	width: max-content;
	max-width: 100%;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: rgba(255, 255, 255, .8);
	color: var(--muted);
	font-size: 14px;
}

footer {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	padding: 38px 0;
	color: var(--muted);
	font-size: 14px;
}

@media (max-width: 900px) {
	.hero { grid-template-columns: 1fr; padding-top: 30px; }
	.grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.geo-filter {
	margin: 0 auto 18px;
	padding: 14px 16px;
	border: 1px solid var(--line);
	border-radius: 14px;
	background: var(--card);
	box-shadow: var(--shadow);
	max-width: min(1180px, calc(100% - 32px));
}
.geo-filter-form {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 14px 20px;
}
.geo-filter-label {
	display: flex;
	flex-direction: column;
	gap: 6px;
	font-size: 13px;
	color: var(--muted);
	min-width: min(200px, 100%);
}
.geo-filter-label span { font-weight: 600; color: var(--text); }
.geo-filter-label select {
	padding: 9px 11px;
	border: 1px solid var(--line);
	border-radius: 10px;
	font-size: 15px;
	color: var(--text);
	background: #fff;
	max-width: 100%;
}
.geo-filter-reset {
	align-self: center;
	font-size: 14px;
	white-space: nowrap;
}

@media (max-width: 640px) {
	.user-badge {
		top: auto;
		right: 10px;
		bottom: 10px;
		display: grid;
		grid-template-columns: 28px minmax(0, 1fr) auto;
		align-items: center;
		column-gap: 8px;
		max-width: calc(100vw - 20px);
		padding: 7px 10px 7px 7px;
	}
	.user-badge img,
	.user-badge span { width: 28px; height: 28px; }
	.user-badge b {
		min-width: 0;
		max-width: 100%;
		font-size: 13px;
		overflow: hidden;
		white-space: nowrap;
		text-overflow: ellipsis;
		-webkit-mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 18px), transparent);
		mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 18px), transparent);
	}
	.user-badge .user-logout {
		font-size: 11px;
		flex: 0 0 auto;
		white-space: nowrap;
	}
	.top { align-items: flex-start; gap: 12px; flex-direction: column; }
	.top nav { width: 100%; overflow-x: auto; padding-bottom: 4px; }
	.search { flex-direction: column; }
	.geo-filter-form { flex-direction: column; align-items: stretch; }
	.intro { align-items: flex-start; flex-direction: column; }
	.grid { grid-template-columns: 1fr; }
	.card { min-height: 0; }
	footer { flex-direction: column; }
	.item-headbar { top: 6px; }
	.item-hero {
		grid-template-columns: 1fr;
		padding: 18px;
		gap: 14px;
	}
	.item-avatar,
	.item-avatar img {
		width: 96px;
		height: 96px;
		border-radius: 24px;
	}
	.item-hero h1 { font-size: clamp(28px, 8vw, 42px); }
	.add-bot-grid { grid-template-columns: 1fr; }
	.add-actions .primary { flex: 1 1 100%; justify-content: center; text-align: center; }
	.analytics-grid { grid-template-columns: 1fr; }
	.analytics-grid--channel,
	.analytics-grid--other { grid-template-columns: 1fr; }
	.analytics-table th, .analytics-table td { padding: 7px 8px; }
	.analytics-chart-wrap { height: 220px; }
}
