/* ==========================================================================
   App Banner Pro — Frontend Banner Styles
   ========================================================================== */

/* Base — aísla el banner de los estilos del tema */
.abp-banner,
.abp-banner *,
.abp-banner *::before,
.abp-banner *::after {
	box-sizing: border-box;
}

.abp-banner {
	font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, sans-serif;
	background: var(--abp-bg, #1a1a2e);
	color: var(--abp-color, #ffffff);
	z-index: var(--abp-zindex, 9999);
	-webkit-font-smoothing: antialiased;
}

/* Close button — resets agresivos para neutralizar estilos de temas */
.abp-close {
	position: absolute !important;
	top: 10px !important;
	background: none !important;
	background-color: transparent !important;
	background-image: none !important;
	border: none !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	outline: none !important;
	-webkit-appearance: none !important;
	appearance: none !important;
	color: var(--abp-color, #fff) !important;
	cursor: pointer !important;
	font-size: 15px !important;
	font-weight: normal !important;
	line-height: 1 !important;
	padding: 5px 8px !important;
	margin: 0 !important;
	min-width: 0 !important;
	min-height: 0 !important;
	height: auto !important;
	width: auto !important;
	text-shadow: none !important;
	letter-spacing: normal !important;
	text-transform: none !important;
	opacity: .65;
	transition: opacity .18s;
	z-index: 1 !important;
}

.abp-close:hover {
	opacity: 1;
	background: none !important;
	background-color: transparent !important;
	box-shadow: none !important;
	border: none !important;
	color: var(--abp-color, #fff) !important;
}

.abp-close--right { right: 10px; }
.abp-close--left  { left: 10px; }

/* Content row */
.abp-content {
	display: flex;
	align-items: center;
	gap: 12px;
	min-width: 0;
}

.abp-icon {
	width: 52px;
	height: 52px;
	border-radius: 12px;
	object-fit: cover;
	flex-shrink: 0;
}

.abp-text {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

.abp-title {
	font-size: 14px;
	font-weight: 700;
	color: var(--abp-color, #fff);
	line-height: 1.25;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.abp-subtitle {
	font-size: 12px;
	color: var(--abp-color, #fff);
	opacity: .75;
	line-height: 1.35;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Buttons */
.abp-buttons {
	display: flex;
	gap: 8px;
	flex-shrink: 0;
	flex-wrap: wrap;
	align-items: center;
}

.abp-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 8px 14px;
	background: var(--abp-btn-bg, #e94560);
	color: var(--abp-btn-color, #fff) !important;
	border-radius: var(--abp-radius, 12px);
	text-decoration: none !important;
	font-size: 12px;
	font-weight: 600;
	white-space: nowrap;
	line-height: 1;
	transition: filter .18s, transform .15s;
}

.abp-btn:hover {
	filter: brightness(1.1);
	transform: translateY(-1px);
}

.abp-store-icon {
	flex-shrink: 0;
}

/* ==========================================================================
   Format: Bottom Bar
   ========================================================================== */
.abp-format-bottom-bar {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	display: flex;
	align-items: center;
	padding: 10px 48px 10px 14px;
	gap: 14px;
	box-shadow: var(--abp-shadow, 0 -2px 16px rgba(0,0,0,0.2));
}

.abp-format-bottom-bar .abp-close--right { right: 12px; top: 50%; transform: translateY(-50%); }
.abp-format-bottom-bar .abp-close--left  { left: 12px;  top: 50%; transform: translateY(-50%); padding-right: 0; }

.abp-format-bottom-bar .abp-content { flex: 1; min-width: 0; }

.abp-format-bottom-bar.abp-enter {
	animation: abp-up-in .4s cubic-bezier(.22,.61,.36,1) both;
}
.abp-format-bottom-bar.abp-exit {
	animation: abp-up-out .28s ease-in both;
}

@keyframes abp-up-in  { from { transform: translateY(100%); } to { transform: translateY(0); } }
@keyframes abp-up-out { from { transform: translateY(0); }    to { transform: translateY(105%); } }

/* ==========================================================================
   Format: Floating Card
   ========================================================================== */
.abp-format-floating-card {
	position: fixed;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: min(90vw, 420px);
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 16px;
	padding: 28px 24px 22px;
	border-radius: var(--abp-radius, 16px);
	box-shadow: var(--abp-shadow, 0 8px 40px rgba(0,0,0,0.28));
	text-align: center;
	overflow: hidden;
}

.abp-format-floating-card .abp-content { flex-direction: column; }
.abp-format-floating-card .abp-icon    { width: 80px; height: 80px; border-radius: 20px; }
.abp-format-floating-card .abp-title   { font-size: 18px; white-space: normal; }
.abp-format-floating-card .abp-subtitle { white-space: normal; }
.abp-format-floating-card .abp-buttons { justify-content: center; width: 100%; }
.abp-format-floating-card .abp-btn     { flex: 1; }

/* El overlay es un elemento hermano del card, fuera del transform */
.abp-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0,0,0,.48);
	z-index: calc(var(--abp-zindex, 9999) - 1);
}

.abp-format-floating-card.abp-enter {
	animation: abp-scale-in .35s cubic-bezier(.22,.61,.36,1) both;
}
.abp-format-floating-card.abp-exit {
	animation: abp-scale-out .24s ease-in both;
}

@keyframes abp-scale-in  { from { opacity:0; transform:translate(-50%,-50%) scale(.82); } to { opacity:1; transform:translate(-50%,-50%) scale(1); } }
@keyframes abp-scale-out { from { opacity:1; transform:translate(-50%,-50%) scale(1); }  to { opacity:0; transform:translate(-50%,-50%) scale(.86); } }
@keyframes abp-fade-in   { from { opacity:0; } to { opacity:1; } }
@keyframes abp-fade-out  { from { opacity:1; } to { opacity:0; } }

/* ==========================================================================
   Format: Smart Banner
   ========================================================================== */
.abp-format-smart-banner {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	height: 76px;
	display: flex;
	align-items: center;
	padding: 0 50px 0 10px;
	gap: 10px;
	box-shadow: 0 1px 5px rgba(0,0,0,.15);
	border-radius: 0 !important;
}

.abp-format-smart-banner .abp-content { flex: 1; min-width: 0; }
.abp-format-smart-banner .abp-icon    { width: 42px; height: 42px; border-radius: 9px; }
.abp-format-smart-banner .abp-title   { font-size: 13px; }
.abp-format-smart-banner .abp-subtitle { font-size: 11px; }
.abp-format-smart-banner .abp-buttons { margin-left: auto; }
.abp-format-smart-banner .abp-btn     { padding: 6px 13px; font-size: 12px; }
.abp-format-smart-banner .abp-close--right { right: 10px; top: 50%; transform: translateY(-50%); }
.abp-format-smart-banner .abp-close--left  { left: 10px;  top: 50%; transform: translateY(-50%); }

body.abp-smart-banner-active {
	padding-top: 76px !important;
}

.abp-format-smart-banner.abp-enter {
	animation: abp-down-in .4s cubic-bezier(.22,.61,.36,1) both;
}
.abp-format-smart-banner.abp-exit {
	animation: abp-down-out .28s ease-in both;
}

@keyframes abp-down-in  { from { transform: translateY(-100%); } to { transform: translateY(0); } }
@keyframes abp-down-out { from { transform: translateY(0); }     to { transform: translateY(-105%); } }

/* ==========================================================================
   Format: Slide-in
   ========================================================================== */
.abp-format-slide-in {
	position: fixed;
	bottom: 24px;
	right: 24px;
	width: min(90vw, 320px);
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 20px 16px 16px;
	border-radius: var(--abp-radius, 16px);
	box-shadow: var(--abp-shadow, 0 8px 32px rgba(0,0,0,0.22));
}

.abp-format-slide-in .abp-buttons { flex-direction: column; }
.abp-format-slide-in .abp-btn     { width: 100%; }

.abp-format-slide-in.abp-enter {
	animation: abp-right-in .4s cubic-bezier(.22,.61,.36,1) both;
}
.abp-format-slide-in.abp-exit {
	animation: abp-right-out .28s ease-in both;
}

@keyframes abp-right-in  { from { transform:translateX(120%); opacity:0; } to { transform:translateX(0); opacity:1; } }
@keyframes abp-right-out { from { transform:translateX(0); opacity:1; }    to { transform:translateX(120%); opacity:0; } }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 600px) {
	.abp-format-bottom-bar {
		flex-wrap: wrap;
		padding: 12px 44px 12px 12px;
		gap: 10px;
	}
	.abp-format-bottom-bar .abp-buttons {
		width: 100%;
	}
	.abp-format-bottom-bar .abp-btn {
		flex: 1;
	}
	.abp-format-floating-card {
		padding: 22px 16px 18px;
	}
	.abp-format-slide-in {
		bottom: 12px;
		right: 12px;
		left: 12px;
		width: auto;
		max-width: none;
	}
}

/* Respect reduced motion preference */
@media (prefers-reduced-motion: reduce) {
	.abp-banner.abp-enter,
	.abp-banner.abp-exit {
		animation: none !important;
	}
}
