/* CUSTOM rukoeb.love: шапка страницы модели, студии и канала (ops/entity_head, 14.11). Цвета — переменные темы,
   рейтинг — --rkb-rate-green/red (video_rate_colors). Подключается из include_rkb_entity_head.tpl. */

.rkb-eh {
	--eh-accent: #d4153f;
	--eh-accent-hover: #e50036;
	--eh-surface: var(--th-bg-5);
	--eh-subtle: var(--th-bg-32);
	--eh-line: var(--th-line-2);
	--eh-text: var(--th-text-1);
	--eh-muted: var(--th-text-21);
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	align-items: start;
	gap: 24px;
	margin: 24px 0 8px;
	padding: 0 0 22px;
	border-bottom: 1px solid var(--eh-line);
	color: var(--eh-text);
}

/* ---------- аватар ---------- */
.rkb-eh__media {
	position: relative;
	flex: none;
	overflow: visible;
}

.rkb-eh__media > img:not(.rkb-model-flag),
.rkb-eh__media > .rkb-eh__noimg {
	display: block;
	background: var(--eh-surface);
}

.rkb-eh--model .rkb-eh__media > img:not(.rkb-model-flag),
.rkb-eh--model .rkb-eh__media > .rkb-eh__noimg {
	width: 168px;
	height: 168px;
	border-radius: 50%;
	object-fit: cover;
	overflow: hidden;
}

.rkb-eh--studio .rkb-eh__media > img:not(.rkb-model-flag),
.rkb-eh--studio .rkb-eh__media > .rkb-eh__noimg,
.rkb-eh--channel .rkb-eh__media > img:not(.rkb-model-flag),
.rkb-eh--channel .rkb-eh__media > .rkb-eh__noimg {
	width: 260px;
	aspect-ratio: 16 / 9;
	height: auto;
	border-radius: 12px;
	object-fit: cover;
	overflow: hidden;
}

.rkb-eh__noimg {
	display: flex !important;
	align-items: center;
	justify-content: center;
}

.rkb-eh__noimg img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
	object-position: center bottom;
}

.rkb-eh__letter {
	color: var(--eh-muted);
	font-size: 56px;
	font-weight: 700;
	text-transform: uppercase;
}

/* флаг страны — овалом внизу кружка, как в карточках моделей */
.rkb-eh__media > img.rkb-model-flag {
	position: absolute;
	left: 50%;
	bottom: 4px;
	width: 34px;
	height: 22px;
	border-radius: 50%;
	object-fit: cover;
	box-shadow: 0 0 0 2px var(--th-bg-1), 0 1px 4px rgba(0, 0, 0, .25);
	transform: translateX(-50%);
}

/* ---------- текст ---------- */
.rkb-eh__body {
	display: flex;
	flex-direction: column;
	gap: 10px;
	min-width: 0;
}

.rkb-eh__kicker {
	color: var(--eh-muted);
	font-size: 13px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .04em;
}

.rkb-eh__title {
	margin: -4px 0 0;
	font-size: 30px;
	font-weight: 700;
	line-height: 1.2;
	overflow-wrap: anywhere;
}

.rkb-eh__alt {
	margin-left: 10px;
	color: var(--eh-muted);
	font-size: 17px;
	font-weight: 500;
}

.rkb-eh__stats {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px 18px;
	color: var(--eh-muted);
	font-size: 14px;
}

.rkb-eh__stat {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.rkb-eh__stat i {
	margin: 0;
	font-size: 16px;
	line-height: 1;
}

.rkb-eh__facts {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 2px 0 0;
	padding: 0;
	list-style: none;
}

.rkb-eh__facts li {
	display: flex;
	flex-direction: column;
	gap: 1px;
	padding: 7px 14px;
	border-radius: 10px;
	background: var(--eh-surface);
	font-size: 14px;
	font-weight: 600;
	line-height: 1.3;
}

.rkb-eh__facts li span {
	color: var(--eh-muted);
	font-size: 11px;
	font-weight: 500;
	text-transform: uppercase;
	letter-spacing: .03em;
}

.rkb-eh__facts li.rkb-eh__fact--wide {
	max-width: 100%;
	font-weight: 500;
}

.rkb-eh__desc {
	max-width: 860px;
	color: var(--th-text-26, var(--eh-muted));
	font-size: 15px;
	line-height: 1.55;
}

.rkb-eh__desc.rkb-clamped {
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.rkb-eh__more {
	align-self: flex-start;
	margin: -6px 0 0;
	padding: 0;
	border: 0;
	background: none;
	color: var(--eh-text);
	font: inherit;
	font-size: 14px;
	font-weight: 700;
	cursor: pointer;
}

/* ---------- подписка и лайки ---------- */
.rkb-eh__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 14px;
	margin: 4px 0 0;
}

.rkb-eh a.rkb-eh__btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	height: 40px;
	padding: 0 18px;
	border-radius: 20px;
	background: var(--eh-surface);
	color: var(--eh-text);
	font-size: 14px;
	font-weight: 600;
	white-space: nowrap;
	transition: background-color .2s, color .2s;
}

.rkb-eh a.rkb-eh__btn svg {
	width: 18px;
	height: 18px;
	fill: currentColor;
}

.no-touch .rkb-eh a.rkb-eh__btn:hover {
	background: var(--eh-subtle);
	color: var(--eh-text);
	box-shadow: inset 0 0 0 1px var(--eh-line);
}

.rkb-eh a.rkb-eh__btn--primary {
	background: var(--eh-accent);
	color: #fff;
}

.no-touch .rkb-eh a.rkb-eh__btn--primary:hover {
	background: var(--eh-accent-hover);
	color: #fff;
	box-shadow: none;
}

/* сразу после подписки main.js ставит .done — показываем «Вы подписаны» */
.rkb-eh a.rkb-eh__btn.done {
	background: var(--eh-surface);
	color: var(--eh-text);
	pointer-events: none;
}

.rkb-eh a.rkb-eh__btn.done span {
	display: none;
}

.rkb-eh a.rkb-eh__btn.done:after {
	content: "Вы подписаны";
}

.rkb-eh .rkb-eh__rate {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 12px;
	margin: 0;
	padding: 0;
	background: none;
}

.rkb-eh a.rkb-eh__vote {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	height: 40px;
	margin: 0;
	padding: 0 16px;
	border-radius: 20px;
	background: var(--eh-surface);
	color: var(--eh-text);
	font-size: 14px;
	font-weight: 600;
	text-transform: none;
	transition: color .2s;
}

.rkb-eh a.rkb-eh__vote:before,
.rkb-eh a.rkb-eh__vote:after {
	content: none;
	display: none;
}

.rkb-eh a.rkb-eh__vote svg {
	width: 20px;
	height: 20px;
	fill: currentColor;
}

.no-touch .rkb-eh a.rkb-eh__vote--like:hover,
.rkb-eh a.rkb-eh__vote--like.voted {
	background: var(--eh-surface);
	color: var(--rkb-rate-green, #15803d);
}

.no-touch .rkb-eh a.rkb-eh__vote--dislike:hover,
.rkb-eh a.rkb-eh__vote--dislike.voted {
	background: var(--eh-surface);
	color: var(--rkb-rate-red, #d42a2a);
}

.rkb-eh a.rkb-eh__vote.disabled:not(.voted) {
	opacity: .5;
}

.rkb-eh__bar {
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 160px;
}

.rkb-eh .rkb-eh__bar .voters {
	position: static;
	color: var(--eh-muted);
	font-size: 13px;
	font-weight: 400;
	line-height: 1.2;
	text-transform: none;
}

.rkb-eh .rkb-eh__bar .scale-holder {
	position: relative;
	display: block;
	width: 100%;
	height: 4px;
	border-radius: 2px;
	background: var(--eh-line);
	overflow: hidden;
}

.rkb-eh .rkb-eh__bar .scale {
	display: block;
	height: 100%;
	border-radius: 2px;
	background: var(--rkb-rate-green, #15803d);
}

/* ---------- телефон ---------- */
@media (max-width: 767px) {
	.rkb-eh {
		grid-template-columns: minmax(0, 1fr);
		justify-items: center;
		gap: 14px;
		margin: 16px 0 6px;
		text-align: center;
	}

	.rkb-eh--model .rkb-eh__media > img:not(.rkb-model-flag),
	.rkb-eh--model .rkb-eh__media > .rkb-eh__noimg {
		width: 128px;
		height: 128px;
	}

	.rkb-eh--studio .rkb-eh__media > img:not(.rkb-model-flag),
	.rkb-eh--studio .rkb-eh__media > .rkb-eh__noimg,
	.rkb-eh--channel .rkb-eh__media > img:not(.rkb-model-flag),
	.rkb-eh--channel .rkb-eh__media > .rkb-eh__noimg {
		width: 220px;
	}

	.rkb-eh__body {
		align-items: center;
		width: 100%;
	}

	.rkb-eh__title {
		font-size: 24px;
	}

	.rkb-eh__alt {
		display: block;
		margin: 2px 0 0;
		font-size: 15px;
	}

	.rkb-eh__stats,
	.rkb-eh__facts,
	.rkb-eh__actions,
	.rkb-eh .rkb-eh__rate {
		justify-content: center;
	}

	.rkb-eh__desc {
		text-align: left;
	}

	.rkb-eh__more {
		align-self: center;
	}
}

/* CUSTOM rukoeb.love (17.11): страницы 2+ модели — компактная шапка (обёртка .rkb-eh-paged в videos_list.tpl):
   без описания и плашек параметров, под шапкой — «Страница N из M» */
.rkb-eh-paged .rkb-eh__facts,.rkb-eh-paged .rkb-eh__desc{display:none}
.rkb-eh-paged__page{margin:-6px 0 18px;color:var(--th-text-21);font-size:14px;line-height:1.4}

/* rukoeb: аватар модели прямоугольный 370x410 (решение 29.11) */
.rkb-eh--model .rkb-eh__media > img:not(.rkb-model-flag),
.rkb-eh--model .rkb-eh__media > .rkb-eh__noimg {
	width: 152px;
	height: auto;
	aspect-ratio: 370 / 410;
	border-radius: 8px;
	object-position: 50% 20%;
}
