/*
 * Site template «لوکس پرانرژی» / Energy Luxury (Figma proposal C, owner 2026-10-31; file
 * «AlaMotors — Premium Automotive Design System»).
 *
 * Isolation: linked only by the public layout when Energy is the active template; every rule is an
 * «en-» class or scoped to «.en-site». The shared chrome below (header, inner pages, footer) follows
 * the Luxury template's structure; the Energy layer at the end gives the dark navy base, gradient and
 * category accents and styles the Energy homepage. Raise TEMPLATE_ASSETS_VERSION with every change.
 */

/* ======================================================================= tokens and page */
.en-site {
  --en-accent: var(--am-color-blue);
  --en-ink: color-mix(in srgb, var(--am-color-navy) 82%, #000);
  --en-on-dark: #f3f5f9;
  --en-on-dark-muted: color-mix(in srgb, var(--am-color-muted-on-dark) 88%, transparent);
  --en-line-dark: rgb(255 255 255 / 12%);
  --en-paper: color-mix(in srgb, var(--am-color-surface) 55%, #fff);
  --en-width: min(var(--am-max-width), calc(100vw - 32px));
  min-block-size: 100vh;
  background: var(--en-paper);
}

/* One level below the wrapper, so the deeper accent can be computed from the theme's accent. */
.en-site > * {
  --am-color-blue: color-mix(in srgb, var(--en-accent) 85%, #000);
  --en-accent-strong: var(--am-color-blue);
  --en-accent-light: var(--am-color-accent-light);
  --am-radius-sm: 6px;
  --am-radius-md: 12px;
  --am-radius-lg: 18px;
  --am-shadow-sm: 0 1px 2px rgb(0 0 0 / 5%), 0 8px 22px rgb(var(--am-color-navy-rgb) / 7%);
  --am-shadow-md: 0 18px 44px rgb(var(--am-color-navy-rgb) / 16%);
}

.en-site h1,
.en-site h2 {
  letter-spacing: -0.01em;
}

.en-site .am-button {
  border-radius: 999px;
  font-weight: 700;
}

.en-site .am-section-heading__eyebrow {
  letter-spacing: 0.08em;
}

.en-site .am-section-heading__title {
  font-weight: 900;
}

/* ======================================================================= header */
.en-header {
  position: sticky;
  inset-block-start: 0;
  z-index: 50;
  background: rgb(255 255 255 / 92%);
  backdrop-filter: saturate(180%) blur(14px);
  box-shadow:
    0 1px 0 var(--am-color-border),
    0 10px 30px rgb(var(--am-color-navy-rgb) / 6%);
}

.en-strip {
  background: var(--en-ink);
  color: var(--en-on-dark-muted);
  font-size: 0.82rem;
}

.en-stripInner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-block-size: 34px;
}

.en-stripItem {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-block-size: 32px;
  color: inherit;
  text-decoration: none;
}

.en-stripItem svg,
.en-rate svg {
  inline-size: 15px;
  block-size: 15px;
}

.en-rate {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
}

.en-rate strong {
  color: #fff;
  font-weight: 700;
}

.en-rateTime,
.en-rateDateShort {
  color: rgb(255 255 255 / 62%);
}

.en-rateDateShort {
  display: none;
}

.en-bar {
  display: flex;
  align-items: center;
  gap: var(--am-space-3);
  min-block-size: 78px;
}

.en-brand {
  display: inline-flex;
  align-items: center;
  min-block-size: var(--am-touch-target);
  border-radius: var(--am-radius-sm);
}

.en-desktopNav {
  margin-inline-start: auto;
}

.en-navList {
  display: flex;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.en-navLink {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-block-size: var(--am-touch-target);
  padding-inline: 12px;
  color: var(--am-color-ink);
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
}

/* A thin accent line grows under the hovered item. */
.en-navLink::after {
  content: '';
  position: absolute;
  inset-inline: 12px;
  inset-block-end: 6px;
  block-size: 2px;
  background: var(--am-color-blue);
  transform: scaleX(0);
  transition: transform 200ms var(--am-ease);
}

.en-navLink:hover::after,
.en-navLink:focus-visible::after {
  transform: scaleX(1);
}

.en-cta {
  white-space: nowrap;
  text-decoration: none;
}

.en-hasSub {
  position: relative;
}

.en-chevron {
  inline-size: 16px;
  block-size: 16px;
  margin-inline-start: 2px;
  transition: transform 160ms var(--am-ease);
}

.en-subMenu {
  position: absolute;
  inset-block-start: 100%;
  inset-inline-start: 0;
  z-index: 60;
  min-inline-size: 200px;
  margin: 0;
  padding: 8px;
  border-radius: var(--am-radius-md);
  background: var(--en-ink);
  box-shadow: var(--am-shadow-md);
  list-style: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(4px);
  transition:
    opacity 140ms var(--am-ease),
    transform 140ms var(--am-ease),
    visibility 140ms;
}

.en-hasSub:hover .en-subMenu,
.en-hasSub:focus-within .en-subMenu {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.en-hasSub:hover .en-chevron,
.en-hasSub:focus-within .en-chevron {
  transform: rotate(180deg);
}

.en-subLink {
  display: flex;
  align-items: center;
  min-block-size: 42px;
  padding-inline: 12px;
  border-radius: var(--am-radius-sm);
  color: var(--en-on-dark);
  text-decoration: none;
}

.en-subLink:hover,
.en-subLink:focus-visible {
  background: rgb(255 255 255 / 8%);
  color: var(--en-accent-light);
}

.en-mobile {
  display: none;
  position: relative;
  margin-inline-start: auto;
}

.en-menuButton {
  display: inline-flex;
  align-items: center;
  gap: var(--am-space-1);
  min-block-size: var(--am-touch-target);
  padding-inline: 14px;
  border-radius: 999px;
  background: var(--en-ink);
  color: #fff;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.en-menuButton::-webkit-details-marker {
  display: none;
}

.en-menuButton svg {
  inline-size: 20px;
  block-size: 20px;
}

.en-mobilePanel {
  position: absolute;
  inset-inline-end: 0;
  inset-block-start: calc(100% + 10px);
  inline-size: min(86vw, 320px);
  padding: 10px;
  border-radius: var(--am-radius-md);
  background: var(--en-ink);
  box-shadow: var(--am-shadow-md);
}

.en-mobileList,
.en-mobileSub {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.en-mobileSub {
  padding-inline-start: 16px;
}

.en-mobileLink {
  display: flex;
  align-items: center;
  min-block-size: var(--am-touch-target);
  padding-inline: 12px;
  border-radius: var(--am-radius-sm);
  color: var(--en-on-dark);
  text-decoration: none;
}

.en-mobileLink:hover {
  background: rgb(255 255 255 / 8%);
}

.en-mobileCta {
  inline-size: 100%;
  margin-block-start: 8px;
  text-decoration: none;
}

@media (max-width: 1080px) {
  .en-desktopNav,
  .en-cta {
    display: none;
  }

  .en-mobile {
    display: block;
  }
}

@media (max-width: 560px) {
  .en-rateTime {
    display: none;
  }

  .en-rateDateShort {
    display: inline;
  }
}

/* ======================================================================= inner pages */
/* Every public page starts with the breadcrumb (and usually the h1): together they become a dark,
   full-width title band. The box-shadow trick widens the background without horizontal scroll. */
.en-site main:has(> .am-container > nav[aria-label='مسیر صفحه']) {
  padding-block-start: 0;
}

.en-site main > .am-container > nav[aria-label='مسیر صفحه'],
.en-site main > .am-container > nav[aria-label='مسیر صفحه'] + h1 {
  margin: 0;
  background: var(--en-ink);
  box-shadow: 0 0 0 100vmax var(--en-ink);
  clip-path: inset(0 -100vmax);
}

.en-site main > .am-container > nav[aria-label='مسیر صفحه'] {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding-block: 22px 10px;
  color: var(--en-on-dark-muted);
  font-size: 0.85rem;
}

.en-site main > .am-container > nav[aria-label='مسیر صفحه'] a {
  color: var(--en-on-dark-muted);
  text-decoration: none;
}

.en-site main > .am-container > nav[aria-label='مسیر صفحه'] a:hover {
  color: #fff;
}

.en-site main > .am-container > nav[aria-label='مسیر صفحه'] [aria-current='page'] {
  color: var(--en-accent-light);
}

.en-site main > .am-container > nav[aria-label='مسیر صفحه'] + h1 {
  padding-block: 4px 40px;
  color: #fff;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 900;
  line-height: 1.35;
}

/* Breadcrumb alone (vehicle and article pages): a thinner band with room below it. */
.en-site main > .am-container > nav[aria-label='مسیر صفحه']:not(:has(+ h1)) {
  padding-block-end: 22px;
}

/* The first block after the band keeps a clear distance from it. */
.en-site main > .am-container > nav[aria-label='مسیر صفحه'] + h1 + *,
.en-site main > .am-container > nav[aria-label='مسیر صفحه'] + :not(h1) {
  margin-block-start: 32px;
}

/* ======================================================================= inner page contents */
/*
 * The public pages are shared with Classic; their CSS-module classes keep the original name as a
 * suffix (production «<hash>_card», development «…__card»). Luxury restyles them by that suffix,
 * only inside its own wrapper. If a future build changed the naming, these rules would simply stop
 * matching and the pages keep their Classic look (never broken).
 */

/* Vehicle cards: no frame, deep shadow, photo zoom on hover. */
.en-site
  main
  :is([class$='_grid'], [class*='_grid '])
  > li
  > :is([class$='_card'], [class*='_card ']),
.en-site
  main
  :is([class$='_card'], [class*='_card ']):has(:is([class$='_media'], [class*='_media '])) {
  overflow: hidden;
  border: 0;
  border-radius: 18px;
  background: var(--am-color-white);
  box-shadow: var(--am-shadow-sm);
  transition:
    transform 220ms var(--am-ease),
    box-shadow 220ms var(--am-ease);
}

.en-site
  main
  :is([class$='_card'], [class*='_card ']):has(:is([class$='_media'], [class*='_media '])):hover {
  transform: translateY(-4px);
  box-shadow: var(--am-shadow-md);
}

.en-site main :is([class$='_media'], [class*='_media ']) {
  overflow: hidden;
}

.en-site main :is([class$='_media'], [class*='_media ']) img {
  transition: transform 400ms var(--am-ease);
}

.en-site
  main
  :is([class$='_card'], [class*='_card ']):hover
  :is([class$='_media'], [class*='_media '])
  img {
  transform: scale(1.04);
}

.en-site main :is([class$='_cardTitle'], [class*='_cardTitle ']) {
  font-weight: 800;
  letter-spacing: -0.01em;
}

.en-site main :is([class$='_priceAmount'], [class*='_priceAmount ']) {
  font-weight: 900;
}

/* Search and filter boxes. */
.en-site main :is([class$='_searchCard'], [class*='_searchCard ']) {
  border: 0;
  border-radius: 20px;
  box-shadow: var(--am-shadow-md);
}

.en-site main :is([class$='_control'], [class*='_control ']) {
  min-block-size: 48px;
  border-radius: 12px;
}

.en-site main :is([class$='_submit'], [class*='_submit ']) {
  border-radius: 999px;
}

.en-site main :is([class$='_chip'], [class*='_chip ']) {
  border-radius: 999px;
}

.en-site main :is([class$='_resultsBar'], [class*='_resultsBar ']) {
  padding-block-end: 12px;
  border-block-end: 1px solid var(--am-color-border);
}

/* Vehicle page: large rounded photo, strong title, framed price panel, underlined tabs. */
.en-site main :is([class$='_gallery'], [class*='_gallery ']),
.en-site main :is([class$='_heroImage'], [class*='_heroImage ']) {
  border-radius: 20px;
}

.en-site main :is([class$='_infoColumn'], [class*='_infoColumn ']) > h1 {
  font-size: clamp(1.7rem, 3.2vw, 2.4rem);
  font-weight: 900;
  line-height: 1.35;
}

.en-site main :is([class$='_pricePanel'], [class*='_pricePanel ']) {
  border: 1px solid color-mix(in srgb, var(--am-color-blue) 35%, var(--am-color-border));
  border-radius: 18px;
  box-shadow: var(--am-shadow-sm);
}

.en-site main [role='tablist'] {
  gap: 4px;
  border-block-end: 1px solid var(--am-color-border);
}

.en-site main [role='tab'] {
  border-radius: 0;
  border-block-end: 2px solid transparent;
  background: none;
  font-weight: 700;
}

.en-site main [role='tab'][aria-selected='true'] {
  border-block-end-color: var(--am-color-blue);
  color: var(--am-color-blue);
}

.en-site main :is([class$='_specRow'], [class*='_specRow ']):nth-child(even) {
  background: color-mix(in srgb, var(--am-color-surface) 70%, transparent);
}

/* Request form: a soft card. */
.en-site
  main
  form:is([class$='_form'], [class*='_form ']):has(:is([class$='_consent'], [class*='_consent '])) {
  border: 0;
  border-radius: 20px;
  box-shadow: var(--am-shadow-md);
}

@media (prefers-reduced-motion: reduce) {
  .en-site main :is([class$='_card'], [class*='_card ']),
  .en-site main :is([class$='_media'], [class*='_media ']) img {
    transition: none;
  }
}

/* ======================================================================= footer */
.en-footer {
  margin-block-start: 64px;
  padding-block: 64px 26px;
  background:
    radial-gradient(
      800px 320px at 85% 0%,
      color-mix(in srgb, var(--en-accent) 18%, transparent),
      transparent 70%
    ),
    var(--en-ink);
  color: var(--en-on-dark-muted);
}

.en-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1.2fr;
  gap: clamp(20px, 4vw, 48px);
}

.en-footer .en-card {
  display: grid;
  gap: 12px;
  align-content: start;
}

.en-about {
  gap: 16px;
}

.en-cardTitle {
  margin: 0;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.en-cardTitle::after {
  content: '';
  display: block;
  inline-size: 36px;
  block-size: 2px;
  margin-block-start: 10px;
  background: var(--en-accent-light);
}

.en-text {
  margin: 0;
  line-height: 2;
}

.en-facts {
  margin: 0;
  font-size: 0.82rem;
  opacity: 0.8;
}

.en-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2px 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.en-link {
  display: inline-flex;
  align-items: center;
  min-block-size: 36px;
  color: var(--en-on-dark-muted);
  text-decoration: none;
}

.en-link:hover,
.en-link:focus-visible {
  color: #fff;
}

.en-rows {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.en-rows li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  line-height: 1.8;
}

.en-rows svg {
  flex: none;
  inline-size: 18px;
  block-size: 18px;
  margin-block-start: 5px;
  color: var(--en-accent-light);
}

.en-rows .en-link {
  min-block-size: auto;
}

.en-rowHint {
  color: rgb(255 255 255 / 55%);
  font-size: 0.8rem;
}

.en-preLine {
  white-space: pre-line;
}

.en-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 4px 0 0;
  padding: 0;
  list-style: none;
}

.en-iconButton {
  display: grid;
  place-items: center;
  inline-size: 44px;
  block-size: 44px;
  border: 1px solid var(--en-line-dark);
  border-radius: 50%;
  color: #fff;
  transition:
    background-color 160ms var(--am-ease),
    border-color 160ms var(--am-ease);
}

.en-iconButton svg {
  inline-size: 20px;
  block-size: 20px;
}

.en-iconButton:hover,
.en-iconButton:focus-visible {
  border-color: transparent;
  background: var(--en-accent-strong);
}

.en-bottom {
  margin-block-start: 40px;
  padding-block-start: 20px;
  border-block-start: 1px solid var(--en-line-dark);
  font-size: 0.85rem;
}

.en-bottom p {
  margin: 0;
}

@media (max-width: 960px) {
  .en-footer .en-grid {
    grid-template-columns: 1fr 1fr;
  }

  .en-about {
    grid-column: 1 / -1;
  }
}

@media (max-width: 600px) {
  .en-footer .en-grid {
    grid-template-columns: 1fr;
  }
}

/* =======================================================================
 * «لوکس پرانرژی» layer (Figma proposal C, owner 2026-10-31). Everything above is the shared
 * template chrome (header, inner pages, footer) with the «en-» prefix; this layer gives it the
 * dark navy base, the electric-blue gradient and the per-category accents, and styles the
 * Energy homepage. Category accents are fixed brand colours of this template; the company
 * theme still drives the base accent (--en-brand).
 * ======================================================================= */
.en-site {
  --en-bg: #0d1530;
  --en-surface: #141d40;
  --en-elevated: #16204a;
  --en-sunken: #0a1026;
  --en-line: #24305e;
  --en-line-strong: #34437a;
  --en-text: #eef2fb;
  --en-muted: #aab6d3;
  --en-glow: #00e0ff;
  --en-grad: linear-gradient(90deg, #2f6bff, #00c2ff);
  --en-electric: #00e0ff;
  --en-hybrid: #12d18e;
  --en-suv: #ffb020;
  --en-sport: #ff5c8a;
  --en-ink: var(--en-sunken);
}

/* -------------------------------------------------------------- header (dark, blurred) */
.en-header {
  background: rgb(13 21 48 / 90%);
  box-shadow: 0 1px 0 var(--en-line);
}

.en-strip {
  background: var(--en-sunken);
}

.en-navLink {
  color: var(--en-muted);
}

.en-navLink:hover,
.en-navLink:focus-visible,
.en-navLink[aria-current='page'] {
  color: var(--en-text);
}

.en-navLink::after {
  background: var(--en-glow);
}

/* The official logo has dark lettering, so on the dark header it sits on a soft plate: a pearl
   gradient with a thin glow ring, rounded and sized to fit inside the bar (not a pasted white box). */
.en-brand {
  padding: 5px 14px;
  border-radius: 14px;
  background: linear-gradient(180deg, #fff 0%, #e9eef8 100%);
  box-shadow:
    0 0 0 1px rgb(255 255 255 / 35%),
    0 0 18px rgb(var(--am-color-blue-rgb, 79 140 255) / 35%);
}

.en-brand img {
  block-size: 46px;
  inline-size: auto;
}

.en-site .en-iconButton,
.en-site .en-menuButton {
  color: var(--en-text);
  border-color: var(--en-line);
}

.en-site .am-button--primary,
.en-cta {
  border: 0;
  background: var(--en-grad);
  color: #fff;
}

.en-site .am-button--primary:hover,
.en-cta:hover {
  box-shadow: 0 8px 32px rgb(0 194 255 / 35%);
}

/* ------------------------------------------------------------------- footer */
.en-footer {
  background: var(--en-sunken);
  border-block-start: 1px solid var(--en-line);
}

/* ------------------------------------------------------------------- homepage */
.en-page {
  background: var(--en-bg);
  color: var(--en-text);
  padding-block-end: 1px;
}

/* Only the Energy parts are dark; the shared CMS sections below keep their own colours. */
.en-sectionHead h2,
.en-searchTitle {
  color: var(--en-text);
}

.en-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(60% 80% at 15% 40%, rgb(47 107 255 / 45%), transparent 70%),
    radial-gradient(40% 60% at 85% 80%, rgb(0 224 255 / 18%), transparent 70%), var(--en-bg);
}

.en-heroInner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  align-items: center;
  gap: 48px;
  inline-size: var(--en-width);
  min-block-size: min(640px, 80vh);
  margin-inline: auto;
  padding-block: 56px 88px;
}

.en-heroText {
  display: grid;
  gap: 20px;
  justify-items: start;
}

.en-eyebrow {
  margin: 0;
  padding: 6px 14px;
  border: 1px solid rgb(0 224 255 / 40%);
  border-radius: 999px;
  background: rgb(0 224 255 / 12%);
  color: var(--en-electric);
  font-size: 0.85rem;
  font-weight: 700;
}

.en-eyebrow[data-size='md'] {
  font-size: 0.95rem;
}

.en-eyebrow[data-size='lg'] {
  font-size: 1.05rem;
}

.en-eyebrow[data-weight='regular'] {
  font-weight: 400;
}

.en-heroTitle {
  margin: 0;
  color: var(--en-text);
  font-size: clamp(2.2rem, 5vw, 4rem);
  font-weight: 800;
  line-height: 1.2;
}

.en-heroTitle span {
  display: block;
  background: linear-gradient(90deg, #00e0ff, #2f6bff);
  background-clip: text;
  color: transparent;
}

.en-heroLead {
  max-inline-size: 36em;
  margin: 0;
  color: var(--en-muted);
  font-size: 1.1rem;
  line-height: 1.9;
}

.en-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.en-primary,
.en-ghost {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-block-size: 52px;
  padding-inline: 26px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  transition:
    box-shadow 200ms var(--am-ease),
    background-color 200ms var(--am-ease);
}

.en-primary {
  background: var(--en-grad);
  color: #fff;
}

.en-primary:hover,
.en-primary:focus-visible {
  box-shadow: 0 8px 32px rgb(0 194 255 / 40%);
}

.en-ghost {
  border: 1.5px solid var(--en-line-strong);
  color: var(--en-text);
}

.en-ghost:hover,
.en-ghost:focus-visible {
  border-color: var(--en-glow);
  background: var(--en-elevated);
}

.en-primary svg,
.en-ghost svg,
.en-more svg,
.en-cardCta svg {
  inline-size: 18px;
  block-size: 18px;
}

.en-heroCar {
  position: relative;
  display: block;
  color: var(--en-muted);
  text-decoration: none;
}

/* Floor glow under the vehicle photo. */
.en-heroCar::before {
  content: '';
  position: absolute;
  inset-inline: 6%;
  inset-block-end: 6%;
  block-size: 26%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgb(0 224 255 / 45%), transparent);
  filter: blur(6px);
}

.en-heroCar img {
  position: relative;
  display: block;
  inline-size: 100%;
  block-size: auto;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: 0 30px 60px rgb(0 0 0 / 40%);
}

.en-heroCaption {
  position: relative;
  display: block;
  margin-block-start: 14px;
  font-size: 0.85rem;
  text-align: center;
}

/* Search card overlaps the bottom of the hero. */
.en-searchWrap {
  position: relative;
  z-index: 2;
  inline-size: var(--en-width);
  margin: -56px auto 0;
}

.en-searchCard {
  padding: 24px;
  border: 1px solid var(--en-line);
  border-radius: 24px;
  background: rgb(20 29 64 / 94%);
  box-shadow: 0 20px 48px rgb(5 10 30 / 50%);
  backdrop-filter: blur(12px);
}

.en-searchHead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-block-end: 16px;
}

.en-searchTitle {
  margin: 0;
  font-size: 1.15rem;
}

.en-compareLink,
.en-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-block-size: var(--am-touch-target);
  color: var(--en-glow);
  font-weight: 700;
  text-decoration: none;
}

.en-compareLink svg {
  inline-size: 18px;
  block-size: 18px;
}

/* The shared finder's labels and controls on the dark card. */
.en-searchCard label,
.en-searchCard legend {
  color: var(--en-muted);
}

.en-searchCard select,
.en-searchCard input {
  border-color: var(--en-line);
  background-color: var(--en-surface);
  color: var(--en-text);
}

.en-searchCard select:disabled {
  border-color: var(--en-line);
  background-color: var(--en-sunken);
  color: var(--en-muted);
  opacity: 0.7;
}

.en-searchCard {
  --am-color-ink: var(--en-text);
  --am-color-text: var(--en-text);
  --am-color-muted: var(--en-muted);
}

.en-searchCard select:focus-visible,
.en-searchCard input:focus-visible {
  border-color: var(--en-glow);
  outline: 2px solid var(--en-glow);
  outline-offset: 1px;
}

.en-section {
  inline-size: var(--en-width);
  margin: 0 auto;
  padding-block-start: 88px;
}

.en-sectionHead {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-block-end: 28px;
}

.en-sectionHead h2 {
  margin: 0;
  font-size: clamp(1.6rem, 3vw, 2rem);
  font-weight: 800;
}

.en-kicker {
  margin: 0 0 6px;
  color: var(--en-muted);
  font-size: 0.9rem;
}

/* ---- per-category accent: one custom property drives icon, border, glow and badge */
.en-site [data-accent='electric'] {
  --en-cat: var(--en-electric);
}

.en-site [data-accent='hybrid'] {
  --en-cat: var(--en-hybrid);
}

.en-site [data-accent='suv'] {
  --en-cat: var(--en-suv);
}

.en-site [data-accent='sport'] {
  --en-cat: var(--en-sport);
}

.en-site [data-accent='brand'] {
  --en-cat: #00c2ff;
}

.en-categories {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.en-category {
  display: grid;
  align-content: end;
  gap: 8px;
  min-block-size: 200px;
  padding: 24px;
  border: 1px solid color-mix(in srgb, var(--en-cat) 45%, transparent);
  border-radius: 24px;
  background:
    radial-gradient(
      80% 80% at 50% 30%,
      color-mix(in srgb, var(--en-cat) 26%, transparent),
      transparent 70%
    ),
    var(--en-surface);
  color: var(--en-text);
  text-decoration: none;
  transition:
    transform 200ms var(--am-ease),
    box-shadow 200ms var(--am-ease);
}

.en-category:hover,
.en-category:focus-visible {
  transform: translateY(-3px);
  box-shadow: 0 12px 36px color-mix(in srgb, var(--en-cat) 30%, transparent);
}

.en-catBox {
  display: inline-grid;
  place-items: center;
  inline-size: 52px;
  block-size: 52px;
  margin-block-end: auto;
  border-radius: 16px;
  background: color-mix(in srgb, var(--en-cat) 16%, transparent);
  color: var(--en-cat);
}

.en-catIcon {
  inline-size: 28px;
  block-size: 28px;
}

.en-catLabel {
  font-size: 1.4rem;
  font-weight: 800;
}

.en-catHint {
  color: var(--en-muted);
  font-size: 0.9rem;
}

.en-brands {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 28px;
  inline-size: var(--en-width);
  margin: 56px auto 0;
}

.en-brands a {
  color: var(--en-muted);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-decoration: none;
}

.en-brands a:hover,
.en-brands a:focus-visible {
  color: var(--en-text);
}

.en-homeGrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.en-slides {
  margin-block-start: 24px;
}

.en-slide {
  /* The slot is decided by the slideshow (marquee card width, grid column); a fixed width here made the
     card wider than its slot, so neighbouring cards overlapped. */
  inline-size: 100%;
}

.en-cardLink {
  display: flex;
  flex-direction: column;
  block-size: 100%;
  overflow: hidden;
  border: 1px solid var(--en-line);
  border-radius: 20px;
  background: var(--en-surface);
  color: var(--en-text);
  text-decoration: none;
  box-shadow: 0 8px 24px rgb(5 10 30 / 35%);
  transition:
    transform 200ms var(--am-ease),
    border-color 200ms var(--am-ease);
}

.en-cardLink:hover,
.en-cardLink:focus-visible {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--en-cat) 60%, transparent);
}

.en-cardMedia {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  /* Without this a photo that is taller than 16:10 stretches its own card (cards of one row differed in height). */
  overflow: hidden;
  flex: none;
  border-block-end: 3px solid var(--en-cat);
  background:
    radial-gradient(
      70% 80% at 50% 45%,
      color-mix(in srgb, var(--en-cat) 32%, transparent),
      transparent 75%
    ),
    var(--en-sunken);
}

.en-cardMedia img {
  inline-size: 100%;
  block-size: 100%;
  object-fit: cover;
}

.en-badge {
  position: absolute;
  inset-block-start: 12px;
  inset-inline-start: 12px;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgb(10 16 38 / 80%);
  color: var(--en-cat);
  font-size: 0.78rem;
  font-weight: 700;
}

.en-cardBody {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 8px;
  padding: 18px 20px 20px;
}

/* Cards in a row line up whatever the name length (owner 2026-11-01): the name keeps room for
   two lines (longer ones end with «…»), price and «مشاهدهٔ خودرو» sit at the bottom. */
.en-vehicleTitle {
  display: -webkit-box;
  overflow: hidden;
  min-block-size: 3em;
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.en-cardBody > .en-cardFooter {
  margin-block-start: auto;
}

.en-cardBody > :is(.en-offer, .en-cardCta) {
  align-self: flex-start;
}

.en-cardMeta {
  color: var(--en-muted);
  font-size: 0.85rem;
}

.en-cardFooter {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-block-start: 12px;
  border-block-start: 1px solid var(--en-line);
  color: var(--en-electric);
  font-weight: 800;
}

/* The shared PriceTag reads the base ink/muted tokens: remap them on the dark card. */
.en-cardFooter {
  --am-color-ink: var(--en-electric);
  --am-color-text: var(--en-electric);
  --am-color-muted: var(--en-muted);
}

.en-stock {
  color: var(--en-muted);
  font-size: 0.8rem;
  font-weight: 500;
}

.en-offer {
  justify-self: start;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgb(255 176 32 / 16%);
  color: var(--en-suv);
  font-size: 0.78rem;
  font-weight: 700;
}

.en-cardCta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-block-start: 4px;
  color: var(--en-glow);
  font-size: 0.9rem;
  font-weight: 700;
}

.en-empty {
  padding: 32px;
  border: 1px dashed var(--en-line-strong);
  border-radius: 20px;
  color: var(--en-muted);
  text-align: center;
}

/* The shared CMS sections below the Energy layout: spacing only, their own cards stay legible. */
/* Spacing only for the CMS sections after the vehicles (not the stories strip on top). */
.en-page > #vehicles ~ section {
  margin-block-start: 88px;
}

@media (max-width: 1100px) {
  .en-homeGrid,
  .en-categories {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .en-heroInner {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-block: 32px 80px;
  }

  .en-heroCar {
    order: -1;
  }

  .en-section {
    padding-block-start: 56px;
  }

  .en-category {
    min-block-size: 150px;
    padding: 18px;
  }
}

@media (max-width: 520px) {
  .en-homeGrid {
    grid-template-columns: 1fr;
  }

  .en-actions > a {
    flex: 1 1 100%;
    justify-content: center;
  }

  .en-searchCard {
    padding: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .en-category,
  .en-cardLink,
  .en-primary,
  .en-ghost {
    transition: none;
  }

  .en-category:hover,
  .en-cardLink:hover {
    transform: none;
  }
}

/* Shared CMS sections have a transparent background; give the news block a light one so its dark text stays readable on any template base (owner 2026-11-07). */
.en-page #news {
  background: var(--am-color-white);
}

/* The «all news» link had a light colour meant for a dark background: on this white block it was invisible (owner 2026-11-12). */
.en-page #news a[href='/news'] {
  color: var(--am-color-blue);
  font-weight: 800;
}

/* The one vehicle card (owner 2026-11-25): colours only. */
.en-site {
  --vc-bg: var(--en-surface, #141d40);
  --vc-ink: var(--en-text, #eef2fb);
  --vc-line: var(--en-line, #24305e);
  --vc-box: rgb(255 255 255 / 5%);
  --vc-muted: var(--en-muted, #aab6d3);
  --vc-price: var(--en-electric);
  --vc-struck: #ff9aa0;
}
