/**
 * Cookie consent banner. Accept and refuse share the same size.
 */

.yny-consent,
.yny-consent * {
	box-sizing: border-box;
}

.yny-consent {
	--yny-red: #c62828;
	--yny-ink: #0d1117;
	--yny-muted: #334155;
	--yny-line: #e2e8f0;
	--yny-surface: #f4f6f8;
	font-family: Inter, system-ui, -apple-system, sans-serif;
}

.yny-consent__banner,
.yny-consent__panel {
	background: #fff;
	border: 1px solid var(--yny-line);
	border-radius: 8px;
	border-top: 3px solid #ee3124;
	bottom: 1rem;
	box-shadow: 0 8px 24px rgb(13 17 23 / 14%);
	box-sizing: border-box;
	color: var(--yny-ink);
	left: 1rem;
	max-height: min(70vh, 28rem);
	overflow: auto;
	padding: 0.75rem 0.875rem;
	position: fixed;
	width: min(20rem, calc(100vw - 2rem));
	z-index: 40;
}

.yny-consent__panel {
	width: min(22rem, calc(100vw - 2rem));
	z-index: 42;
}

.yny-consent__overlay {
	background: transparent;
	inset: 0;
	position: fixed;
	z-index: 41;
}

.yny-consent__top {
	align-items: center;
	display: flex;
	gap: 1rem;
	justify-content: space-between;
}

.yny-consent__kicker {
	color: var(--yny-red);
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.04em;
	margin: 0;
	text-transform: uppercase;
}

.yny-consent__langs {
	display: flex;
	flex-shrink: 0;
	gap: 0.25rem;
}

.yny-consent__lang {
	background: transparent;
	border: 1px solid var(--yny-line);
	border-radius: 4px;
	color: var(--yny-ink);
	cursor: pointer;
	font: inherit;
	font-size: 0.75rem;
	font-weight: 700;
	min-height: 2rem;
	min-width: 2.25rem;
	padding: 0.25rem 0.5rem;
}

.yny-consent__lang[aria-pressed="true"] {
	background: var(--yny-ink);
	border-color: var(--yny-ink);
	color: #fff;
}

.yny-consent__title {
	font-size: 1rem;
	letter-spacing: -0.02em;
	line-height: 1.3;
	margin: 0.5rem 0 0.35rem;
}

.yny-consent__intro,
.yny-consent__policy,
.yny-consent__row-text {
	color: var(--yny-muted);
	font-size: 0.8125rem;
	line-height: 1.45;
	margin: 0;
}

.yny-consent__policy {
	margin-top: 0.5rem;
}

.yny-consent__policy a {
	color: var(--yny-ink);
	font-weight: 600;
}

.yny-consent__policy a:hover {
	color: var(--yny-red);
}

.yny-consent__actions {
	display: grid;
	gap: 0.5rem;
	grid-template-columns: 1fr 1fr;
	margin-top: 0.75rem;
}

.yny-consent__actions--panel {
	grid-template-columns: 1fr;
}

.yny-consent__btn,
.yny-consent__customize {
	border-radius: 4px;
	cursor: pointer;
	font: inherit;
	font-size: 0.8125rem;
	font-weight: 700;
	min-height: 2.25rem;
	padding: 0.4rem 0.5rem;
}

.yny-consent__btn--refuse {
	background: var(--yny-ink);
	border: 2px solid var(--yny-ink);
	color: #fff;
}

.yny-consent__btn--accept,
.yny-consent__btn--save {
	background: var(--yny-red);
	border: 2px solid var(--yny-red);
	color: #fff;
}

.yny-consent__btn:hover,
.yny-consent__customize:hover {
	filter: brightness(1.08);
}

.yny-consent__customize {
	background: transparent;
	border: 0;
	color: var(--yny-ink);
	display: block;
	margin: 0.25rem auto 0;
	text-decoration: underline;
	text-underline-offset: 0.2em;
	width: 100%;
}

.yny-consent__row {
	align-items: center;
	border-top: 1px solid var(--yny-line);
	display: flex;
	gap: 1rem;
	justify-content: space-between;
	margin-top: 0.75rem;
	padding-top: 0.75rem;
}

.yny-consent__row-copy {
	display: flex;
	flex-direction: column;
	gap: 0.2rem;
	min-width: 0;
}

.yny-consent__row-title {
	font-weight: 700;
}

.yny-consent__switch-wrap {
	align-items: center;
	display: flex;
	flex-direction: column;
	flex-shrink: 0;
	gap: 0.25rem;
}

.yny-consent__always {
	color: var(--yny-muted);
	font-size: 0.6875rem;
	font-weight: 600;
	text-align: center;
}

.yny-consent__switch {
	appearance: none;
	background: #cbd5e1;
	border: 0;
	border-radius: 999px;
	cursor: pointer;
	height: 1.5rem;
	margin: 0;
	position: relative;
	width: 2.75rem;
}

.yny-consent__switch::after {
	background: #fff;
	border-radius: 50%;
	content: "";
	height: 1.25rem;
	left: 2px;
	position: absolute;
	top: 2px;
	width: 1.25rem;
}

.yny-consent__switch:checked {
	background: var(--yny-red);
}

.yny-consent__switch:checked::after {
	transform: translateX(1.25rem);
}

.yny-consent__switch:disabled {
	background: #64748b;
	cursor: not-allowed;
}

.yny-consent__switch:focus-visible,
.yny-consent__btn:focus-visible,
.yny-consent__customize:focus-visible,
.yny-consent__lang:focus-visible,
.yny-consent__reopen:focus-visible,
.yny-consent-open:focus-visible {
	outline: 3px solid #ee3124;
	outline-offset: 2px;
}

.yny-consent__reopen,
.yny-shop-footer__nav-list .yny-consent-open {
	background: none;
	border: 0;
	color: inherit;
	cursor: pointer;
	font: inherit;
	text-align: left;
}

.yny-consent__reopen {
	background: var(--yny-ink);
	border-radius: 999px;
	border-top: 2px solid #ee3124;
	bottom: 1rem;
	box-shadow: 0 8px 24px rgb(13 17 23 / 18%);
	color: #fff;
	font-size: 0.8125rem;
	font-weight: 700;
	left: 1rem;
	padding: 0.625rem 0.875rem;
	position: fixed;
	z-index: 30;
}

.yny-shop-footer__nav-list .yny-consent-open {
	color: var(--wp--preset--color--base, #fff);
	display: block;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	line-height: 1.5;
	padding: 0.125rem 0;
}

.yny-shop-footer__nav-list .yny-consent-open:hover {
	color: #ee3124;
}

.yny-consent__reopen:hover {
	background: #1e293b;
}

.yny-consent__live {
	height: 1px;
	margin: -1px;
	overflow: hidden;
	position: absolute;
	width: 1px;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
}

.yny-consent__noscript {
	background: #fff;
	border-radius: 8px;
	border-top: 3px solid #ee3124;
	bottom: 1rem;
	box-shadow: 0 8px 24px rgb(13 17 23 / 14%);
	box-sizing: border-box;
	color: #0d1117;
	font-family: Inter, system-ui, sans-serif;
	font-size: 0.8125rem;
	left: 1rem;
	line-height: 1.45;
	margin: 0;
	padding: 0.75rem 0.875rem;
	position: fixed;
	width: min(20rem, calc(100vw - 2rem));
	z-index: 40;
}

@media (prefers-reduced-motion: reduce) {
	.yny-consent__switch::after {
		transition: none;
	}
}

@media print {
	.yny-consent,
	.yny-consent__noscript {
		display: none !important;
	}
}
