/* Cookie-баннер neftopt.ru (работа №180). Префикс .nocb — конфликтов с темой нет. */

.nocb,
.nocb * { box-sizing: border-box; }

.nocb[hidden] { display: none !important; }

.nocb {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 99990;
	font-family: inherit;
	pointer-events: none;
}

.nocb__backdrop {
	position: fixed;
	inset: 0;
	background: rgba(20, 20, 25, .45);
	pointer-events: auto;
	z-index: 1;
}

.nocb__backdrop[hidden] { display: none; }

.nocb__box {
	position: relative;
	z-index: 2;
	pointer-events: auto;
	width: calc(100% - 32px);
	max-width: 1180px;
	margin: 0 auto 16px;
	padding: 20px 24px;
	background: #fff;
	color: #2b2b33;
	border: 1px solid #f0e3d8;
	border-radius: 16px;
	box-shadow: 0 12px 40px rgba(20, 20, 25, .18);
	transform: translateY(24px);
	opacity: 0;
	transition: transform .35s ease, opacity .35s ease;
	max-height: calc(100vh - 32px);
	overflow-y: auto;
}

.nocb.is-visible .nocb__box {
	transform: translateY(0);
	opacity: 1;
}

.nocb__main {
	display: flex;
	align-items: center;
	gap: 18px;
}

.nocb.is-prefs-open .nocb__main { display: none; }

.nocb__icon {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	border-radius: 50%;
	color: #fff;
	background: linear-gradient(135deg, #f7941e 0%, #ef5c2b 100%);
}

.nocb__content { flex: 1 1 auto; min-width: 0; }

.nocb__title {
	margin: 0 0 4px;
	font-size: 18px;
	line-height: 1.25;
	font-weight: 700;
	color: #2b2b33;
}

.nocb__text {
	margin: 0;
	font-size: 14px;
	line-height: 1.5;
	color: #55555f;
}

.nocb__link {
	color: #ef5c2b;
	text-decoration: underline;
}

.nocb__link:hover { color: #d94a1b; }

.nocb__actions {
	flex: 0 0 auto;
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 8px;
	min-width: 210px;
}

.nocb__btn {
	display: inline-block;
	width: 100%;
	padding: 11px 18px;
	font-family: inherit;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.2;
	text-align: center;
	border-radius: 10px;
	border: 1px solid transparent;
	cursor: pointer;
	transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.nocb__btn:focus-visible {
	outline: 2px solid #ef5c2b;
	outline-offset: 2px;
}

.nocb__btn--primary {
	color: #fff;
	background: linear-gradient(135deg, #f7941e 0%, #ef5c2b 100%);
}

.nocb__btn--primary:hover { filter: brightness(.95); }

.nocb__btn--ghost {
	color: #2b2b33;
	background: #fff;
	border-color: #d8d8e0;
}

.nocb__btn--ghost:hover { background: #f5f5f7; }

.nocb__btn--link {
	color: #6a6a76;
	background: transparent;
	font-weight: 600;
	text-decoration: underline;
	padding: 6px 10px;
}

.nocb__btn--link:hover { color: #ef5c2b; }

/* --- настройки по категориям --- */

.nocb__prefs[hidden] { display: none; }

.nocb__prefs-title {
	margin: 0 0 14px;
	font-size: 17px;
	font-weight: 700;
	color: #2b2b33;
}

.nocb__row {
	display: flex;
	align-items: flex-start;
	gap: 14px;
	padding: 12px 0;
	border-top: 1px solid #eeeef2;
	cursor: pointer;
	margin: 0;
}

.nocb__row:first-of-type { border-top: 0; }

.nocb__row-body { flex: 1 1 auto; }

.nocb__row-title {
	display: block;
	font-size: 15px;
	font-weight: 700;
	color: #2b2b33;
}

.nocb__row-desc {
	display: block;
	margin-top: 2px;
	font-size: 13px;
	line-height: 1.45;
	color: #6a6a76;
}

.nocb__check {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

.nocb__switch {
	flex: 0 0 auto;
	position: relative;
	display: block;
	width: 46px;
	height: 26px;
	margin-top: 2px;
	border-radius: 13px;
	background: #d3d3dc;
	transition: background-color .2s ease;
}

.nocb__knob {
	position: absolute;
	top: 3px;
	left: 3px;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
	transition: transform .2s ease;
}

.nocb__check:checked ~ .nocb__switch {
	background: linear-gradient(135deg, #f7941e 0%, #ef5c2b 100%);
}

.nocb__check:checked ~ .nocb__switch .nocb__knob { transform: translateX(20px); }

.nocb__check:disabled ~ .nocb__switch { opacity: .55; }

.nocb__check:focus-visible ~ .nocb__switch {
	outline: 2px solid #ef5c2b;
	outline-offset: 2px;
}

.nocb__row:has(.nocb__check:disabled) { cursor: default; }

.nocb__prefs-actions {
	display: flex;
	gap: 10px;
	margin-top: 16px;
	padding-top: 14px;
	border-top: 1px solid #eeeef2;
}

.nocb__prefs-actions .nocb__btn { width: auto; min-width: 160px; }

/* --- планшет --- */

@media (max-width: 991px) {
	.nocb__main {
		flex-wrap: wrap;
		gap: 14px;
	}

	.nocb__actions {
		width: 100%;
		flex-direction: row;
		flex-wrap: wrap;
	}

	.nocb__actions .nocb__btn { width: auto; flex: 1 1 180px; }
	.nocb__actions .nocb__btn--link { flex: 0 0 auto; }
}

/* --- мобильные --- */

@media (max-width: 575px) {
	.nocb__box {
		width: calc(100% - 16px);
		margin-bottom: 8px;
		padding: 16px;
		border-radius: 14px;
	}

	.nocb__icon { display: none; }

	.nocb__title { font-size: 16px; }
	.nocb__text { font-size: 13px; }

	.nocb__actions { flex-direction: column; gap: 8px; }
	.nocb__actions .nocb__btn { width: 100%; flex: 0 0 auto; }

	.nocb__prefs-actions { flex-direction: column; }
	.nocb__prefs-actions .nocb__btn { width: 100%; min-width: 0; }

	.nocb__row-desc { font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {
	.nocb__box,
	.nocb__knob { transition: none; }
}
