/* Motor detail page – template matching design: hero (black right), title, info, gallery 8, section, colors, CTA */

html.motor-page,
body.motor-page {
    overflow-x: hidden;
    max-width: 100%;
}

html.motor-page {
    scroll-behavior: smooth;
}

.motor-page {
    font-family: "BMWMotorradW01-Regular", Arial, sans-serif;
    color: #111;
    background: #fff;
}

/* Let the hero section define height; don’t clip with global .hero (90vh + overflow hidden) */
.motor-page .motor-header.hero,
body.motor-page .motor-header.hero {
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
}

/* Ensure main content is visible */
.motor-main {
    display: block !important;
    position: relative;
    z-index: 1;
}

.motor-header {
    position: relative;
}

.motor-header .hero-nav {
    background: #fff;
    color: #111;
}

/* Hero: black overlay right, content in overlay; height tuned so video fits without cutting motor */
.motor-hero {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 620px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Desktop hero video: full screen, fills hero; centered; hidden on mobile */
.motor-hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    z-index: 0;
    display: block;
}

.motor-hero-overlay {
    position: absolute;
    top: 0;
    right: 0;
    width: 20%;
    min-width: 280px;
    height: 100%;
    background: rgba(22, 23, 26, 0.8);
    pointer-events: none;
    animation: motorOverlayFadeIn 0.7s ease-out forwards;
    z-index: 1;
}

@keyframes motorOverlayFadeIn {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.motor-hero-content {
    position: absolute;
    top: 0;
    right: 0;
    width: 19.8%;
    min-width: 280px;
    height: 100%;
    padding: 24px 28px 152px 28px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    animation: motorContentFadeIn 0.8s ease-out 0.15s both;
    z-index: 2;
}

.motor-hero-content-inner {
    width: 100%;
    max-width: 100%;
    text-align: left;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

@keyframes motorContentFadeIn {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.motor-hero-year {
    font-family: "BMWMotorradW01-Regular", Arial, sans-serif;
    font-size: 16px;
    color: rgba(255,255,255,0.95);
    margin: 0 0 4px;
}

.motor-hero-title {
    font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
    font-size: clamp(18px, 2.2vw + 16px, 36px);
    font-weight: 700;
    color: #fff;
    margin: 0 0 4px;
    letter-spacing: 0.02em;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.motor-hero-price {
    font-family: "BMWMotorradW01-Regular", Arial, sans-serif;
    font-size: 22px;
    color: #fff;
    margin: 0 0 16px;
}

.motor-hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: flex-start;
}

.motor-hero-btn.hero-button {
    display: inline-block;
    padding: 10px 48px;
    background: transparent;
    border: 2px solid #fff;
    color: #fff;
    text-decoration: none;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 0.5px;
    min-width: 320px;
    text-align: center;
    transition: background 0.2s ease, color 0.2s ease;
}

.motor-hero-btn-first.hero-button {
    background: #fff;
    color: #111;
    border-color: #fff;
}

.motor-hero-btn.hero-button:hover,
.motor-hero-btn-first.hero-button:hover {
    background: #0062ff;
    color: #fff;
    border-color: #0062ff;
}

/* Title + subtitle: left-aligned with paragraph below (same max-width as info section) */
.motor-title-section {
    background: #fff;
    padding: 56px 39px 20px;
    text-align: left;
}

.motor-title-inner {
    max-width: 1200px;
    margin: 0 auto;
}

.motor-main {
    box-sizing: border-box;
    overflow-x: hidden;
}

.motor-page-title {
    font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
    font-size: 64px;
    font-weight: 700;
    margin: 0 0 12px;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: #111;
    line-height: 1.1;
}

.motor-page-subtitle {
    font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
    font-size: 32px;
    font-weight: 700;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: #111;
}

/* Info section like servisi: text left, image right; centered with header */
.motor-info-section {
    background: #fff;
    padding: 6px 39px 72px;
}

.motor-info-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
}

.motor-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.motor-info-body {
    font-family: "BMWMotorradW01-Regular", Arial, sans-serif;
    font-size: 17px;
    line-height: 1.65;
    color: #333;
    margin: 0;
}

.motor-ratio-3-2 {
    aspect-ratio: 3 / 2;
    overflow: hidden;
}

.motor-info-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Gallery: white title strip (black text), grid full width, row 1: 25% 30% 25% 20%, row 2: 30% 25% 20% 25% */
.motor-gallery-section {
    background: #fff;
    padding: 0;
    margin: 0;
}

.motor-gallery-inner {
    max-width: none;
    margin: 0;
    padding: 40px 0 0;
}

.motor-gallery-header {
    padding: 0 39px;
}

.motor-gallery-separator {
    position: relative;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.motor-gallery-line {
    display: block;
    position: absolute;
    left: 15%;
    right: 15%;
    top: 50%;
    height: 3px;
    background: #333;
}

.motor-gallery-icon {
    position: relative;
    width: 120px;
    height: 120px;
    object-fit: contain;
    background: #fff;
    padding: 0 16px;
}

.motor-gallery-heading {
    font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
    font-size: 32px;
    font-weight: 700;
    color: #111;
    margin: 0;
    padding: 0 0 28px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    background: #fff;
}

.motor-gallery-grid {
    display: grid;
    grid-template-columns: repeat(20, 1fr);
    grid-auto-rows: 420px;
    gap: 0;
    background: #111;
}

.motor-gallery-card {
    position: relative;
    overflow: hidden;
    background: #000;
}

.motor-gallery-card:nth-child(1) { grid-column: span 5; }
.motor-gallery-card:nth-child(2) { grid-column: span 6; }
.motor-gallery-card:nth-child(3) { grid-column: span 5; }
.motor-gallery-card:nth-child(4) { grid-column: span 4; }
.motor-gallery-card:nth-child(5) { grid-column: span 6; }
.motor-gallery-card:nth-child(6) { grid-column: span 5; }
.motor-gallery-card:nth-child(7) { grid-column: span 4; }
.motor-gallery-card:nth-child(8) { grid-column: span 5; }

.motor-gallery-card-image {
    position: absolute;
    inset: 0;
}

.motor-gallery-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.motor-gallery-card:hover .motor-gallery-card-image img {
    transform: scale(1.08);
}

.motor-gallery-card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px 16px 22px;
    background: #fff;
    transform: translateY(100%);
    transition: transform 0.35s ease;
    display: flex;
    flex-direction: column;
    min-height: 80px;
}

.motor-gallery-card:hover .motor-gallery-card-content {
    transform: translateY(0);
}

.motor-gallery-card-title {
    font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #111;
    margin: 0 0 auto;
}

.motor-gallery-card-line {
    width: 100%;
    height: 4px;
    background: #888;
    margin-top: 12px;
    flex-shrink: 0;
    transition: background 0.2s ease;
}

.motor-gallery-card:hover .motor-gallery-card-line {
    background: #0062ff;
}

/* Make gallery cards clickable */
.motor-gallery-card {
    cursor: pointer;
}

/* Carousel wrapper: no layout change on desktop */
.motor-gallery-carousel-wrap {
    position: relative;
}

.motor-gallery-carousel-controls {
    display: none;
}

/* ===== Lightbox Modal ===== */
.gallery-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
}

.gallery-lightbox.is-open {
    display: flex;
}

.lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
}

.lightbox-content {
    position: relative;
    z-index: 2;
    max-width: 90%;
    max-height: 85%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox-image {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
}

.lightbox-title {
    color: #fff;
    font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
    font-size: 18px;
    margin-top: 20px;
    text-align: center;
}

.lightbox-close {
    position: absolute;
    top: 24px;
    right: 24px;
    z-index: 3;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

.lightbox-close:hover {
    opacity: 1;
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    cursor: pointer;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: #fff;
}

.lightbox-prev {
    left: 24px;
}

.lightbox-next {
    right: 24px;
}

.lightbox-prev img,
.lightbox-next img {
    width: 24px;
    height: 24px;
}

.lightbox-counter {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    color: #fff;
    font-family: "BMWMotorradW01-Regular", Arial, sans-serif;
    font-size: 16px;
}

/* Mobile lightbox adjustments */
@media (max-width: 640px) {
    .lightbox-prev,
    .lightbox-next {
        width: 40px;
        height: 40px;
    }
    
    .lightbox-prev {
        left: 12px;
    }
    
    .lightbox-next {
        right: 12px;
    }
    
    .lightbox-close {
        top: 16px;
        right: 16px;
    }
    
    .lightbox-title {
        font-size: 16px;
        padding: 0 16px;
    }
}

/* Section: title + paragraph (narrow width) + full-width image; centered with header */
.motor-section-block {
    background: #fff;
    padding: 56px 39px 72px;
}

.motor-section-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
}

.motor-section-text-wrap {
    max-width: 640px;
    margin-left: auto;
    margin-right: auto;
    text-align: left;
}

.motor-section-heading {
    font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
    font-size: 28px;
    font-weight: 700;
    color: #111;
    margin: 0 0 20px;
}

.motor-section-text {
    font-family: "BMWMotorradW01-Regular", Arial, sans-serif;
    font-size: 17px;
    line-height: 1.65;
    color: #333;
    margin-bottom: 32px;
}

.motor-section-full-image {
    width: 100%;
    overflow: hidden;
}

.motor-section-full-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* Design section: "Dizajn dinamik", 3:2 slideshow; centered with header */
.motor-colors-section {
    background: #fff;
    padding: 56px 39px 72px;
}

.motor-colors-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
    text-align: center;
}

.motor-colors-separator {
    position: relative;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.motor-colors-line {
    display: block;
    position: absolute;
    left: 15%;
    right: 15%;
    top: 50%;
    height: 3px;
    background: #333;
}

.motor-colors-icon {
    position: relative;
    width: 120px;
    height: 120px;
    object-fit: contain;
    background: #fff;
    padding: 0 16px;
}

.motor-colors-heading {
    font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
    font-size: 32px;
    font-weight: 700;
    color: #111;
    margin: 0 0 32px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.motor-colors-layout {
    position: relative;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}

.motor-colors-main-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 3 / 2;
    background: #fff;
    overflow: visible;
}

/* Swatches are sibling of main-wrap: desktop = overlay bottom-right, mobile = below */
.motor-color-swatches-wrap {
    position: absolute;
    bottom: 0;
    right: 28px;
    z-index: 2;
}

.motor-color-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.motor-color-slide.is-active {
    opacity: 1;
    pointer-events: auto;
}

.motor-color-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;  /* full image visible, never cropped at edges */
    object-position: center bottom;
    display: block;
}

.motor-color-swatches {
    display: flex;
    flex-direction: row;
    gap: 12px;
    flex-wrap: wrap;
}

.motor-swatch-btn {
    position: relative;
    width: 108px;
    height: 72px;
    padding: 0;
    border: none;
    border-radius: 0;
    background: #fff;
    cursor: pointer;
    overflow: hidden;
    flex-shrink: 0;
    aspect-ratio: 3 / 2;
}

.motor-swatch-btn > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.motor-swatch-btn .motor-swatch-tick {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 28px;
    height: 28px;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.motor-swatch-btn .motor-swatch-tick img {
    width: 16px;
    height: 16px;
    object-fit: contain;
    display: block;
    filter: brightness(0) invert(1);
}

.motor-swatch-btn.is-active .motor-swatch-tick {
    opacity: 1;
}

/* CTA: no title/separator, just content; centered with header */
.motor-cta-section {
    background: #fff;
    padding: 56px 39px 72px;
}

.motor-cta-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
}

.motor-cta-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.motor-cta-lead {
    font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
    font-size: 20px;
    color: #111;
    margin: 0 0 16px;
}

.motor-cta-para {
    font-family: "BMWMotorradW01-Regular", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    margin: 0 0 24px;
}

.motor-cta-btn.hero-button {
    display: inline-block;
    padding: 12px 24px;
    background: #111;
    color: #fff;
    border: 2px solid #111;
    text-decoration: none;
    font-size: 13px;
    letter-spacing: 0.5px;
    transition: background 0.2s ease, color 0.2s ease;
}

.motor-cta-btn.hero-button:hover {
    background: #0062ff;
    color: #fff;
    border-color: #0062ff;
}

.motor-cta-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Back to top */
.motor-back-to-top {
    background: #fff;
    padding: 24px;
    text-align: center;
}

.motor-back-to-top .back-to-top-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    letter-spacing: 0.3px;
    color: #111;
    text-decoration: none;
}

.motor-back-to-top .back-to-top-icon {
    width: 20px;
    height: 20px;
}

/* Responsive */
@media (max-width: 1024px) {
    .motor-hero-overlay,
    .motor-hero-content {
        width: 40%;
        min-width: 260px;
    }
    .motor-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .motor-gallery-grid .motor-gallery-card {
        grid-column: span 1;
    }
    .motor-gallery-card {
        aspect-ratio: 4 / 3;
    }
}

/* Tablet - keep desktop layout, smaller header (50% height) */
@media (max-width: 1024px) and (min-width: 641px) {
    .motor-hero {
        height: 50vh;
        min-height: 350px;
    }
    .motor-hero-overlay {
        width: 40%;
    }
    .motor-hero-content {
        width: 40%;
        padding: 80px 24px 30px;
    }
    .motor-hero-content-inner {
        gap: 12px;
    }
    .motor-hero-year {
        font-size: 14px;
    }
    .motor-hero-title {
        font-size: 28px;
    }
    .motor-hero-price {
        font-size: 18px;
    }
    .motor-hero-buttons {
        gap: 10px;
        margin-top: 16px;
    }
    .motor-hero-btn.hero-button {
        min-width: 140px;
        padding: 8px 16px;
        font-size: 12px;
    }
    .motor-page-title {
        font-size: 38px;
    }
    .motor-page-subtitle {
        font-size: 20px;
    }
    .motor-info-grid,
    .motor-cta-grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }
    /* Gallery on tablet - 2 columns, no gap, bigger photos */
    .motor-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 300px;
        gap: 0;
    }
    .motor-gallery-grid .motor-gallery-card {
        grid-column: span 1;
    }
    .motor-gallery-card:nth-child(1),
    .motor-gallery-card:nth-child(2),
    .motor-gallery-card:nth-child(3),
    .motor-gallery-card:nth-child(4),
    .motor-gallery-card:nth-child(5),
    .motor-gallery-card:nth-child(6),
    .motor-gallery-card:nth-child(7),
    .motor-gallery-card:nth-child(8) {
        grid-column: span 1;
    }
    .motor-title-section {
        padding-left: 28px;
        padding-right: 28px;
    }
    .motor-info-section,
    .motor-section-block,
    .motor-colors-section,
    .motor-cta-section {
        padding-left: 28px;
        padding-right: 28px;
    }
    .motor-gallery-header {
        padding-left: 28px;
        padding-right: 28px;
    }
}

/* Mobile - single column stacked layout */
@media (max-width: 640px) {
    .motor-hero {
        height: 90vh;
        min-height: 480px;
    }
    .motor-hero-overlay {
        width: 100%;
        background: rgba(0, 0, 0, 0.9);
    }
    .motor-hero-content {
        width: 100%;
        padding: 120px 24px 40px;
        align-items: flex-start;
        text-align: left;
    }
    .motor-hero-buttons {
        align-items: flex-start;
    }
    .motor-hero-btn.hero-button {
        min-width: 300px;
        width: 100%;
        max-width: 360px;
        padding: 10px 40px;
        font-size: 15px;
    }
    .motor-colors-layout {
        grid-template-columns: 1fr;
    }
    .motor-colors-icon {
        width: 90px;
        height: 90px;
    }
    .motor-color-swatches {
        flex-direction: row;
        flex-wrap: wrap;
    }
    .motor-page-title {
        font-size: 36px;
    }
    .motor-page-subtitle {
        font-size: 22px;
    }
    .motor-info-grid,
    .motor-cta-grid {
        grid-template-columns: 1fr;
    }
    .motor-cta-right {
        order: 1;
    }
    .motor-cta-left {
        order: 2;
    }
    .motor-gallery-grid {
        grid-template-columns: 1fr;
    }
    .motor-gallery-grid .motor-gallery-card {
        grid-column: span 1;
    }
    .motor-gallery-card {
        aspect-ratio: 4 / 3;
    }
    .motor-color-swatches-wrap {
        position: absolute;
        bottom: 12px;
        right: 12px;
    }
    .motor-title-section {
        padding-left: 24px;
        padding-right: 24px;
    }
    .motor-info-section,
    .motor-section-block,
    .motor-colors-section,
    .motor-cta-section {
        padding-left: 24px;
        padding-right: 24px;
    }
    .motor-gallery-header {
        padding-left: 24px;
        padding-right: 24px;
    }
    .motor-gallery-icon {
        width: 90px;
        height: 90px;
    }
}

@media (max-width: 640px) {
    /* No horizontal scroll on mobile */
    body.motor-page,
    .motor-page {
        overflow-x: hidden;
    }

    /* Motor header: index.php style – photo on top, then content section below (no overlay) */
    .motor-header.hero {
        height: auto;
        min-height: auto;
        display: block;
        overflow: visible;
    }

    .motor-hero {
        position: relative;
        height: auto;
        min-height: auto;
        display: block;
        padding-top: 55vh;
        background-position: center 85%;
        background-size: cover;
    }

    .motor-hero-video {
        display: none !important;
    }

    .motor-hero-overlay {
        display: none;
    }

    .motor-hero-content {
        position: relative;
        top: 0;
        right: 0;
        width: 100%;
        min-width: 0;
        max-width: none;
        background: #16171a;
        padding: 36px 0 40px 0;
        align-items: stretch;
        text-align: left;
        animation: none;
        opacity: 1;
        transform: none;
    }

    .motor-hero-content-inner {
        width: 100%;
        padding: 0 16px 0 16px;
        box-sizing: border-box;
    }

    .motor-hero-buttons {
        width: 100%;
        margin-top: 8px;
        padding: 0;
        box-sizing: border-box;
    }

    .motor-hero-btn.hero-button {
        display: block;
        width: 100%;
        max-width: none;
        box-sizing: border-box;
        padding: 10px 40px;
        font-size: 15px;
    }

    .motor-hero-year {
        color: rgba(255, 255, 255, 0.9);
    }

    .motor-hero-title {
        color: #fff;
    }

    .motor-hero-price {
        color: #fff;
    }

    .motor-page-title {
        font-size: 28px;
    }
    .motor-page-subtitle {
        font-size: 18px;
    }
    .motor-hero-title {
        font-size: clamp(16px, 4.5vw, 26px);
    }
    .motor-hero-price {
        font-size: 16px;
    }
    .motor-gallery-heading,
    .motor-colors-heading {
        font-size: 20px;
    }
    .motor-gallery-icon {
        width: 72px;
        height: 72px;
    }
    .motor-colors-icon {
        width: 72px;
        height: 72px;
    }

    /* Smaller paragraph text on mobile */
    .motor-page-subtitle {
        font-size: 15px;
    }
    .motor-info-body {
        font-size: 14px;
    }
    .motor-section-text {
        font-size: 14px;
    }
    .motor-cta-para {
        font-size: 14px;
    }
    .motor-cta-lead {
        font-size: 16px;
    }

    /* More margin left/right on whole page for mobile */
    .motor-title-section {
        padding-left: 28px;
        padding-right: 28px;
    }
    .motor-info-section,
    .motor-section-block,
    .motor-cta-section {
        padding-left: 28px;
        padding-right: 28px;
    }
    .motor-gallery-header {
        padding-left: 28px;
        padding-right: 28px;
    }

    /* Gallery: carousel on mobile – instant card change (no slide), like kontakti slideshow */
    .motor-gallery-carousel-wrap {
        overflow: hidden;
        background: #f2f2f2;
        position: relative;
    }
    .motor-gallery-grid {
        display: block;
        grid-template-columns: unset;
        grid-auto-rows: unset;
        gap: 0;
        width: 100%;
    }
    .motor-gallery-grid .motor-gallery-card {
        width: 100%;
        max-width: 100%;
        grid-column: unset;
        display: none;
        flex-direction: column;
        aspect-ratio: unset;
        background: #f2f2f2;
    }
    .motor-gallery-grid .motor-gallery-card.is-visible {
        display: flex;
    }
    .motor-gallery-card-image {
        position: relative;
        width: 100%;
        height: 290px;
        flex-shrink: 0;
        overflow: hidden;
    }
    .motor-gallery-card-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
    .motor-gallery-card-content {
        position: relative;
        flex-shrink: 0;
        background: #f2f2f2;
        padding: 18px 20px 24px;
        display: flex;
        flex-direction: column;
        min-height: 90px;
        transform: none;
    }
    .motor-gallery-card-title {
        font-family: "BMWMotorradW01-Bold", Arial, sans-serif;
        font-size: 20px;
        color: #111;
        margin: 0 0 4px;
        line-height: 1.3;
    }
    .motor-gallery-card-line {
        margin-top: auto;
        width: calc(100% - 10px);
        height: 4px;
        background: #999;
    }
    /* Controls: same style as kontakti.php slideshow (arrows + counter) */
    .motor-gallery-carousel-controls {
        display: block;
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 290px;
        pointer-events: none;
    }
    .motor-gallery-carousel-controls .motor-gallery-arrow {
        pointer-events: auto;
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        z-index: 2;
        width: 48px;
        height: 48px;
        border-radius: 0;
        background: rgba(255, 255, 255, 0.95);
        border: none;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 0;
    }
    .motor-gallery-carousel-controls .motor-gallery-arrow:hover {
        background: #fff;
    }
    .motor-gallery-prev {
        left: 0;
    }
    .motor-gallery-next {
        right: 0;
    }
    .motor-gallery-arrow-img {
        width: 20px;
        height: 20px;
        object-fit: contain;
        display: block;
    }
    .motor-gallery-counter {
        position: absolute;
        bottom: 12px;
        right: 16px;
        z-index: 2;
        font-size: 14px;
        color: #fff;
        text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
        font-family: "BMWMotorradW01-Regular", Arial, sans-serif;
    }

    /* First section (paragraph + image): image inside margins, no cut on right */
    .motor-info-section .motor-info-inner {
        max-width: 100%;
        box-sizing: border-box;
    }
    .motor-info-section .motor-info-grid {
        max-width: 100%;
        overflow: hidden;
    }
    .motor-info-section .motor-info-image.motor-ratio-3-2 {
        min-height: 280px;
        max-width: 100%;
        overflow: hidden;
    }
    .motor-info-section .motor-info-image .motor-info-img {
        object-fit: cover;
        height: 100%;
        min-height: 280px;
        max-width: 100%;
        display: block;
    }

    /* "Gjithçka që ju nevojitet..." section: full-width image bigger on mobile */
    .motor-section-block .motor-section-full-image {
        min-height: 280px;
    }
    .motor-section-block .motor-section-full-image img {
        min-height: 280px;
        object-fit: cover;
        width: 100%;
    }

    /* Dizajn dinamik: full-width slideshow, controls under it, squared and centered */
    .motor-colors-section {
        padding-left: 0;
        padding-right: 0;
    }
    .motor-colors-inner {
        padding: 0;
    }
    .motor-colors-separator,
    .motor-colors-heading {
        padding-left: 28px;
        padding-right: 28px;
    }
    .motor-colors-layout {
        max-width: none;
        width: 100%;
    }
    .motor-color-swatches-wrap {
        position: static;
        padding: 20px 16px;
        display: flex;
        justify-content: center;
    }
    .motor-color-swatches {
        justify-content: center;
        gap: 12px;
    }
    .motor-swatch-btn {
        width: 64px;
        height: 64px;
        aspect-ratio: 1;
    }
}
