/**
 * Public styles for AE888 Banner.
 */

.ae888-banner {
	position: fixed;
	bottom: max(16px, env(safe-area-inset-bottom));
	left: 50%;
	z-index: 999999;
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	width: 100%;
	max-width: var(--ae888-banner-max-width, 1100px);
	padding: 0 10px;
	box-sizing: border-box;
	background: transparent;
	transform: translateX(-50%);
}

.ae888-banner[hidden] {
	display: none !important;
}

.ae888-banner__item {
	width: calc(50% - 5px);
}

.ae888-banner--single .ae888-banner__item {
	width: 100%;
}

.ae888-banner__item img {
	display: block;
	max-width: 100%;
	height: auto;
	border-radius: 8px;
	box-shadow: 0 3px 10px rgba(0, 0, 0, 0.12);
}

.ae888-banner__close {
	position: absolute;
	top: -28px;
	right: 8px;
	width: 22px;
	height: 22px;
	padding: 0;
	border: 1px solid rgba(255, 255, 255, 0.6);
	border-radius: 6px;
	background: rgba(0, 0, 0, 0.6);
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
	color: #fff;
	font-size: 14px;
	line-height: 20px;
	text-align: center;
	cursor: pointer;
	backdrop-filter: saturate(120%) blur(2px);
	transition: transform 0.15s ease, filter 0.15s ease, background 0.15s ease;
}

.ae888-banner__close:hover,
.ae888-banner__close:focus-visible {
	filter: brightness(1.15);
	transform: scale(1.05);
}

.ae888-banner__close:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 2px;
}

@media (max-width: 549px) {
	.ae888-banner {
		gap: 8px;
		padding: 0 8px;
	}

	.ae888-banner__item {
		width: 100%;
	}

	.ae888-banner__close {
		top: -30px;
		right: 10px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ae888-banner__close {
		transition: none;
	}
}
