/* Final visual alignment overrides for the Donyaye Ghesti home demo. */
.dg-demo-home {
    margin-top: -18px;
    background:
        linear-gradient(180deg, #fff 0 236px, var(--dg-accent, #e51542) 236px 100%) !important;
}

.dg-demo-home::before {
    content: "";
    position: absolute;
    top: 140px !important;
    right: -10vw !important;
    left: -10vw !important;
    bottom: auto !important;
    z-index: 1;
    width: auto !important;
    height: 158px !important;
    border-radius: 0 0 50% 50% / 0 0 100% 100% !important;
    background: #fff !important;
    pointer-events: none;
}

.dg-demo-home::after {
    display: none !important;
    content: none !important;
}

.dg-demo-category-rail {
    max-width: none !important;
    padding: 2px 0 8px !important;
    overflow: hidden;
}

.dg-demo-category-marquee {
    width: min(100%, 1280px);
    margin: 0 auto;
    overflow: hidden;
    padding: 0 0 8px;
    direction: ltr;
}

.dg-demo-category-scroll {
    display: flex !important;
    width: max-content !important;
    grid-template-columns: none !important;
    align-items: stretch !important;
    gap: 20px !important;
    padding: 58px 0 0 !important;
    direction: rtl;
    animation: dgCategoryMarquee 46s linear infinite;
    will-change: transform;
}

.dg-demo-category-marquee:hover .dg-demo-category-scroll,
.dg-demo-category-marquee:focus-within .dg-demo-category-scroll {
    animation-play-state: paused;
}

.dg-demo-category-card {
    flex: 0 0 166px !important;
    min-width: 166px !important;
    min-height: 148px !important;
}

@keyframes dgCategoryMarquee {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }
}

.dg-demo-spotlight {
    display: flex;
    min-height: 664px;
    align-items: center;
    justify-content: center;
    margin-top: 0 !important;
    padding: 82px 18px 118px !important;
    background: transparent !important;
}

.dg-demo-spotlight::before {
    content: "";
    position: absolute;
    right: -10vw !important;
    left: -10vw !important;
    bottom: -48px !important;
    width: auto !important;
    height: 158px !important;
    border-radius: 50% 50% 0 0 / 100% 100% 0 0 !important;
    background: #fff !important;
    pointer-events: none;
}

.dg-demo-spotlight::after {
    display: none !important;
    content: none !important;
}

.dg-demo-spotlight-panel {
    grid-template-columns: 140px minmax(0, 1fr) !important;
    max-width: 1200px;
    min-height: 410px;
    margin: 0 auto !important;
}

.dg-demo-spotlight-panel::before {
    display: none !important;
    content: none !important;
}

.dg-demo-spotlight-thumbs {
    display: flex !important;
    min-width: 0;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-right: 1px solid #eef2f8 !important;
    border-left: 0 !important;
    padding: 0 22px 0 0 !important;
    direction: ltr;
}

.dg-demo-thumb-list {
    display: grid !important;
    width: 92px !important;
    max-height: none !important;
    grid-template-columns: 1fr !important;
    gap: 8px !important;
    overflow: visible !important;
}

.dg-demo-thumb {
    position: relative;
    width: 92px !important;
    height: 66px !important;
    padding: 4px;
    border: 2px solid transparent !important;
    border-radius: 16px !important;
    background: #f3f6fb !important;
    box-shadow: none !important;
    transform: none !important;
}

.dg-demo-thumb:hover,
.dg-demo-thumb:focus {
    border-color: rgba(229, 21, 66, .35) !important;
    background: #fff !important;
    transform: translateX(3px) !important;
}

.dg-demo-thumb.is-active {
    border-color: var(--dg-accent, #e51542) !important;
    background: #fff !important;
    box-shadow: 0 10px 24px rgba(229, 21, 66, .18) !important;
}

.dg-demo-thumb.is-active::after {
    content: "";
    position: absolute;
    right: -8px;
    top: 50%;
    width: 4px;
    height: 34px;
    transform: translateY(-50%);
    border-radius: 8px;
    background: var(--dg-accent, #e51542);
}

.dg-demo-thumb img {
    width: 76px !important;
    height: 52px !important;
    object-fit: contain;
}

.dg-demo-spotlight-mini {
    display: none !important;
}

.dg-demo-slide {
    grid-template-columns: minmax(0, 1fr) 340px !important;
}

.dg-demo-spotlight-visual {
    min-height: 320px !important;
}

.dg-demo-spotlight-visual > img {
    height: 270px !important;
}

footer.main-footer .back-to-top {
    display: none !important;
}

footer.main-footer.dt-sl::before,
footer.main-footer::before,
.main-footer.dt-sl::before,
.main-footer::before {
    display: none !important;
    content: none !important;
}

footer.main-footer .site-description a[href="/"],
footer.main-footer .copyright a[href="/"] {
    color: inherit !important;
    pointer-events: none;
    text-decoration: none !important;
}

.dg-template-banner-stack {
    display: grid;
    gap: 14px;
    align-content: start;
    min-width: 0;
}

.dg-template-product-showcase--full {
    grid-template-columns: 1fr !important;
}

.dg-template-banner-stack .dg-template-side-banner {
    width: 100%;
}

.dg-template-side-banner--primary {
    min-height: 460px !important;
}

.dg-template-side-banner--secondary {
    min-height: 224px !important;
}

.dg-template-side-banner--secondary img {
    min-height: 224px !important;
}

.dg-template-wide-banner img {
    min-height: 128px !important;
}

@media (max-width: 1199px) {
    .dg-demo-home {
        background:
            linear-gradient(180deg, #fff 0 262px, var(--dg-accent, #e51542) 262px 100%) !important;
    }

    .dg-demo-home::before {
        top: 164px !important;
        height: 148px !important;
    }

    .dg-demo-spotlight {
        min-height: 640px;
        padding: 82px 18px 94px !important;
    }

    .dg-demo-spotlight::before {
        height: 148px !important;
    }

    .dg-demo-spotlight-panel {
        grid-template-columns: 120px minmax(0, 1fr) !important;
        max-width: 1080px;
    }

    .dg-demo-slide {
        grid-template-columns: minmax(0, 1fr) 310px !important;
    }

    .dg-demo-thumb-list,
    .dg-demo-thumb {
        width: 76px !important;
    }

    .dg-demo-thumb {
        height: 58px !important;
    }

    .dg-demo-thumb img {
        width: 62px !important;
        height: 46px !important;
    }
}

@media (max-width: 991px) {
    .dg-demo-home {
        background:
            linear-gradient(180deg, #fff 0 270px, var(--dg-accent, #e51542) 270px 100%) !important;
    }

    .dg-demo-home::before {
        top: 176px !important;
        height: 132px !important;
    }

    .dg-demo-spotlight {
        min-height: 697px;
        padding: 104px 18px 108px !important;
    }

    .dg-demo-spotlight::before {
        height: 132px !important;
    }

    .dg-demo-spotlight-panel {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    .dg-demo-spotlight-thumbs {
        display: flex !important;
        margin-bottom: 12px;
        border-right: 0 !important;
        border-bottom: 1px solid #eef2f8;
        padding: 0 0 14px !important;
    }

    .dg-demo-thumb-list {
        display: flex !important;
        width: 100% !important;
        justify-content: center;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        padding: 4px 2px 8px;
        scroll-snap-type: x proximity;
    }

    .dg-demo-thumb {
        flex: 0 0 68px;
        scroll-snap-align: center;
    }

    .dg-demo-thumb.is-active::after {
        right: 50%;
        top: auto;
        bottom: -7px;
        width: 32px;
        height: 4px;
        transform: translateX(50%);
    }

    .dg-demo-slide {
        grid-template-columns: minmax(0, 1fr) 270px !important;
    }

    .dg-demo-category-rail {
        padding-bottom: 12px !important;
    }

    .dg-template-banner-stack {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        order: 2;
    }

    .dg-template-product-showcase .dg-mh-product-grid {
        order: 1;
    }

    .dg-template-banner-stack .dg-template-side-banner,
    .dg-template-side-banner--primary,
    .dg-template-side-banner--secondary {
        min-height: 220px !important;
        height: 220px !important;
    }

    .dg-template-banner-stack .dg-template-side-banner img {
        min-height: 220px !important;
    }
}

@media (max-width: 767px) {
    .dg-demo-home {
        margin-top: -10px;
        background:
            linear-gradient(180deg, #fff 0 190px, var(--dg-accent, #e51542) 190px 100%) !important;
    }

    .dg-demo-home::before {
        top: 132px !important;
        right: -18vw !important;
        left: -18vw !important;
        width: auto !important;
        height: 108px !important;
    }

    .dg-demo-category-scroll {
        padding-top: 52px !important;
        animation-duration: 38s;
    }

    .dg-demo-category-rail {
        padding: 0 0 10px !important;
    }

    .dg-demo-category-card {
        flex-basis: 142px !important;
        min-width: 142px !important;
        min-height: 136px !important;
    }

    .dg-demo-spotlight {
        min-height: 0;
        padding: 50px 14px 104px !important;
    }

    .dg-demo-spotlight::before {
        display: block !important;
        right: -18vw !important;
        left: -18vw !important;
        bottom: -30px !important;
        width: auto !important;
        height: 108px !important;
    }

    .dg-demo-slide {
        grid-template-columns: 1fr !important;
    }

    .dg-template-banner-stack {
        grid-template-columns: 1fr;
    }

    .dg-template-banner-stack .dg-template-side-banner,
    .dg-template-side-banner--primary,
    .dg-template-side-banner--secondary {
        min-height: 240px !important;
        height: 240px !important;
    }

    .dg-template-wide-banner img {
        min-height: 98px !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .dg-demo-category-scroll {
        animation: none !important;
    }

    .dg-demo-category-marquee {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}
