/**
 * CookieYes preference modal only.
 * Does not change consent logic, banner, or plugin core.
 */

/* Jolie has-mouse-dot hides the native cursor on every node.
   The custom #mouseDot sits at z-index 10000, under .cky-modal (999999999). */
body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-modal,
body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-modal *,
body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-overlay {
	cursor: default !important;
}

body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-modal a,
body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-modal button,
body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-modal label,
body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-modal input[type="checkbox"],
body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-modal .cky-accordion-header-wrapper,
body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-modal .cky-accordion-chevron,
body:not(.wp-admin):not(.elementor-editor-active).has-mouse-dot .cky-modal .cky-switch {
	cursor: pointer !important;
}

html:has(.cky-modal.cky-modal-open),
body:has(.cky-modal.cky-modal-open) {
	overflow: hidden !important;
	overscroll-behavior: none;
}

.cky-modal,
.cky-preference-center {
	box-sizing: border-box;
	overflow: hidden;
}

.cky-preference-body-wrapper {
	overflow-x: hidden;
	-webkit-overflow-scrolling: touch;
}

@media (max-width: 845px) {
	.cky-modal.cky-modal-open {
		width: calc(100% - 24px);
		max-width: calc(100% - 24px);
		max-height: calc(100dvh - 24px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
	}

	.cky-preference-center {
		width: 100%;
		max-width: 100%;
		max-height: calc(100dvh - 24px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
	}
}

@media (max-width: 576px) {
	.cky-modal.cky-modal-open {
		width: calc(100% - 24px);
		max-width: calc(100% - 24px);
	}

	.cky-preference-center {
		max-height: calc(100dvh - 24px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
	}

	.cky-preference-header .cky-preference-title {
		font-size: 16px;
		line-height: 1.3;
	}

	.cky-preference-content-wrapper,
	.cky-preference-content-wrapper *,
	.cky-accordion-header-des,
	.cky-accordion-header-des * {
		font-size: 14px;
		line-height: 1.45;
	}

	.cky-modal .cky-preference-header .cky-btn-close {
		width: 44px !important;
		height: 44px !important;
		flex: 0 0 44px;
		display: inline-flex;
		align-items: center;
		justify-content: center;
	}

	.cky-preference-header .cky-btn-close img {
		width: 10px;
		height: 10px;
	}

	.cky-accordion-header-wrapper,
	.cky-accordion-btn {
		min-height: 44px;
	}

	.cky-accordion-chevron {
		min-width: 20px;
		padding-top: 12px;
		padding-bottom: 12px;
		box-sizing: content-box;
	}

	.cky-switch {
		min-width: 44px;
		min-height: 44px;
		align-items: center;
		justify-content: flex-end;
	}

	.cky-prefrence-btn-wrapper .cky-btn {
		min-height: 44px;
		box-sizing: border-box;
	}

	.cky-footer-wrapper {
		padding-bottom: env(safe-area-inset-bottom, 0px);
	}

	.cky-btn-revisit-wrapper.cky-revisit-bottom-left {
		bottom: calc(12px + env(safe-area-inset-bottom, 0px));
		left: calc(12px + env(safe-area-inset-left, 0px));
	}
}
