/**
 * LGPD Cookie Consent Banner Stylings
 * Cores principais: Branco (#ffffff) e Verde (#00a849)
 */

/* Z-index global elevado para sobrepor cabeçalhos e outros plugins */
#lgpd-banner, #lgpd-modal {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
	box-sizing: border-box;
}

#lgpd-banner *, #lgpd-modal * {
	box-sizing: border-box;
}

.lgpd-hidden {
	opacity: 0 !important;
	pointer-events: none !important;
}

/* --- BANNER --- */
.lgpd-banner-container {
	position: fixed;
	bottom: 24px;
	left: 24px;
	right: 24px;
	width: auto;
	max-width: 1100px;
	margin: 0 auto;
	background: #ffffff;
	border: 1px solid rgba(0, 0, 0, 0.06);
	border-radius: 12px;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.02);
	z-index: 999999;
	transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
	transform: translateY(0);
}

.lgpd-banner-container.lgpd-hidden {
	transform: translateY(100px) scale(0.98);
}

.lgpd-banner-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 20px 24px;
	gap: 24px;
}

.lgpd-banner-content {
	flex: 1;
}

.lgpd-banner-content p {
	margin: 0;
	font-size: 14px;
	line-height: 1.6;
	color: #2d3748;
}

.lgpd-privacy-link {
	color: #00a849;
	text-decoration: underline;
	font-weight: 600;
	transition: color 0.2s ease;
}

.lgpd-privacy-link:hover {
	color: #007533;
}

.lgpd-banner-actions {
	display: flex;
	align-items: center;
	gap: 12px;
	flex-shrink: 0;
}

/* --- BOTÕES --- */
.lgpd-btn {
	font-size: 14px;
	font-weight: 600;
	padding: 10px 22px;
	border-radius: 6px;
	cursor: pointer;
	border: 1px solid transparent;
	transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: 42px;
	outline: none;
	text-decoration: none;
}

.lgpd-btn-primary {
	background-color: #00a849;
	color: #ffffff;
	box-shadow: 0 4px 12px rgba(0, 168, 73, 0.18);
}

.lgpd-btn-primary:hover {
	background-color: #008f3e;
	box-shadow: 0 6px 16px rgba(0, 168, 73, 0.28);
	transform: translateY(-1px);
}

.lgpd-btn-primary:active {
	transform: translateY(0);
}

.lgpd-btn-outline {
	background-color: transparent;
	color: #4a5568;
	border-color: #cbd5e0;
}

.lgpd-btn-outline:hover {
	background-color: #f7fafc;
	color: #1a202c;
	border-color: #a0aec0;
}

.lgpd-btn-text {
	background-color: transparent;
	color: #00a849;
	padding-left: 12px;
	padding-right: 12px;
}

.lgpd-btn-text:hover {
	color: #008f3e;
	background-color: rgba(0, 168, 73, 0.05);
}

/* --- MODAL --- */
.lgpd-modal-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background-color: rgba(0, 0, 0, 0.45);
	backdrop-filter: blur(4px);
	-webkit-backdrop-filter: blur(4px);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 1000000;
	opacity: 1;
	transition: opacity 0.3s ease;
}

.lgpd-modal-overlay.lgpd-hidden {
	opacity: 0;
}

.lgpd-modal-container {
	background: #ffffff;
	border-radius: 16px;
	width: 90%;
	max-width: 580px;
	box-shadow: 0 20px 40px rgba(0, 0, 0, 0.16);
	display: flex;
	flex-direction: column;
	max-height: 85vh;
	transform: scale(1) translateY(0);
	transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.lgpd-modal-overlay.lgpd-hidden .lgpd-modal-container {
	transform: scale(0.95) translateY(20px);
}

.lgpd-modal-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 20px 24px;
	border-bottom: 1px solid #edf2f7;
}

.lgpd-modal-header h2 {
	margin: 0;
	font-size: 20px;
	font-weight: 700;
	color: #1a202c;
}

.lgpd-modal-close-btn {
	background: transparent;
	border: none;
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
	color: #a0aec0;
	transition: color 0.2s ease;
	padding: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border-radius: 50%;
}

.lgpd-modal-close-btn:hover {
	color: #4a5568;
	background-color: #f7fafc;
}

.lgpd-modal-body {
	padding: 24px;
	overflow-y: auto;
}

.lgpd-modal-intro {
	font-size: 14px;
	line-height: 1.6;
	color: #4a5568;
	margin-top: 0;
	margin-bottom: 20px;
}

.lgpd-preference-options {
	display: flex;
	flex-direction: column;
}

.lgpd-pref-item {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	padding: 16px 0;
	border-bottom: 1px solid #edf2f7;
	gap: 20px;
}

.lgpd-pref-item:last-child {
	border-bottom: none;
}

.lgpd-pref-info {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.lgpd-pref-title {
	font-weight: 600;
	font-size: 15px;
	color: #1a202c;
}

.lgpd-pref-desc {
	font-size: 12px;
	color: #718096;
	line-height: 1.5;
}

.lgpd-modal-footer {
	padding: 16px 24px;
	border-top: 1px solid #edf2f7;
	display: flex;
	justify-content: flex-end;
	background: #f7fafc;
	border-bottom-left-radius: 16px;
	border-bottom-right-radius: 16px;
}

/* --- SWITCH / TOGGLE SLIDER --- */
.lgpd-switch {
	position: relative;
	display: inline-block;
	width: 44px;
	height: 24px;
	flex-shrink: 0;
}

.lgpd-switch input {
	opacity: 0;
	width: 0;
	height: 0;
}

.lgpd-slider {
	position: absolute;
	cursor: pointer;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background-color: #cbd5e0;
	transition: .3s cubic-bezier(0.4, 0, 0.2, 1);
}

.lgpd-slider:before {
	position: absolute;
	content: "";
	height: 18px;
	width: 18px;
	left: 3px;
	bottom: 3px;
	background-color: white;
	transition: .3s cubic-bezier(0.4, 0, 0.2, 1);
	box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

.lgpd-switch input:checked + .lgpd-slider {
	background-color: #00a849;
}

.lgpd-switch input:focus + .lgpd-slider {
	box-shadow: 0 0 1px #00a849;
}

.lgpd-switch input:checked + .lgpd-slider:before {
	transform: translateX(20px);
}

/* Slider desativado / bloqueado */
.lgpd-switch-disabled .lgpd-slider {
	background-color: #edf2f7;
	cursor: not-allowed;
}

.lgpd-switch-disabled input:checked + .lgpd-slider {
	background-color: #a0aec0;
}

.lgpd-slider.lgpd-round {
	border-radius: 24px;
}

.lgpd-slider.lgpd-round:before {
	border-radius: 50%;
}

/* --- RESPONSIVIDADE --- */
@media (max-width: 860px) {
	.lgpd-banner-inner {
		flex-direction: column;
		align-items: stretch;
		text-align: left;
		padding: 20px;
		gap: 16px;
	}
	
	.lgpd-banner-actions {
		justify-content: flex-end;
		width: 100%;
		gap: 10px;
	}

	.lgpd-btn {
		flex: 1;
		font-size: 13px;
		padding: 8px 14px;
	}

	.lgpd-btn-text {
		flex: 0 0 auto;
	}
}

@media (max-width: 480px) {
	.lgpd-banner-container {
		bottom: 12px;
		left: 12px;
		right: 12px;
		border-radius: 8px;
	}

	.lgpd-banner-actions {
		flex-direction: column-reverse;
		align-items: stretch;
	}

	.lgpd-btn {
		width: 100%;
	}

	.lgpd-modal-container {
		max-height: 90vh;
		width: 95%;
	}

	.lgpd-modal-header {
		padding: 16px;
	}

	.lgpd-modal-body {
		padding: 16px;
	}

	.lgpd-pref-item {
		align-items: center;
	}
}
