/* ==========================================================================
   Moboplus Theme 2026 — home page
   ========================================================================== */

.mp-home {
    clear: both;
    padding-top: 18px;
}
.mp-home > section { margin-bottom: 30px; }

/* reveal on scroll (enabled by theme-2026.js) */
.mp-reveal-ready [data-reveal] {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .7s var(--mp-ease), transform .7s var(--mp-ease);
}
.mp-reveal-ready [data-reveal].is-visible {
    opacity: 1;
    transform: none;
}

/* ---------- Hero ---------- */
.mp-hero { position: relative; }
.mp-hero__slider {
    border-radius: var(--mp-radius-xl);
    overflow: hidden;
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow);
    isolation: isolate;
}
.mp-hero__slider .item img {
    display: block;
    width: 100%;
    height: auto;
}
.mp-hero__slider .carousel-indicators {
    bottom: 58px;
    margin-bottom: 0;
}
.mp-hero__slider .carousel-indicators li {
    width: 8px;
    height: 8px;
    margin: 0 3px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, .55);
    box-shadow: 0 1px 4px rgba(0, 0, 0, .25);
    transition: width .35s var(--mp-ease), background .3s;
}
.mp-hero__slider .carousel-indicators .active {
    width: 28px;
    height: 8px;
    margin: 0 3px;
    background: #fff;
}
.mp-hero__slider .carousel-control.mp-hero__ctrl {
    top: 42%;
    bottom: auto;
    width: 48px;
    height: 48px;
    margin-top: -24px;
    border-radius: 16px;
    background: rgba(255, 255, 255, .8) !important;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    color: var(--mp-text);
    text-shadow: none;
    opacity: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--mp-shadow);
    transition: opacity .25s, transform .25s var(--mp-ease);
}
.mp-hero__slider .carousel-control.left { left: 22px; }
.mp-hero__slider .carousel-control.right { right: 22px; }
.mp-hero__slider:hover .carousel-control.mp-hero__ctrl { opacity: 1; }
.mp-hero__slider .carousel-control.mp-hero__ctrl:hover { transform: scale(1.06); color: var(--mp-primary); }
.mp-hero__slider .carousel-control .fas {
    position: static;
    margin: 0;
    width: auto;
    height: auto;
    font-size: 15px;
}

/* perks: floating strip overlapping the slider */
.mp-perks {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    margin: -40px 36px 0;
    padding: 8px;
    border-radius: var(--mp-radius-lg);
    background: rgba(255, 255, 255, .92);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    box-shadow: 0 24px 50px -24px rgba(15, 16, 32, .35);
}
.mp-perk {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 18px;
    transition: background .25s;
}
.mp-perk + .mp-perk { position: relative; }
.mp-perk + .mp-perk:before {
    content: "";
    position: absolute;
    right: -1px;
    top: 22%;
    bottom: 22%;
    width: 1px;
    background: var(--mp-border);
}
.mp-perk:hover { background: var(--mp-surface-2); }
.mp-perk__icon {
    flex: 0 0 46px;
    height: 46px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: #fff;
    background: var(--mp-grad);
    box-shadow: 0 10px 20px -10px rgba(91, 61, 245, .8);
}
.mp-perk:nth-child(2) .mp-perk__icon { background: linear-gradient(135deg, #ff9a3d, #ff6a1a); box-shadow: 0 10px 20px -10px rgba(255, 122, 26, .8); }
.mp-perk:nth-child(3) .mp-perk__icon { background: linear-gradient(135deg, #20c997, #0ea672); box-shadow: 0 10px 20px -10px rgba(18, 184, 134, .8); }
.mp-perk:nth-child(4) .mp-perk__icon { background: linear-gradient(135deg, #ff5c8a, #f0346a); box-shadow: 0 10px 20px -10px rgba(255, 61, 110, .8); }
.mp-perk strong {
    display: block;
    font-size: 13.5px;
    font-weight: 600;
    color: var(--mp-text);
}
.mp-perk small {
    display: block;
    margin-top: 2px;
    font-size: 12px;
    color: var(--mp-text-3);
}

/* ---------- Banners ---------- */
.mp-banners { display: grid; gap: 18px; }
.mp-banners--3 { grid-template-columns: repeat(3, 1fr); }
.mp-banners--2 { grid-template-columns: repeat(2, 1fr); }
.mp-banner {
    display: block;
    position: relative;
    border-radius: var(--mp-radius-lg);
    overflow: hidden;
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
    transition: transform .4s var(--mp-ease), box-shadow .4s var(--mp-ease);
}
.mp-banner img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .7s var(--mp-ease);
}
.mp-banner:after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, .35) 50%, transparent 70%);
    transform: translateX(100%);
    transition: transform .8s var(--mp-ease);
    pointer-events: none;
}
.mp-banner:hover { transform: translateY(-4px); box-shadow: var(--mp-shadow); }
.mp-banner:hover img { transform: scale(1.04); }
.mp-banner:hover:after { transform: translateX(-100%); }

.mp-bento {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}
.mp-bento__col { display: flex; flex-direction: column; gap: 18px; }
.mp-bento__col .mp-banner { flex: 1; }

/* ---------- Section shell ---------- */
.mp-section {
    position: relative;
    padding: 24px;
    border-radius: var(--mp-radius-xl);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
}
.mp-section__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 20px;
}
.mp-section__title {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    padding-right: 16px;
    font-size: 20px;
    font-weight: 600;
    color: var(--mp-text);
}
.mp-section__title:before {
    content: "";
    position: absolute;
    right: 0;
    top: 50%;
    width: 6px;
    height: 22px;
    margin-top: -11px;
    border-radius: 6px;
    background: var(--mp-grad);
}
.mp-section__nav { display: flex; gap: 8px; }
.mp-nav-btn {
    width: 42px;
    height: 42px;
    border: 1.5px solid var(--mp-border);
    border-radius: 14px;
    background: #fff;
    color: var(--mp-text-2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    cursor: pointer;
    transition: all .2s var(--mp-ease);
}
.mp-nav-btn:hover {
    border-color: var(--mp-primary);
    background: var(--mp-primary);
    color: #fff;
    transform: translateY(-1px);
}
.mp-nav-btn.is-disabled { opacity: .35; pointer-events: none; }
.mp-nav-btn.swiper-button-lock { display: none; }

/* featured (first product section) */
.mp-section--featured {
    overflow: hidden;
    background: var(--mp-grad);
    box-shadow: var(--mp-shadow-lg);
}
.mp-section--featured:before,
.mp-section--featured:after {
    content: "";
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}
.mp-section--featured:before {
    width: 360px;
    height: 360px;
    top: -160px;
    left: -80px;
    background: radial-gradient(closest-side, rgba(255, 255, 255, .22), transparent);
}
.mp-section--featured:after {
    width: 280px;
    height: 280px;
    bottom: -140px;
    right: 18%;
    background: radial-gradient(closest-side, rgba(255, 154, 61, .35), transparent);
}
.mp-section--featured > * { position: relative; z-index: 1; }
.mp-section--featured .mp-section__title { color: #fff; padding-right: 0; }
.mp-section--featured .mp-section__title:before { display: none; }
.mp-section__spark {
    width: 40px;
    height: 40px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, .18);
    color: #ffd27a;
    font-size: 17px;
}
.mp-section--featured .mp-nav-btn {
    border-color: rgba(255, 255, 255, .3);
    background: rgba(255, 255, 255, .12);
    color: #fff;
}
.mp-section--featured .mp-nav-btn:hover { background: #fff; color: var(--mp-primary); border-color: #fff; }
.mp-section--featured .mp-card { border-color: transparent; }

/* ---------- Categories (story style) ---------- */
.mp-cats__swiper { padding: 6px 2px 4px; margin: -6px -2px -4px; }
.mp-cats__slide { width: 120px; }
.mp-cat__img--empty {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--mp-primary-50), #fff1e6);
    color: var(--mp-primary);
    font-size: 24px;
}
@media (min-width: 768px) {
    .mp-cats .mp-cats__swiper { margin-left: -24px; }
}
.mp-cat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    text-decoration: none !important;
}
.mp-cat__ring {
    position: relative;
    display: block;
    width: 96px;
    height: 96px;
    padding: 3px;
    border-radius: 50%;
    background: conic-gradient(from 210deg, #5b3df5, #b14cf0, #ff7a1a, #ffb547, #5b3df5);
    transition: transform .4s var(--mp-ease);
}
.mp-cat__img {
    display: block;
    width: 100%;
    height: 100%;
    border: 4px solid #fff;
    border-radius: 50%;
    background-color: var(--mp-surface-2);
    background-size: 62%;
    background-position: center;
    background-repeat: no-repeat;
    transition: background-size .4s var(--mp-ease);
}
.mp-cat__title {
    margin: 0;
    max-width: 116px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.6;
    text-align: center;
    color: var(--mp-text-2);
    transition: color .2s;
}
.mp-cat:hover .mp-cat__ring { transform: translateY(-4px) rotate(-6deg); }
.mp-cat:hover .mp-cat__img { background-size: 70%; }
.mp-cat:hover .mp-cat__title { color: var(--mp-primary); }

/* ---------- Product swiper ---------- */
.mp-section .mp-swiper {
    margin: -6px -4px -12px;
    padding: 6px 4px 12px;
}
.mp-section .swiper-slide { height: auto; display: flex; }
/* let the half card peek out to the panel edge (left = end side in RTL) */
@media (min-width: 768px) {
    .mp-section .mp-swiper { margin-left: -24px; padding-left: 0; }
}

/* ---------- Blog section ---------- */
.mp-blog-grid > .swiper-slide { height: auto; display: flex; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1199px) {
    .mp-perks { margin: -30px 20px 0; }
    .mp-perk { padding: 10px 12px; }
    .mp-perk small { display: none; }
}
@media (max-width: 991px) {
    .mp-perks { grid-template-columns: repeat(2, 1fr); margin: 14px 0 0; }
    .mp-perk + .mp-perk:before { display: none; }
    .mp-hero__slider .carousel-indicators { bottom: 10px; }
}
@media (max-width: 767px) {
    .mp-home { padding-top: 12px; }
    .mp-home > section { margin-bottom: 18px; }
    .mp-hero__slider { border-radius: 20px; }
    .mp-hero__slider .carousel-control.mp-hero__ctrl { display: none; }
    .mp-hero__slider .carousel-indicators { bottom: 4px; }
    .mp-hero__slider .carousel-indicators li,
    .mp-hero__slider .carousel-indicators .active { height: 6px; }
    .mp-hero__slider .carousel-indicators .active { width: 18px; }

    .mp-perks {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
        margin: 12px 0 0;
        padding: 0;
        background: transparent;
        box-shadow: none;
        border-radius: 0;
        -webkit-backdrop-filter: none;
        backdrop-filter: none;
    }
    .mp-perk {
        min-width: 0;
        gap: 10px;
        padding: 10px;
        background: #fff;
        border-radius: 16px;
        box-shadow: var(--mp-shadow-sm);
    }
    .mp-perk__icon { flex-basis: 36px; height: 36px; border-radius: 12px; font-size: 15px; }
    .mp-perk strong { font-size: 12px; line-height: 1.6; }

    .mp-section { padding: 18px 14px; border-radius: 24px; }
    .mp-section__head { margin-bottom: 14px; }
    .mp-section__title { font-size: 16.5px; }
    .mp-section__nav { display: none; }
    .mp-section__spark { width: 34px; height: 34px; border-radius: 12px; font-size: 15px; }

    .mp-cats .mp-cats__swiper { margin: -6px -14px -4px; padding: 6px 14px 4px; }
    .mp-cats__slide { width: 80px; }
    .mp-cat { gap: 8px; }
    .mp-cat__img--empty { font-size: 18px; }
    .mp-cat__ring { width: 72px; height: 72px; padding: 2.5px; }
    .mp-cat__img { border-width: 3px; }
    .mp-cat__title { font-size: 11.5px; }

    .mp-section .mp-swiper { margin-left: -14px; margin-right: -14px; padding-left: 14px; padding-right: 14px; }

}

@media (prefers-reduced-motion: reduce) {
    .mp-home *, .mp-home *:before, .mp-home *:after { transition: none !important; }
}

/* hero fallback fade (before Bootstrap JS is available) */
.mp-hero--fade .carousel-inner > .item.active {
    animation: mpHeroFade .7s var(--mp-ease);
}
@keyframes mpHeroFade {
    from { opacity: 0; transform: scale(1.015); }
    to { opacity: 1; transform: none; }
}

/* categories: center when all fit */
.mp-cats__swiper.is-locked .swiper-wrapper { justify-content: space-around; transform: none !important; }
