/* Online shop */
:root {
    --shop-blue: #0b5cff;
    --shop-red: #ef4444;
}
.btn-shop {
    background: var(--shop-blue);
    border-color: var(--shop-blue);
    border-radius: 6px;
    font-weight: 600;
    padding: .6rem 0.935rem;
}
.btn-shop:hover {
    background: #0049d6;
    border-color: #0049d6;
}
.shop .see-all {
    color: var(--shop-blue);
}

/* Title */
.shop-title {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 1.275rem 0 1.062rem;
}
.shop-title img {
    width: 56px;
    height: 56px;
}
.shop-title h1 {
    font-size: 1.6rem;
    font-weight: 800;
    margin: 0;
}
.shop-title p {
    margin: .15rem 0 0;
    color: var(--ek-muted);
}

/* Top grid: categories | hero | perks */
.shop-top {
    display: grid;
    grid-template-columns: 230px minmax(0, 1fr) 230px;
    grid-template-rows: 440px;
    gap: 0.85rem;
}
.cat-menu {
    background: #fff;
    border: 1px solid var(--ek-border);
    border-radius: 6px;
    overflow: hidden auto;
    scrollbar-width: thin;
    display: flex;
    flex-direction: column;
}
.cat-menu a {
    display: flex;
    align-items: center;
    gap: .7rem;
    padding: 0 0.85rem;
    min-height: 28px;
    color: #303038;
    font-size: .82rem;
    flex: 1 0 auto; /* rows share the menu height evenly */
}
.cat-menu.static a {
    padding: .55rem 0.85rem;
    flex: 0 0 auto;
}
.cat-menu a > .bi:first-child {
    color: #767678;
    font-size: 1rem;
}
.cat-menu a:hover,
.cat-menu a.current {
    background: #eef4ff;
    color: var(--shop-blue);
}
.cat-menu a:hover .bi,
.cat-menu a.current .bi {
    color: var(--shop-blue);
}
.cat-menu .cat-all {
    background: var(--shop-blue);
    color: #fff !important;
    font-weight: 600;
    padding: 0.637rem 0.85rem;
    flex: 0 0 auto;
}
.cat-menu .cat-all .bi {
    color: #fff !important;
}
.cat-menu .count {
    font-size: .72rem;
    color: var(--ek-muted);
}
.cat-menu.static {
    position: sticky;
    top: 1rem;
}

.shop-hero {
    position: relative;
    border-radius: 6px;
    overflow: hidden;
    min-height: 0;
}
/* Absolutely positioned so the photo never stretches the grid row. */
.shop-hero .carousel-inner {
    position: absolute;
    inset: 0;
}
.shop-hero .carousel-item {
    height: 100%;
}
.shop-hero .carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.shop-hero .carousel-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(5, 30, 70, .78) 0%, rgba(5, 30, 70, .35) 45%, rgba(5, 30, 70, 0) 70%);
}
.shop-hero-caption {
    position: absolute;
    top: 50%;
    left: 4.5rem;
    transform: translateY(-50%);
    z-index: 2;
    color: #fff;
    max-width: 60%;
}
.shop-hero-caption h2 {
    font-size: clamp(1.4rem, 2.4vw, 2rem);
    font-weight: 800;
    line-height: 1.2;
    text-transform: uppercase;
}
.shop-hero-caption p {
    font-size: .95rem;
    opacity: .95;
    margin-bottom: 1.25rem;
}
.btn-orange {
    background: #f97316;
    color: #fff;
    border-radius: 6px;
    font-weight: 600;
    padding: .6rem 1.19rem;
    box-shadow: none;
}
.btn-orange:hover {
    background: #ea580c;
    color: #fff;
}
.shop-hero .carousel-control-prev,
.shop-hero .carousel-control-next {
    width: 56px;
    opacity: 1;
    z-index: 3;
}
.hero-arrow {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .9);
    color: var(--ek-text);
    display: flex;
    align-items: center;
    justify-content: center;
}
.shop-hero .carousel-indicators {
    z-index: 3;
}
.shop-hero .carousel-indicators [data-bs-target] {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    border: 0;
}
.shop-hero .carousel-indicators .active {
    width: 22px;
    border-radius: 4px;
}

.perks {
    list-style: none;
    margin: 0;
    padding: .5rem 0.85rem;
    background: linear-gradient(180deg, #f3f7ff, #f8faff);
    border: 1px solid #e3ebfa;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
}
.perks li {
    display: flex;
    align-items: center;
    gap: 0.68rem;
    font-size: .8rem;
    font-weight: 600;
    line-height: 1.3;
    padding: .55rem 0;
}
.perks li + li {
    border-top: 1px solid #e3ebfa;
}
.perks small {
    font-weight: 400;
    color: var(--ek-muted);
}
.perk-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
    background: #fff;
}
.perk-icon.blue { color: #0b5cff; }
.perk-icon.green { color: #03a94d; }
.perk-icon.purple { color: #7c3aed; }
.perk-icon.orange { color: #f97316; }

/* Wide banners */
.wide-banner {
    position: relative;
    display: flex;
    align-items: center;
    height: 150px;
    border-radius: 6px;
    overflow: hidden;
    color: var(--ek-text);
}
.wide-banner img {
    position: absolute;
    right: 0;
    top: 0;
    width: 58%;
    height: 100%;
    object-fit: cover;
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 35%);
    mask-image: linear-gradient(90deg, transparent 0%, #000 35%);
}
.wide-body {
    position: relative;
    padding: 0 1.488rem;
    max-width: 55%;
}
.wide-body h3 {
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: .75rem;
}
.wide-banner.theme-yellow {
    background: linear-gradient(90deg, #f2f7c8, #fdf6d8);
}
.wide-banner.theme-yellow h3 {
    color: #166534;
}
.wide-banner.theme-blue {
    background: linear-gradient(90deg, #2f6df6, #5b8ff8);
    color: #fff;
}
.wide-btn {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    border-radius: 6px;
    padding: .45rem 0.935rem;
    font-size: .8rem;
    font-weight: 600;
    background: #166534;
    color: #fff;
}
.wide-banner.theme-blue .wide-btn {
    background: #fff;
    color: var(--shop-blue);
}
.wide-banner.theme-green {
    background: linear-gradient(90deg, #dff3e3, #c9ecd1);
}
.wide-banner.theme-green h3 {
    color: #14532d;
}
.wide-banner.theme-orange {
    background: linear-gradient(90deg, #f2541b, #ff8a3d);
    color: #fff;
}
.wide-banner.theme-orange .wide-btn {
    background: #fff;
    color: #c2410c;
}
.wide-banner.theme-pink {
    background: linear-gradient(90deg, #fde4ef, #fbd0e2);
}
.wide-banner.theme-pink h3 {
    color: #9d174d;
}
.wide-banner.theme-pink .wide-btn {
    background: #be185d;
}
.wide-banner.theme-purple {
    background: linear-gradient(90deg, #6d28d9, #8b5cf6);
    color: #fff;
}
.wide-banner.theme-purple .wide-btn {
    background: #fff;
    color: #6d28d9;
}

/* Product sections and cards */
.p-section .section-head h2 {
    font-size: 1.15rem;
}
.new-pill {
    background: #7c3aed;
    color: #fff;
    font-size: .62rem;
    font-weight: 800;
    padding: .2rem .45rem;
    border-radius: 5px;
}
.sale-dot {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--shop-red);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: .8rem;
}
.p-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 0.85rem;
}
.p-grid.cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}
.p-card {
    position: relative;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--ek-border);
    border-radius: 6px;
    padding: .6rem .6rem .7rem;
    background: #fff;
    transition: box-shadow .2s;
}
.p-card:hover {
    box-shadow: none;
}
.p-img {
    position: relative;
    display: block;
    aspect-ratio: 4 / 3;
    border-radius: 6px;
    overflow: hidden;
    background: #f4f6fa;
    margin-bottom: .6rem;
}
.p-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s;
}
.p-card:hover .p-img img {
    transform: scale(1.04);
}
.p-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    font-size: .68rem;
    font-weight: 700;
    color: #fff;
    padding: .12rem .45rem;
    border-radius: 5px;
    z-index: 1;
}
.p-badge.sale {
    background: var(--shop-red);
}
.p-badge.new {
    background: #03a94d;
}
.p-fav {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 0;
    background: #fff;
    color: #767678;
    font-size: .8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: none;
    z-index: 2;
}
.p-fav.on {
    color: var(--shop-red);
}
.p-name {
    display: block;
    font-weight: 700;
    font-size: .8rem;
    color: var(--ek-text);
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.p-variant {
    color: var(--ek-muted);
    font-size: .74rem;
    margin-top: .1rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.p-rating {
    font-size: .74rem;
    color: #303038;
    margin: .4rem 0 .5rem;
}
.p-rating .bi {
    color: #f59e0b;
}
.p-rating span {
    color: var(--ek-muted);
}
.p-foot {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: .4rem;
    margin-top: auto;
}
.p-prices {
    min-width: 0;
    line-height: 1.15;
}
.p-price {
    font-weight: 800;
    font-size: .95rem;
    white-space: nowrap;
}
.p-price.red {
    color: var(--shop-red);
}
.p-old {
    display: block;
    color: #9ca3af;
    font-size: .7rem;
}
.p-cart {
    width: 34px;
    height: 34px;
    border-radius: 6px;
    border: 0;
    background: var(--shop-blue);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
    transition: background .2s, transform .2s;
}
.p-cart:hover {
    background: #0049d6;
}
.p-cart.added {
    background: #03a94d;
    transform: scale(1.1);
}

/* Stores */
.store-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.85rem;
}
.store-card {
    display: block;
    border: 1px solid var(--ek-border);
    border-radius: 6px;
    overflow: hidden;
    color: var(--ek-text);
    background: #fff;
    transition: box-shadow .2s;
}
.store-card:hover {
    box-shadow: none;
}
.store-cover {
    height: 110px;
    background: #e6efff;
    overflow: hidden;
}
.store-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s;
}
.store-card:hover .store-cover img {
    transform: scale(1.05);
}
.store-body {
    position: relative;
    padding: 1.7rem 0.85rem 0.85rem;
}
.store-logo {
    width: 56px;
    height: 56px;
    border-radius: 6px;
    border: 3px solid #fff;
    background: #fff;
    overflow: hidden;
    box-shadow: none;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--shop-blue);
    font-size: 1.4rem;
    flex-shrink: 0;
}
.store-body .store-logo {
    position: absolute;
    top: -28px;
    left: 1rem;
}
.store-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.store-logo.sm {
    width: 44px;
    height: 44px;
    border-radius: 6px;
}
.store-logo.lg {
    width: 92px;
    height: 92px;
    border-radius: 6px;
    border-width: 4px;
}
.store-card h3 {
    font-size: .98rem;
    font-weight: 700;
    margin-bottom: .2rem;
}
.store-card p {
    color: var(--ek-muted);
    font-size: .8rem;
    margin-bottom: .6rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.store-meta {
    display: flex;
    flex-wrap: wrap;
    gap: .35rem 0.85rem;
    font-size: .76rem;
    color: #606060;
}
.store-hero {
    position: relative;
    height: 230px;
    border-radius: 6px;
    overflow: hidden;
    background: linear-gradient(135deg, #0b5cff, #0a3fa8);
}
.store-hero > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.store-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(5, 25, 60, .85) 0%, rgba(5, 25, 60, .1) 65%);
}
.store-hero-body {
    position: absolute;
    left: 1.75rem;
    right: 1.75rem;
    bottom: 1.5rem;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    gap: 1.062rem;
    color: #fff;
}
.store-hero h1 {
    font-size: 1.6rem;
    font-weight: 800;
    margin: 0 0 .2rem;
}
.store-hero p {
    margin: 0 0 .5rem;
    opacity: .9;
}
.store-meta.light {
    color: rgba(255, 255, 255, .92);
}
.store-side {
    background: #fff;
    border: 1px solid var(--ek-border);
    border-radius: 6px;
    padding: 1.062rem;
}
.side-h {
    font-size: 1rem;
    font-weight: 800;
    margin-bottom: 1rem;
}
.side-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .5rem;
    margin-top: .85rem;
}
.side-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    height: 40px;
    border-radius: 6px;
    font-size: .8rem;
    font-weight: 600;
    background: #eef4ff;
    color: var(--shop-blue);
    transition: background .15s, color .15s;
}
.side-btn:first-child {
    background: var(--shop-blue);
    color: #fff;
}
.side-btn:hover {
    background: #0049d6;
    color: #fff;
}


/* Product detail */
.pd-image {
    position: relative;
    border-radius: 6px;
    overflow: hidden;
    background: #f4f6fa;
    aspect-ratio: 1 / 1;
}
.pd-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.pd-image .p-badge {
    top: 16px;
    left: 16px;
    font-size: .85rem;
    padding: .25rem .6rem;
}
.pd-store {
    font-size: .85rem;
    font-weight: 600;
    color: var(--shop-blue);
}
.pd-info h1 {
    font-size: 1.8rem;
    font-weight: 800;
    margin: .4rem 0 .2rem;
}
.pd-variant {
    color: var(--ek-muted);
    margin-bottom: .5rem;
}
.pd-price {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.637rem;
    font-size: 2rem;
    font-weight: 800;
}
.pd-price .red {
    color: var(--shop-red);
}
.pd-price s {
    font-size: 1.05rem;
    font-weight: 500;
    color: #9ca3af;
}
.pd-price .save {
    font-size: .78rem;
    font-weight: 700;
    background: #fee2e2;
    color: var(--shop-red);
    padding: .2rem .6rem;
    border-radius: 6px;
}
.pd-stock {
    font-size: .85rem;
    font-weight: 600;
    color: var(--shop-red);
    margin: .5rem 0 1.25rem;
}
.pd-stock.in {
    color: #03a94d;
}
.pd-buy {
    display: flex;
    gap: 0.637rem;
}
.pd-perks {
    list-style: none;
    padding: 0.85rem 0.935rem;
    margin: 1.25rem 0;
    background: #f5f8ff;
    border-radius: 6px;
    font-size: .85rem;
}
.pd-perks li {
    display: flex;
    gap: .6rem;
    padding: .25rem 0;
}
.pd-perks .bi {
    color: var(--shop-blue);
}
.pd-h2 {
    font-size: 1.05rem;
    font-weight: 800;
}
.pd-desc {
    color: #606060;
    line-height: 1.65;
}
.pd-seller {
    display: flex;
    align-items: center;
    gap: 0.722rem;
    border: 1px solid var(--ek-border);
    border-radius: 6px;
    padding: 0.68rem 0.85rem;
    color: var(--ek-text);
}
.pd-seller:hover {
    border-color: var(--shop-blue);
}
.pd-seller strong {
    display: block;
}
.pd-seller small {
    color: var(--ek-muted);
}

@media (max-width: 1199.98px) {
    .p-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
    .p-grid.cols-4 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
@media (max-width: 991.98px) {
    .shop-top {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto 280px;
    }
    .cat-menu {
        flex-direction: row;
        overflow-x: auto;
        scrollbar-width: none;
    }
    .cat-menu.static {
        position: static;
    }
    .cat-menu a {
        white-space: nowrap;
        flex: 0 0 auto;
        padding: .6rem 0.85rem;
    }
    .perks {
        display: none;
    }
    .store-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
@media (max-width: 767.98px) {
    .p-grid,
    .p-grid.cols-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: .6rem;
    }
    .shop-top {
        grid-template-rows: auto 230px;
    }
    .shop-hero-caption {
        left: 3.5rem;
        max-width: 75%;
    }
    .wide-body {
        max-width: 70%;
    }
    .store-grid {
        grid-template-columns: minmax(0, 1fr);
    }
    .cart-row {
        flex-wrap: wrap;
    }
    .cart-total {
        min-width: 0;
    }
    .list-head {
        flex-wrap: wrap;
    }
}
