/* Aviso de cookies de AIO: colores y fuentes del manual (Noche, Señal, Bruma, Niebla; Space Grotesk, DM Sans, JetBrains Mono). */
.aio-cc-banner,
.aio-cc-modal {
	--aio-cc-noche: #0A1330;
	--aio-cc-noche-deep: #060B1E;
	--aio-cc-noche-surface: #0E1A3D;
	--aio-cc-noche-elevated: #142452;
	--aio-cc-senal: #2DD4A0;
	--aio-cc-bruma: #DCE6FB;
	--aio-cc-niebla: #F4F7FD;
	--aio-cc-azul: #005BFE;
	font-family: 'DM Sans', system-ui, sans-serif;
	color: var(--aio-cc-bruma);
}

.aio-cc-banner[hidden],
.aio-cc-modal[hidden] { display: none; }

/* Barra */
.aio-cc-banner {
	position: fixed;
	left: 16px;
	right: 16px;
	bottom: 16px;
	z-index: 60;
	max-width: 960px;
	margin: 0 auto;
	background: rgba(10, 19, 48, 0.86);
	-webkit-backdrop-filter: blur(16px) saturate(140%);
	backdrop-filter: blur(16px) saturate(140%);
	border: 1px solid rgba(45, 212, 160, 0.55);
	border-radius: 16px;
	box-shadow: 0 18px 48px rgba(6, 11, 30, 0.55), 0 0 0 1px rgba(45, 212, 160, 0.08) inset;
	opacity: 0;
	transform: translateY(16px);
	transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.aio-cc-banner.is-visible { opacity: 1; transform: none; }

/* En celular y tableta el sitio tiene la barra de pestañas fija abajo (64 px): el aviso va encima. */
@media (max-width: 1023px) {
	.aio-cc-banner { bottom: calc(64px + env(safe-area-inset-bottom, 0px) + 12px); }
}

/* Dos variantes: implícita (por defecto) y estricta del RGPD (.is-ue, la pone banner.js según la zona horaria). */
.aio-cc-banner .aio-cc-ue { display: none; }
.aio-cc-banner.is-ue .aio-cc-implicito { display: none; }
.aio-cc-banner.is-ue p.aio-cc-ue { display: block; }
.aio-cc-banner.is-ue div.aio-cc-ue { display: flex; }
.aio-cc-acciones { gap: 10px; flex-shrink: 0; }
.aio-cc-acciones .aio-cc-btn { min-width: 120px; }

.aio-cc-inner {
	display: flex;
	align-items: center;
	gap: 20px;
	padding: 16px 16px 16px 22px;
}

.aio-cc-text {
	margin: 0;
	flex: 1;
	font-size: 14px;
	line-height: 1.55;
	color: var(--aio-cc-bruma);
}
.aio-cc-text em { font-style: normal; color: var(--aio-cc-niebla); font-weight: 600; }

.aio-cc-eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	margin-right: 10px;
	font-family: 'JetBrains Mono', ui-monospace, monospace;
	font-size: 11px;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--aio-cc-senal);
	vertical-align: 1px;
}
.aio-cc-dot {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: var(--aio-cc-senal);
	box-shadow: 0 0 0 0 rgba(45, 212, 160, 0.6);
	animation: aio-cc-pulso 2.4s ease-out infinite;
}
@keyframes aio-cc-pulso {
	0% { box-shadow: 0 0 0 0 rgba(45, 212, 160, 0.55); }
	70%, 100% { box-shadow: 0 0 0 8px rgba(45, 212, 160, 0); }
}

.aio-cc-link {
	color: var(--aio-cc-senal);
	text-decoration: underline;
	text-decoration-color: rgba(45, 212, 160, 0.45);
	text-underline-offset: 3px;
}
.aio-cc-link:hover { text-decoration-color: var(--aio-cc-senal); }

/* Botones: el CTA es verde en todo el sitio. */
.aio-cc-btn {
	flex-shrink: 0;
	min-height: 44px;
	padding: 0 22px;
	border-radius: 10px;
	border: 1px solid transparent;
	font-family: 'Space Grotesk', system-ui, sans-serif;
	font-size: 15px;
	font-weight: 600;
	letter-spacing: -0.01em;
	cursor: pointer;
	transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.aio-cc-btn:active { transform: scale(0.98); }
.aio-cc-btn-primary { background: var(--aio-cc-senal); color: var(--aio-cc-noche); }
.aio-cc-btn-primary:hover { background: #4BE0B2; }
.aio-cc-btn-secondary { background: transparent; color: var(--aio-cc-bruma); border-color: rgba(220, 230, 251, 0.22); }
.aio-cc-btn-secondary:hover { border-color: rgba(220, 230, 251, 0.5); color: var(--aio-cc-niebla); }

.aio-cc-banner :focus-visible,
.aio-cc-modal :focus-visible { outline: 2px solid var(--aio-cc-senal); outline-offset: 3px; }

@media (max-width: 639px) {
	.aio-cc-inner { flex-direction: column; align-items: stretch; gap: 12px; padding: 16px; }
	.aio-cc-text { font-size: 13.5px; }
	.aio-cc-eyebrow { display: flex; margin: 0 0 6px; }
	.aio-cc-btn { width: 100%; }
	.aio-cc-acciones .aio-cc-btn { flex: 1; min-width: 0; }
}

/* Ventana de preferencias */
html.aio-cc-lock { overflow: hidden; }

.aio-cc-modal {
	position: fixed;
	inset: 0;
	z-index: 80;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	opacity: 0;
	transition: opacity 0.25s ease;
}
.aio-cc-modal.is-open { opacity: 1; }

.aio-cc-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(6, 11, 30, 0.72);
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
}

.aio-cc-panel {
	position: relative;
	width: 100%;
	max-width: 560px;
	max-height: calc(100vh - 32px);
	max-height: calc(100dvh - 32px);
	overflow-y: auto;
	padding: 28px;
	background: linear-gradient(160deg, var(--aio-cc-noche-elevated) 0%, var(--aio-cc-noche-surface) 55%, var(--aio-cc-noche-deep) 100%);
	border: 1px solid rgba(0, 91, 254, 0.35);
	border-radius: 20px;
	box-shadow: 0 30px 80px rgba(6, 11, 30, 0.7);
	transform: translateY(12px) scale(0.98);
	transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.aio-cc-modal.is-open .aio-cc-panel { transform: none; }

.aio-cc-close {
	position: absolute;
	top: 14px;
	right: 14px;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	border: 0;
	background: rgba(220, 230, 251, 0.08);
	color: var(--aio-cc-bruma);
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
}
.aio-cc-close:hover { background: rgba(220, 230, 251, 0.16); color: #fff; }

.aio-cc-title {
	margin: 0 48px 8px 0;
	font-family: 'Space Grotesk', system-ui, sans-serif;
	font-size: 24px;
	line-height: 1.2;
	font-weight: 600;
	letter-spacing: -0.02em;
	color: var(--aio-cc-niebla);
}

.aio-cc-intro { margin: 0 0 20px; font-size: 14px; line-height: 1.6; color: rgba(220, 230, 251, 0.82); }
.aio-cc-intro em { font-style: normal; color: var(--aio-cc-niebla); }

.aio-cc-cat {
	padding: 16px 18px;
	margin-bottom: 10px;
	border-radius: 14px;
	background: rgba(6, 11, 30, 0.45);
	border: 1px solid rgba(220, 230, 251, 0.1);
}
.aio-cc-cat-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.aio-cc-cat-title { font-family: 'Space Grotesk', system-ui, sans-serif; font-size: 16px; font-weight: 600; color: var(--aio-cc-niebla); }
.aio-cc-cat-desc { margin: 0; font-size: 13.5px; line-height: 1.55; color: rgba(220, 230, 251, 0.75); }

.aio-cc-badge {
	font-family: 'JetBrains Mono', ui-monospace, monospace;
	font-size: 11px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--aio-cc-senal);
	padding: 4px 10px;
	border-radius: 999px;
	background: rgba(45, 212, 160, 0.12);
}

.aio-cc-toggle { position: relative; display: inline-flex; width: 46px; height: 26px; flex-shrink: 0; }
.aio-cc-toggle input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; z-index: 1; }
.aio-cc-slider {
	position: absolute;
	inset: 0;
	border-radius: 999px;
	background: rgba(220, 230, 251, 0.18);
	transition: background-color 0.2s ease;
}
.aio-cc-slider::after {
	content: '';
	position: absolute;
	top: 3px;
	left: 3px;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: var(--aio-cc-niebla);
	transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.aio-cc-toggle input:checked + .aio-cc-slider { background: var(--aio-cc-senal); }
.aio-cc-toggle input:checked + .aio-cc-slider::after { transform: translateX(20px); background: var(--aio-cc-noche); }
.aio-cc-toggle input:focus-visible + .aio-cc-slider { outline: 2px solid var(--aio-cc-senal); outline-offset: 3px; }
.aio-cc-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.aio-cc-footer { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; flex-wrap: wrap; }

@media (max-width: 479px) {
	.aio-cc-panel { padding: 22px 18px; }
	.aio-cc-footer { flex-direction: column-reverse; }
	.aio-cc-footer .aio-cc-btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
	.aio-cc-banner,
	.aio-cc-modal,
	.aio-cc-panel,
	.aio-cc-slider,
	.aio-cc-slider::after { transition: none; }
	.aio-cc-dot { animation: none; }
}
