/* Humand - Consent UI. Vive en mu-plugin: no se pisa con updates de Complianz. */

/* 1) Muro (overlay oscuro fullscreen) SOLO en opt-in. En opt-out el aviso es pequeño y no bloquea (ver sección 9). */
.cmplz-optout .cmplz-soft-cookiewall { position: initial !important; background: none !important; }
/* Excepción: páginas de documentos legales/políticas se pueden leer sin decidir (nativo de Complianz) */
.cmplz-document .cmplz-soft-cookiewall,
.humand-policy-page .cmplz-soft-cookiewall { position: initial !important; }
.cmplz-soft-cookiewall { background-color: rgba(0, 0, 0, .72); }
.cmplz-soft-cookiewall.cmplz-dismissed { display: none !important; }

/* 2) Sin scroll de fondo mientras el banner está activo (solo opt-in; en opt-out se puede seguir navegando) */
body.cmplz-optin.cmplz-banner-active { overflow: hidden; }

/* 3) Sin botón de cierre (X): hay que decidir (también se desactiva con close_button=0) */
.cmplz-cookiebanner .cmplz-close { display: none !important; }

/* 4) Sin botón flotante de cookies (también con manage_consent_options=hide-everywhere) */
#cmplz-manage-consent .cmplz-manage-consent { display: none !important; }

/* 5) Link de footer */
.humand-cookie-settings { cursor: pointer; text-decoration: underline; }
.humand-cookie-settings-fallback { text-align: center; padding: 12px 16px; font-size: 13px; }

/* 6) Opt-out con el MISMO formato que opt-in: Complianz oculta "Personalizar" en opt-out (optout.css).
      Sin !important a propósito: el JS de Complianz alterna display inline al abrir/cerrar preferencias. */
.cmplz-cookiebanner.optout .cmplz-buttons .cmplz-btn.cmplz-view-preferences { display: block; }
/* Layout de botones igual en ambos tipos (Permitir todo | Personalizar, o Permitir selección | Permitir todo) */
.cmplz-cookiebanner.optout .cmplz-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.cmplz-cookiebanner.optout .cmplz-buttons .cmplz-btn { flex: 1 1 0; }

/* 7) Categoría "Necesarias": tildada y deshabilitada (la deshabilita el JS) */
.cmplz-cookiebanner input.cmplz-functional:disabled + label { opacity: .55; cursor: not-allowed; }

/* 8) Tipografía de marca */
.cmplz-cookiebanner, .cmplz-cookiebanner button, .cmplz-cookiebanner a { font-family: "SF UI", system-ui, -apple-system, "Segoe UI", sans-serif; }

/* 9) OPT-OUT: aviso compacto abajo a la izquierda, sin overlay ni scroll lock, con menos información (título oculto, mensaje corto).
      Se cierra solo a los 10 s sin interacción (ver humand-consent.js). Mantiene los botones Permitir todo / Personalizar. */
.cmplz-cookiebanner.optout { box-shadow: 0 8px 30px rgba(0, 0, 0, .18); transition: opacity .4s ease, transform .4s ease; }
.cmplz-cookiebanner.optout.humand-fade { opacity: 0; transform: translateY(8px) !important; pointer-events: none; }
.cmplz-cookiebanner.optout .cmplz-header { display: none; }
.cmplz-cookiebanner.optout .cmplz-message { font-size: 13px; line-height: 1.45; }
.cmplz-cookiebanner.optout .cmplz-documents { margin-top: 2px; }
@media (min-width: 768px) {
	.cmplz-cookiebanner.optout { top: auto !important; right: auto !important; bottom: 16px !important; left: 16px !important; transform: none !important;
		min-width: 0 !important; width: 360px !important; max-width: calc(100vw - 32px) !important; }
	.cmplz-cookiebanner.optout .cmplz-message, .cmplz-cookiebanner.optout .cmplz-categories { width: auto !important; }
}
@media (max-width: 767px) {
	.cmplz-cookiebanner.optout { top: auto !important; bottom: 0 !important; left: 0 !important; right: 0 !important; transform: none !important;
		width: 100% !important; border-radius: 16px 16px 0 0 !important; }
	.cmplz-cookiebanner.optout .cmplz-buttons { flex-direction: row !important; }
}
