/**
 * OEM ASTRA J — WHY CHOOSE OEM (mobile ≤900px)
 * Auto-moving bubble marquee (~2 visible). Desktop uses footer-workshop-desktop.css.
 */

.mob-v2-why {
  display: none;
}

.mob-v2-why-motion {
  display: none;
}

/* Shared OEM wordmark colors (logo: red arc on O + charcoal EM) */
.why-oem-logo-mark {
  display: inline;
  white-space: nowrap;
  font: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  vertical-align: baseline;
}

.why-oem-logo-o,
.why-oem-logo-em {
  display: inline;
  font: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  vertical-align: baseline;
}

.why-oem-logo-o {
  background: conic-gradient(from 218deg, #D71920 0deg 78deg, #111111 78deg 360deg);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

@supports not ((-webkit-background-clip: text) or (background-clip: text)) {
  .why-oem-logo-o {
    color: #D71920;
    -webkit-text-fill-color: #D71920;
    background: none;
  }
}

.why-oem-logo-em {
  color: #111111;
  -webkit-text-fill-color: #111111;
}

@keyframes whyOemMarqueeLtr {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@keyframes whyOemMarqueeRtl {
  from { transform: translateX(0); }
  to { transform: translateX(50%); }
}

/* ── Shared mobile/tablet (≤900px) ── */
@media (max-width: 900px) {
  body.is-home-page .mob-v2-why {
    --why-choose-red: #D71920;
    --why-choose-text: #111111;
    --why-choose-muted: #6b7280;
    --why-bubble-gap: 10px;
    position: relative;
    display: block;
    margin: 4px 16px 8px;
    padding: 10px 16px 8px;
    border-radius: 0;
    background: #ffffff;
    border: none;
    box-shadow: none;
    overflow: hidden;
    box-sizing: border-box;
  }

  body.is-home-page .mob-v2-why-motion {
    display: block;
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    opacity: 0.5;
    background: repeating-linear-gradient(
      -32deg,
      transparent 0,
      transparent 28px,
      rgba(0, 0, 0, 0.035) 28px,
      rgba(0, 0, 0, 0.035) 29px
    );
    -webkit-mask-image: linear-gradient(120deg, transparent 0%, #000 30%, #000 70%, transparent 100%);
    mask-image: linear-gradient(120deg, transparent 0%, #000 30%, #000 70%, transparent 100%);
  }

  body.is-home-page .mob-v2-why-head {
    position: relative;
    z-index: 1;
    margin: 0 0 6px;
    padding: 0;
    text-align: left;
  }

  body.is-home-page .mob-v2-why-label {
    margin: 0;
    font-size: clamp(22px, 5.5vw, 28px);
    font-weight: 800;
    letter-spacing: 0.06em;
    line-height: 1.05;
    color: #1e5bb8;
    text-transform: uppercase;
    text-align: left;
  }

  /* Keep WHY + OEM wordmark on the same type scale (no logo O/EM scale drift) */
  body.is-home-page .mob-v2-why-label .why-oem-logo-mark,
  body.is-home-page .mob-v2-why-label .why-oem-logo-o,
  body.is-home-page .mob-v2-why-label .why-oem-logo-em {
    font: inherit;
    font-size: 1em;
    font-weight: inherit;
    letter-spacing: inherit;
    line-height: inherit;
    vertical-align: baseline;
  }

  html[dir="rtl"] body.is-home-page .mob-v2-why-label {
    font-family: var(--font-ar, Cairo, sans-serif);
    letter-spacing: 0.04em;
    text-align: left;
  }

  body.is-home-page .mob-v2-why-title {
    display: none;
  }

  /* Viewport clips to ~2 bubbles; track auto-marquee loops */
  body.is-home-page .mob-v2-why-viewport {
    position: relative;
    z-index: 1;
    container-type: inline-size;
    container-name: why-bubbles;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    padding: 2px 0 4px;
    margin: 0;
    box-sizing: border-box;
    cursor: grab;
    touch-action: pan-y pinch-zoom;
  }

  body.is-home-page .mob-v2-why-viewport.is-dragging {
    cursor: grabbing;
  }

  body.is-home-page .mob-v2-why-track {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: stretch;
    width: max-content;
    min-width: 100%;
    margin: 0;
    padding: 0;
    gap: 0;
    will-change: transform;
    transition: none;
  }

  body.is-home-page .mob-v2-why-track.why-oem-marquee {
    animation: whyOemMarqueeLtr 28s linear infinite;
    animation-play-state: running;
  }

  html[dir="rtl"] body.is-home-page .mob-v2-why-track.why-oem-marquee {
    animation-name: whyOemMarqueeRtl;
  }

  body.is-home-page .mob-v2-why-viewport.is-paused .mob-v2-why-track.why-oem-marquee,
  body.is-home-page .mob-v2-why-viewport.is-dragging .mob-v2-why-track.why-oem-marquee,
  body.is-home-page .mob-v2-why-viewport:has(.mob-v2-why-card:hover) .mob-v2-why-track.why-oem-marquee {
    animation-play-state: paused;
  }

  body.is-home-page .mob-v2-why-set {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: stretch;
    flex-shrink: 0;
    gap: var(--why-bubble-gap);
    padding-inline-end: var(--why-bubble-gap);
    box-sizing: content-box;
  }

  body.is-home-page .mob-v2-why-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0;
    flex: 0 0 calc((100cqw - var(--why-bubble-gap)) / 2);
    width: calc((100cqw - var(--why-bubble-gap)) / 2);
    min-width: calc((100cqw - var(--why-bubble-gap)) / 2);
    max-width: calc((100cqw - var(--why-bubble-gap)) / 2);
    min-height: 0;
    height: auto;
    padding: 14px 10px 12px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid #dce3ee;
    box-shadow: none;
    box-sizing: border-box;
  }

  body.is-home-page .mob-v2-why-card:hover {
    z-index: 2;
  }

  body.is-home-page .mob-v2-why-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    margin: 0 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #c9a227;
    border: none;
    border-radius: 50%;
    background: #1e5bb8;
  }

  body.is-home-page .mob-v2-why-icon svg {
    width: 22px;
    height: 22px;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.75;
  }

  body.is-home-page .mob-v2-why-copy {
    display: contents;
  }

  body.is-home-page .mob-v2-why-card-title {
    margin: 0 0 4px;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.25;
    color: #0f2d6b;
  }

  html[dir="rtl"] body.is-home-page .mob-v2-why-card-title {
    font-family: var(--font-ar, Cairo, sans-serif);
  }

  body.is-home-page .mob-v2-why-card-desc {
    margin: 0 0 10px;
    font-size: 11px;
    font-weight: 400;
    line-height: 1.4;
    color: var(--why-choose-muted);
    display: block;
    -webkit-line-clamp: unset;
    line-clamp: unset;
    overflow: visible;
  }

  html[dir="rtl"] body.is-home-page .mob-v2-why-card-desc {
    font-family: var(--font-ar, Cairo, sans-serif);
  }

  body.is-home-page .mob-v2-why-card::after {
    content: "";
    display: block;
    width: 28px;
    height: 2px;
    margin: 0 auto;
    background: #c9a227;
    border-radius: 1px;
  }

  body.is-home-page .mob-v2-why-more {
    display: none;
  }

  body.is-home-page .mob-v2-why-arrow {
    display: none;
  }

  body.is-home-page .home-premium-info .premium-service-card--expandable {
    display: none !important;
  }

  body.is-home-page .home-premium-info {
    margin-inline: 0 !important;
    margin-bottom: 0 !important;
    padding: 0 !important;
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    border-radius: 0 !important;
  }

  @media (prefers-reduced-motion: reduce) {
    body.is-home-page .mob-v2-why-viewport {
      overflow-x: auto;
      -webkit-overflow-scrolling: touch;
      scroll-snap-type: x mandatory;
      scrollbar-width: thin;
      scrollbar-color: rgba(30, 91, 184, 0.35) transparent;
    }

    body.is-home-page .mob-v2-why-track.why-oem-marquee {
      animation: none !important;
      transform: none !important;
    }

    body.is-home-page .mob-v2-why-set[aria-hidden="true"] {
      display: none !important;
    }

    body.is-home-page .mob-v2-why-set {
      padding-inline-end: 0;
    }

    body.is-home-page .mob-v2-why-card {
      scroll-snap-align: start;
    }
  }
}

@media (max-width: 420px) {
  body.is-home-page .mob-v2-why {
    --why-bubble-gap: 8px;
    padding: 8px 12px 6px;
  }

  body.is-home-page .mob-v2-why-label {
    font-size: clamp(20px, 5.8vw, 26px);
  }

  body.is-home-page .mob-v2-why-card {
    padding: 10px 6px 8px;
    border-radius: 16px;
  }

  body.is-home-page .mob-v2-why-icon {
    width: 40px;
    height: 40px;
    margin: 0 0 6px;
  }

  body.is-home-page .mob-v2-why-card-title {
    font-size: 12px;
  }

  body.is-home-page .mob-v2-why-card-desc {
    font-size: 10px;
    max-width: none;
  }
}

/* WHY OEM removed — hide on all viewports (Track / Help cards stay) */
#mobV2WhySection,
.mob-v2-why {
  display: none !important;
}
