/* РОСТИНПРОМ · стили баннера, настроек cookie и превью видео */

#rp-banner {
	position: fixed;
	left: 20px;
	bottom: 20px;
	z-index: 999990;
	width: min(480px, calc(100vw - 40px));
	background: #ffffff;
	color: #1f2a33;
	border-radius: 14px;
	box-shadow: 0 12px 40px rgba(15, 35, 50, .18), 0 2px 8px rgba(15, 35, 50, .08);
	padding: 18px 20px 16px;
	font: 400 14px/1.45 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
	box-sizing: border-box;
}

#rp-banner .rp-banner__text strong {
	display: block;
	font-size: 16px;
	font-weight: 700;
	margin-bottom: 6px;
	color: #10222e;
}

#rp-banner .rp-banner__text p {
	margin: 0;
	color: #40525f;
}

#rp-banner a,
#rp-settings a {
	color: #1a6b46;
	text-decoration: underline;
}

#rp-banner .rp-banner__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 14px;
}

.rp-btn {
	-webkit-appearance: none;
	appearance: none;
	border: 1px solid transparent;
	border-radius: 10px;
	cursor: pointer;
	font: inherit;
	font-size: 13px;
	line-height: 1;
	padding: 11px 16px;
	transition: background .15s, border-color .15s, color .15s;
}

.rp-btn--primary {
	background: #1a6b46;
	color: #ffffff;
	font-weight: 600;
}

.rp-btn--primary:hover { background: #14563a; }

.rp-btn--secondary {
	background: #ffffff;
	color: #1f2a33;
	border-color: #cfd8dd;
	font-weight: 600;
}

.rp-btn--secondary:hover { border-color: #9fb0ba; }

.rp-btn--link {
	background: transparent;
	color: #1a6b46;
	padding: 11px 6px;
	text-decoration: underline;
}

.rp-settings-btn {
	position: fixed;
	left: 20px;
	bottom: 16px;
	z-index: 999980;
	background: rgba(255, 255, 255, .94);
	color: #3c4c57;
	border: 1px solid #d3dde2;
	border-radius: 999px;
	padding: 7px 12px;
	font: 400 12px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
	cursor: pointer;
	box-shadow: 0 2px 10px rgba(15, 35, 50, .10);
	opacity: .92;
}

.rp-settings-btn:hover { opacity: 1; }

#rp-settings {
	position: fixed;
	inset: 0;
	z-index: 1000000;
	background: rgba(10, 22, 30, .55);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	box-sizing: border-box;
}

.rp-settings__box {
	width: min(560px, 100%);
	max-height: 86vh;
	overflow: auto;
	background: #ffffff;
	color: #1f2a33;
	border-radius: 16px;
	padding: 24px;
	box-shadow: 0 24px 60px rgba(0, 0, 0, .28);
	font: 400 14px/1.45 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

.rp-settings__box h2 {
	margin: 0 0 16px;
	font-size: 20px;
	color: #10222e;
}

.rp-settings__row {
	display: flex;
	gap: 16px;
	align-items: flex-start;
	justify-content: space-between;
	padding: 14px 0;
	border-top: 1px solid #e6edf1;
}

.rp-settings__row p {
	margin: 4px 0 0;
	color: #5a6b76;
	font-size: 13px;
}

.rp-settings__row--locked { opacity: .75; }

.rp-settings__actions {
	display: flex;
	gap: 10px;
	margin-top: 18px;
}

.rp-switch {
	position: relative;
	display: inline-block;
	width: 46px;
	height: 26px;
	flex: 0 0 auto;
	margin-top: 2px;
}

.rp-switch input {
	position: absolute;
	opacity: 0;
	width: 100%;
	height: 100%;
	margin: 0;
	cursor: pointer;
}

.rp-switch span,
.rp-switch::after {
	content: "";
}

.rp-switch span,
.rp-switch.rp-switch--on {
	display: block;
	width: 46px;
	height: 26px;
	border-radius: 999px;
	background: #cfd8dd;
	transition: background .2s;
}

.rp-switch span::after,
.rp-switch.rp-switch--on::after {
	content: "";
	position: absolute;
	top: 3px;
	left: 3px;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: #ffffff;
	transition: transform .2s;
	box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
}

.rp-switch input:checked + span { background: #1a6b46; }
.rp-switch input:checked + span::after { transform: translateX(20px); }
.rp-switch.rp-switch--on { background: #1a6b46; }
.rp-switch.rp-switch--on::after { transform: translateX(20px); }

/* чекбокс согласия в формах */

.rp-consent-row {
	margin: 10px 0 4px;
}

.rp-check {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	cursor: pointer;
	font-size: 13px;
	line-height: 1.4;
	color: inherit;
}

.rp-check input[type="checkbox"] {
	-webkit-appearance: none;
	appearance: none;
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin: 1px 0 0;
	border: 1.5px solid #9fb0ba;
	border-radius: 4px;
	background: #fff;
	cursor: pointer;
	position: relative;
}

.rp-check input[type="checkbox"]:checked {
	background: #1a6b46;
	border-color: #1a6b46;
}

.rp-check input[type="checkbox"]:checked::after {
	content: "";
	position: absolute;
	left: 5px;
	top: 1px;
	width: 5px;
	height: 10px;
	border: solid #fff;
	border-width: 0 2px 2px 0;
	transform: rotate(45deg);
}

.rp-consent-error {
	margin-top: 6px;
	color: #b3261e;
	font-size: 12.5px;
}

.rp-consent-row--error .rp-check input[type="checkbox"] {
	border-color: #b3261e;
	box-shadow: 0 0 0 3px rgba(179, 38, 30, .12);
}

/* ссылки в подвале: каждая с новой строки */

.rp-footer-links {
	line-height: 1.7;
}

.rp-footer-links .rp-footer-item {
	display: block;
	margin: 0 0 4px;
}

.rp-footer-links .rp-footer-item:last-child {
	margin-bottom: 0;
}

.rp-footer-links a {
	display: inline;
	text-decoration: underline;
	text-underline-offset: 2px;
}

.rp-footer-links a:hover {
	text-decoration: none;
}

/* превью видео вместо YouTube */

.rp-video {
	position: relative;
	width: 100%;
	max-width: 640px;
	aspect-ratio: 16 / 9;
	background: #0f1c24;
	border-radius: 10px;
	overflow: hidden;
}

.rp-video iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

.rp-video-play {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 10px;
	width: 100%;
	height: 100%;
	border: 0;
	background: radial-gradient(circle at 50% 45%, #1d3542 0%, #0f1c24 70%);
	color: #eaf1f4;
	cursor: pointer;
	font: inherit;
}

.rp-video-play svg { filter: drop-shadow(0 3px 10px rgba(0, 0, 0, .45)); }
.rp-video-play:hover svg { transform: scale(1.06); }
.rp-video-play svg { transition: transform .15s; }
.rp-video-note { font-size: 12px; opacity: .75; }

@media (max-width: 600px) {
	#rp-banner {
		left: 12px;
		right: 12px;
		bottom: 12px;
		width: auto;
		padding: 16px;
	}
	.rp-banner__actions { gap: 6px; }
	.rp-btn { flex: 1 1 auto; text-align: center; }
	.rp-settings-btn { left: 12px; bottom: 10px; font-size: 11px; padding: 6px 10px; }
}
