/* =========================================================================
   IME Motors: Electric Vehicles page ([ime_ev_showcase], inc/ime-ev.php).
   Same red, type and card style as the rest of the site.
   ====================================================================== */

.ime-ev {
	--ev-red: var(--color-primary, #ec2329);
	--ev-red-dark: #b01920;
	--ev-ink: #111827;
	--ev-text: #4b5563;
	--ev-soft: #f5eee9;
	--ev-line: #e5e7eb;
	--ev-card: #fff;
	--ev-radius: 20px;
	color: var(--ev-ink);
	overflow-x: clip;
}
.ime-ev *, .ime-ev *::before, .ime-ev *::after { box-sizing: border-box; }
.ime-ev ul { list-style: none; margin: 0; padding: 0; }
.ime-ev p { margin: 0; }
.ime-ev img { display: block; max-width: 100%; height: auto; }

.ime-ev-wrap { width: 100%; max-width: 1320px; margin: 0 auto; padding: 0 15px; }
.ime-ev-center { text-align: center; }
.ime-ev-red { color: var(--ev-red); }

.ime-ev-section { padding: 88px 0; scroll-margin-top: calc(var(--ime-header-h, 96px) + 70px); }
.ime-ev-section--soft { background: var(--ev-soft); }

.ime-ev-eyebrow {
	display: inline-block;
	margin-bottom: 18px !important;
	padding: 7px 16px;
	border-radius: 999px;
	background: rgba(236, 35, 41, .08);
	color: var(--ev-red);
	font-size: 14px;
	font-weight: 600;
	letter-spacing: .02em;
}
.ime-ev-h2 {
	margin: 0 0 18px;
	font-family: "PolySans", var(--e-global-typography-primary-font-family, sans-serif);
	font-size: clamp(28px, 3.2vw, 44px);
	font-weight: 700;
	line-height: 1.1;
	letter-spacing: -0.5px;
	color: var(--ev-ink);
}
.ime-ev-h3 {
	margin: 64px 0 24px;
	font-family: "PolySans", var(--e-global-typography-primary-font-family, sans-serif);
	font-size: clamp(22px, 2.2vw, 30px);
	font-weight: 700;
	letter-spacing: -0.3px;
}
.ime-ev-lead { max-width: 760px; margin: 0 auto 48px !important; font-size: 18px; line-height: 1.6; color: var(--ev-text); }

/* ---- Buttons ---- */
.ime-ev-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.ime-ev-btn {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 14px 28px;
	border-radius: 999px;
	font-size: 16px;
	font-weight: 600;
	text-decoration: none !important;
	transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.ime-ev-btn .ime-ev-icon { width: 18px; height: 18px; transition: transform .15s ease; }
.ime-ev-btn:hover .ime-ev-icon { transform: translateX(3px); }
.ime-ev-btn--primary { background: var(--ev-red); color: #fff !important; }
.ime-ev-btn--primary:hover { background: var(--ev-red-dark); }
.ime-ev-btn--ghost { border: 1.5px solid var(--ev-line); color: var(--ev-ink) !important; }
.ime-ev-btn--ghost:hover { border-color: var(--ev-ink); }
.ime-ev-btn--white { background: #fff; color: var(--ev-red) !important; }
.ime-ev-btn--white:hover { background: #fff5f5; }
.ime-ev-btn--outline { border: 1.5px solid rgba(255, 255, 255, .7); color: #fff !important; }
.ime-ev-btn--outline:hover { background: rgba(255, 255, 255, .12); }
.ime-ev a:focus-visible { outline: 2px solid var(--ev-red); outline-offset: 3px; }

/* ---- Hero ---- */
.ime-ev-hero { padding: calc(var(--ime-header-h, 96px) + 40px) 0 0; text-align: center; }
.ime-ev-hero__title {
	max-width: 900px;
	margin: 0 auto 20px;
	font-family: "PolySans", var(--e-global-typography-primary-font-family, sans-serif);
	font-size: clamp(36px, 5vw, 68px);
	font-weight: 700;
	line-height: 1.04;
	letter-spacing: -1.2px;
}
.ime-ev-hero__text { max-width: 820px; margin: 0 auto 32px !important; font-size: 18px; line-height: 1.65; color: var(--ev-text); }
.ime-ev-hero .ime-ev-actions { justify-content: center; margin-bottom: 48px; }
.ime-ev-hero__media { overflow: hidden; border-radius: var(--ev-radius); background: #0b1220; }
.ime-ev-hero__media img { width: 100%; }

/* ---- Sub navigation ---- */
.ime-ev-subnav {
	position: sticky;
	top: var(--ime-header-h, 96px);
	z-index: 20;
	margin-top: 48px;
	background: rgba(255, 255, 255, .94);
	backdrop-filter: blur(8px);
	border-top: 1px solid var(--ev-line);
	border-bottom: 1px solid var(--ev-line);
}
.ime-ev-subnav .ime-ev-wrap { display: flex; gap: 6px; overflow-x: auto; padding-top: 10px; padding-bottom: 10px; scrollbar-width: none; }
.ime-ev-subnav a {
	flex: none;
	padding: 9px 18px;
	border-radius: 999px;
	color: var(--ev-ink) !important;
	font-size: 15px;
	font-weight: 600;
	text-decoration: none !important;
}
.ime-ev-subnav a:hover { background: var(--ev-soft); color: var(--ev-red) !important; }
.ime-ev-subnav a.is-cta { margin-left: auto; background: var(--ev-red); color: #fff !important; }
.ime-ev-subnav a.is-cta:hover { background: var(--ev-red-dark); }

/* ---- About ---- */
.ime-ev-about { display: grid; grid-template-columns: 1.1fr 1fr; gap: 64px; align-items: center; }
.ime-ev-about__text > p { font-size: 18px; line-height: 1.65; color: var(--ev-text); margin-bottom: 28px !important; }
.ime-ev-about__media img { width: 100%; border-radius: var(--ev-radius); }
.ime-ev-pills { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 36px !important; }
.ime-ev-pills li {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 9px 16px;
	border: 1px solid var(--ev-line);
	border-radius: 999px;
	font-size: 15px;
	font-weight: 600;
}
.ime-ev-pills .ime-ev-icon { width: 16px; height: 16px; color: var(--ev-red); }
.ime-ev-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 0; }
.ime-ev-stats div { padding: 20px; border-radius: 16px; background: var(--ev-soft); }
.ime-ev-stats dt { font-family: "PolySans", sans-serif; font-size: clamp(22px, 2.4vw, 32px); font-weight: 700; color: var(--ev-red); }
.ime-ev-stats dd { margin: 4px 0 0; font-size: 14px; color: var(--ev-text); }

/* ---- Features ---- */
.ime-ev-features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 40px !important; }
.ime-ev-features li { padding: 32px; border-radius: var(--ev-radius); background: var(--ev-card); }
.ime-ev-features__icon,
.ime-ev-keys__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	margin-bottom: 20px;
	border-radius: 14px;
	background: var(--ev-red);
	color: #fff;
}
.ime-ev-features h3 { margin: 0 0 8px; font-size: 20px; font-weight: 700; }
.ime-ev-features p { font-size: 15px; line-height: 1.6; color: var(--ev-text); }

/* ---- Variant cards ---- */
.ime-ev-variants { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.ime-ev-variant {
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 36px 32px 32px;
	border: 1px solid var(--ev-line);
	border-radius: var(--ev-radius);
	background: linear-gradient(180deg, #f4f8fc 0%, #fff 60%);
	color: var(--ev-ink) !important;
	text-align: center;
	text-decoration: none !important;
	transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.ime-ev-variant:hover { border-color: transparent; box-shadow: 0 18px 40px rgba(17, 24, 39, .1); transform: translateY(-4px); }
.ime-ev-variant__img img { width: auto; max-height: 300px; margin: 0 auto; }
.ime-ev-variant__name { margin-top: 18px; font-family: "PolySans", sans-serif; font-size: 28px; font-weight: 700; }
.ime-ev-variant__specs { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 20px; margin: 12px 0 20px; font-size: 15px; color: var(--ev-text); }
.ime-ev-variant__specs strong { color: var(--ev-ink); }
.ime-ev-variant__more { display: inline-flex; align-items: center; gap: 8px; color: var(--ev-red); font-weight: 700; }
.ime-ev-variant__more .ime-ev-icon { width: 18px; height: 18px; }

/* ---- Model detail ---- */
.ime-ev-model { padding: 88px 0; border-top: 1px solid var(--ev-line); scroll-margin-top: calc(var(--ime-header-h, 96px) + 70px); }
.ime-ev-model__banner { overflow: hidden; margin-bottom: 48px; border-radius: var(--ev-radius); }
.ime-ev-model__banner img { width: 100%; }
.ime-ev-model__intro { max-width: 980px; }
.ime-ev-model__intro p { font-size: 18px; line-height: 1.65; color: var(--ev-text); }

.ime-ev-keys { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; margin-top: 40px !important; }
.ime-ev-keys li { display: flex; flex-direction: column; padding: 24px 20px; border-radius: 16px; background: var(--ev-soft); }
.ime-ev-keys__icon { width: 44px; height: 44px; margin-bottom: 16px; border-radius: 12px; }
.ime-ev-keys strong { font-family: "PolySans", sans-serif; font-size: 22px; line-height: 1.2; }
.ime-ev-keys span:last-child { margin-top: 4px; font-size: 14px; color: var(--ev-text); }

.ime-ev-advantage { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.ime-ev-advantage__media img { width: 100%; border-radius: var(--ev-radius); background: #eef2f6; }
.ime-ev-advantage details { border-bottom: 1px solid var(--ev-line); }
.ime-ev-advantage summary {
	position: relative;
	padding: 18px 40px 18px 0;
	font-size: 19px;
	font-weight: 700;
	cursor: pointer;
	list-style: none;
}
.ime-ev-advantage summary::-webkit-details-marker { display: none; }
.ime-ev-advantage summary::after {
	content: "+";
	position: absolute;
	right: 4px;
	top: 50%;
	transform: translateY(-50%);
	font-size: 26px;
	font-weight: 400;
	color: var(--ev-red);
}
.ime-ev-advantage details[open] summary { color: var(--ev-red); }
.ime-ev-advantage details[open] summary::after { content: "−"; }
.ime-ev-advantage details p { padding: 0 0 20px; font-size: 16px; line-height: 1.65; color: var(--ev-text); }

.ime-ev-apps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.ime-ev-apps li { overflow: hidden; border-radius: 16px; background: #eceff3; }
.ime-ev-apps img { width: 100%; aspect-ratio: 700 / 555; object-fit: cover; }
.ime-ev-apps span { display: block; padding: 12px 14px; background: #fff; border: 1px solid var(--ev-line); border-top: 0; border-radius: 0 0 16px 16px; font-size: 15px; font-weight: 600; }
.ime-ev-tags { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px !important; }
.ime-ev-tags li { padding: 8px 16px; border-radius: 999px; background: var(--ev-soft); font-size: 14px; font-weight: 600; }
.ime-ev-notes { margin-top: 28px; font-size: 13px; line-height: 1.6; color: #6b7280; }
.ime-ev-notes p + p { margin-top: 2px; }

/* ---- Comparison ---- */
.ime-ev-table { overflow-x: auto; margin-top: 40px; border-radius: 16px; background: #fff; border: 1px solid var(--ev-line); }
.ime-ev-table table { width: 100%; min-width: 620px; border-collapse: collapse; font-size: 15px; }
.ime-ev-table th, .ime-ev-table td { padding: 15px 20px; border-bottom: 1px solid var(--ev-line); text-align: left; }
.ime-ev-table thead th { background: var(--ev-red); color: #fff; font-weight: 700; }
.ime-ev-table tbody th { width: 30%; font-weight: 600; background: #fbf7f4; }
.ime-ev-table td[colspan] { text-align: center; }
.ime-ev-table tbody tr:last-child > * { border-bottom: 0; }

/* ---- Enquiry CTA ---- */
.ime-ev-cta {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 32px;
	padding: 56px;
	border-radius: var(--ev-radius);
	background: linear-gradient(120deg, var(--ev-red) 0%, #c81d22 100%);
	color: #fff;
}
.ime-ev-cta .ime-ev-h2 { color: #fff; }
.ime-ev-cta p { max-width: 620px; font-size: 18px; line-height: 1.6; color: rgba(255, 255, 255, .9); }
.ime-ev-cta .ime-ev-actions { flex: none; }

/* ---- Responsive ---- */
@media (max-width: 1199px) {
	.ime-ev-keys { grid-template-columns: repeat(3, 1fr); }
	.ime-ev-apps { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 991px) {
	.ime-ev-section, .ime-ev-model { padding: 64px 0; }
	.ime-ev-about, .ime-ev-advantage { grid-template-columns: 1fr; gap: 36px; }
	.ime-ev-features { grid-template-columns: repeat(2, 1fr); }
	.ime-ev-cta { flex-direction: column; align-items: flex-start; padding: 40px 32px; }
}
@media (max-width: 767px) {
	.ime-ev-hero { padding-top: calc(var(--ime-header-h, 64px) + 28px); }
	.ime-ev-hero__text, .ime-ev-lead, .ime-ev-about__text > p, .ime-ev-model__intro p { font-size: 16px; }
	.ime-ev-features, .ime-ev-variants { grid-template-columns: 1fr; }
	.ime-ev-keys, .ime-ev-apps { grid-template-columns: repeat(2, 1fr); }
	.ime-ev-stats { grid-template-columns: 1fr; }
	.ime-ev-features li { padding: 24px; }
	.ime-ev-subnav a.is-cta { margin-left: 0; }
	.ime-ev-model__banner { margin-bottom: 32px; border-radius: 14px; }
	.ime-ev-model__banner img { aspect-ratio: 16 / 9; object-fit: cover; object-position: 70% center; }
}
@media (prefers-reduced-motion: reduce) {
	.ime-ev-variant, .ime-ev-btn .ime-ev-icon { transition: none; }
	.ime-ev-variant:hover { transform: none; }
}

/* ---- Dark mode ---- */
html.uc-dark .ime-ev {
	--ev-ink: #f3f4f6;
	--ev-text: #c4c8cf;
	--ev-soft: rgba(255, 255, 255, .05);
	--ev-line: rgba(255, 255, 255, .1);
	--ev-card: rgba(255, 255, 255, .04);
}
html.uc-dark .ime-ev-subnav { background: rgba(17, 24, 39, .94); }
html.uc-dark .ime-ev-variant { background: rgba(255, 255, 255, .03); }
html.uc-dark .ime-ev-table, html.uc-dark .ime-ev-apps span { background: transparent; }
html.uc-dark .ime-ev-table tbody th { background: rgba(255, 255, 255, .04); }
