/**
 * Aalam Cars Carousel — frontend CSS.
 *
 * This file provides the layout/structure baseline.
 * All cosmetic properties (colors, fonts, sizes, padding, radius, shadows)
 * are driven by Elementor controls and applied via inline rules — so this
 * file should NEVER set those properties unless explicitly stated.
 */

/* =============================================================
 * RESET / SCOPE
 * ========================================================== */
.acc-cars-carousel,
.acc-cars-carousel * {
	box-sizing: border-box;
}

.acc-cars-carousel {
	position: relative;
	width: 100%;
	max-width: 100%;
}

/* =============================================================
 * SWIPER CONTAINER
 * ========================================================== */
.acc-cars-carousel .acc-swiper {
	width: 100%;
	max-width: 100%;
	overflow: hidden;
}

.acc-cars-carousel .swiper-wrapper {
	display: flex;
	align-items: stretch;
	box-sizing: content-box;
}

.acc-cars-carousel .swiper-slide {
	height: auto;
	display: flex;
	flex-direction: column;
}

/* =============================================================
 * CARD
 * ========================================================== */
.acc-card {
	position: relative;
	display: flex;
	flex-direction: column;
	width: 100%;
	height: 100%;
	margin: 0;
	background: #ffffff;
	border: 1px solid #E7ECF3;
	border-radius: 18px;
	overflow: hidden;
}

/* =============================================================
 * MEDIA / IMAGE
 * ========================================================== */
.acc-card-media {
	position: relative;
	width: 100%;
	height: 230px;
	overflow: hidden;
	flex-shrink: 0;
}

.acc-card-media img {
	display: block;
	width: 100%;
	height: 230px;
	object-fit: cover;
	object-position: center 45%;
	margin: 0;
	padding: 0;
}

/* =============================================================
 * PILLS
 * ========================================================== */
.acc-card-pills {
	position: absolute;
	top: 10px;
	left: 10px;
	right: 10px;
	z-index: 5;
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	pointer-events: none;
}

.acc-pill {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 22px;
	padding: 5px 10px;
	border-radius: 999px;
	font-size: 9px;
	font-weight: 800;
	line-height: 1;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	white-space: nowrap;
}

.acc-pill-available {
	color: #ffffff;
	background: linear-gradient(180deg, #18B96B 0%, #109958 100%);
}

.acc-pill-dot {
	display: inline-block;
	width: 5px;
	height: 5px;
	margin-right: 6px;
	border-radius: 50%;
	background: currentColor;
	opacity: 0.95;
	flex-shrink: 0;
}

.acc-pill-country {
	color: #0B2545;
	background: rgba(255, 255, 255, 0.94);
	border: 1px solid rgba(226, 232, 240, 0.95);
	min-width: 42px;
}

/* =============================================================
 * CONTENT
 * ========================================================== */
.acc-card-content {
	display: flex;
	flex-direction: column;
	padding: 16px;
	flex-grow: 1;
}

.acc-card-brand {
	color: #94A3B8;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	line-height: 1;
	margin: 0 0 4px 0;
}

.acc-card-title {
	color: #0B2545;
	font-size: 20px;
	font-weight: 700;
	line-height: 1.2;
	margin: 0 0 10px 0;
}

/* =============================================================
 * SPECS ROW
 * ========================================================== */
.acc-card-specs {
	display: flex;
	flex-direction: row;
	flex-wrap: nowrap;
	align-items: center;
	column-gap: 14px;
	margin: 0 0 12px 0;
	padding: 0;
	list-style: none;
}

.acc-spec {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	color: #5b6b80;
	font-size: 13px;
	font-weight: 500;
	line-height: 1.2;
	white-space: nowrap;
}

.acc-spec svg {
	display: block;
	width: 14px;
	height: 14px;
	flex-shrink: 0;
	color: #0B2545;
	stroke: currentColor;
	align-self: center;
}

/* =============================================================
 * FEATURES LIST
 * ========================================================== */
.acc-card-features {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	column-gap: 18px;
	row-gap: 6px;
	margin: 0 0 12px 0;
	padding: 0;
	list-style: none;
}

.acc-card-features li {
	margin: 0;
	padding: 0;
	list-style: none;
}

.acc-feature {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: #0B2545;
	font-size: 13px;
	font-weight: 500;
	line-height: 1.2;
	white-space: nowrap;
}

.acc-feature > span {
	display: inline-flex;
	align-items: center;
	line-height: 1.2;
}

.acc-feature svg {
	display: block;
	width: 14px;
	height: 14px;
	flex-shrink: 0;
	color: #1E5BB8;
	stroke: currentColor;
	align-self: center;
	position: relative;
	top: 0;
}

/* =============================================================
 * PRICE
 * ========================================================== */
.acc-card-price {
	color: #0B2545;
	font-size: 24px;
	font-weight: 700;
	line-height: 1.15;
	margin: auto 0 12px 0; /* push to bottom of flex column */
}

/* =============================================================
 * BUTTON (CTA)
 * ========================================================== */
.acc-card-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	padding: 12px 16px;
	background: #ffffff;
	color: #0B2545;
	border: 1.5px solid #0B2545;
	border-radius: 12px;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	text-decoration: none;
	white-space: nowrap;
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
	margin-top: auto;
	box-sizing: border-box;
}

.acc-card-btn:hover {
	background: #0B2545;
	color: #ffffff;
}

/* =============================================================
 * ARROWS — positioned safely inside the visible area
 * ========================================================== */
.acc-arrow {
	position: absolute;
	top: 115px; /* roughly mid-image on default 230px */
	z-index: 10;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border: none;
	border-radius: 50%;
	background: #ffffff;
	color: #0B2545;
	box-shadow: 0 4px 14px rgba(11, 37, 69, 0.12);
	cursor: pointer;
	transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.acc-arrow:hover {
	transform: translateY(-1px);
	box-shadow: 0 6px 18px rgba(11, 37, 69, 0.18);
}

.acc-arrow:disabled,
.acc-arrow.swiper-button-disabled {
	opacity: 0.35;
	cursor: not-allowed;
	pointer-events: none;
}

/* Default: inside the card area (won't crop) */
.acc-arrow-prev {
	left: 12px;
}

.acc-arrow-next {
	right: 12px;
}

/* =============================================================
 * PAGINATION (DOTS)
 * ========================================================== */
.acc-cars-carousel .swiper-pagination {
	position: relative;
	margin-top: 18px;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
}

.acc-cars-carousel .swiper-pagination-bullet {
	width: 8px;
	height: 8px;
	background: #CBD5E1;
	opacity: 1;
	border-radius: 50%;
	transition: width 0.2s ease, background-color 0.2s ease;
}

.acc-cars-carousel .swiper-pagination-bullet-active {
	width: 24px;
	border-radius: 4px;
	background: #0B2545;
}

/* =============================================================
 * EDITOR EMPTY STATE
 * ========================================================== */
.acc-empty {
	padding: 30px;
	text-align: center;
	color: #64748B;
	background: #F8FAFC;
	border: 2px dashed #CBD5E1;
	border-radius: 8px;
}

/* =============================================================
 * MOBILE — Native horizontal scroll
 * Below 768px: destroy Swiper (via JS) and use scroll-snap.
 * The .acc-mobile-native class is added by JS on init.
 * ========================================================== */
@media (max-width: 767px) {

	.acc-cars-carousel {
		padding-left: 14px;
	}

	.acc-cars-carousel.acc-mobile-native .acc-swiper {
		overflow-x: auto;
		overflow-y: visible;
		padding-right: 50px;
		scroll-snap-type: x mandatory;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: none;
		touch-action: pan-x;
	}

	.acc-cars-carousel.acc-mobile-native .acc-swiper::-webkit-scrollbar {
		display: none;
		width: 0;
		height: 0;
	}

	.acc-cars-carousel.acc-mobile-native .swiper-wrapper {
		display: flex;
		flex-direction: row;
		flex-wrap: nowrap;
		gap: 12px;
		width: max-content;
		transform: none !important;
		transition: none !important;
	}

	.acc-cars-carousel.acc-mobile-native .swiper-slide {
		width: var(--acc-mobile-peek, 78vw);
		max-width: 320px;
		min-width: var(--acc-mobile-peek, 78vw);
		flex: 0 0 var(--acc-mobile-peek, 78vw);
		scroll-snap-align: start;
		scroll-snap-stop: always;
	}

	/* Smaller card defaults on mobile (overridable via Elementor controls) */
	.acc-card-media,
	.acc-card-media img {
		height: 150px;
	}

	.acc-card-content {
		padding: 12px 14px;
	}

	.acc-card-brand {
		font-size: 9.5px;
	}

	.acc-card-title {
		font-size: 16px;
		margin-bottom: 8px;
	}

	.acc-card-specs {
		column-gap: 10px;
		margin-bottom: 8px;
	}

	.acc-spec {
		font-size: 11px;
	}

	.acc-spec svg {
		width: 12px;
		height: 12px;
	}

	.acc-card-features {
		display: none; /* hidden on mobile by default; show via Elementor control */
	}

	.acc-card-price {
		font-size: 19px;
		margin-bottom: 8px;
	}

	.acc-card-btn {
		padding: 9px 12px;
		font-size: 11.5px;
	}

	/* Hide arrows + dots on mobile (we use native scroll) */
	.acc-cars-carousel.acc-mobile-native .acc-arrow,
	.acc-cars-carousel.acc-mobile-native .swiper-pagination {
		display: none;
	}
}
