:root {
    --bg-soft: #f6f9f6;
}

body {
    background-color: var(--bg-soft);
}

.cart-badge {
    position: absolute;
    top: 2px;
    right: -6px;
    font-size: .65rem;
}

.hero {
    background: linear-gradient(135deg, var(--brand-green), var(--brand-green-dark));
}

.product-card {
    border-radius: 10px;
    transition: box-shadow .15s ease;
}

.product-card:hover {
    box-shadow: 0 2px 10px rgba(0, 0, 0, .08);
}

/* Product card image: a perfect square, like Flipkart/Amazon listing tiles, so a tall
   bottle and a wide bunch of bananas still line up in a tidy grid. object-fit: contain
   (not cover) keeps each product's true shape intact on the light padding background,
   rather than cropping it to fill the square. */
.pc-image-wrap {
    position: relative;
}

.pc-image-square {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    background: #f5f7f5;
    border-radius: 10px 10px 0 0;
    overflow: hidden;
}

.pc-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 10px;
    opacity: 0;
    transition: opacity .25s ease;
}

.pc-image.active {
    opacity: 1;
}

.pc-dots {
    position: absolute;
    bottom: 8px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 5px;
    z-index: 2;
}

.pc-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(0, 0, 0, .25);
    cursor: pointer;
    transition: background-color .2s ease, transform .2s ease;
}

.pc-dot.active {
    background-color: var(--brand-green);
    transform: scale(1.25);
}

.no-image-placeholder {
    background: #f5f7f5;
    border-radius: 10px 10px 0 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.detail-no-image {
    height: 320px;
    background: #eef1ee;
    border-radius: .5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.price-strike {
    text-decoration: line-through;
    color: #999;
    font-size: .85rem;
}

.category-card {
    border-radius: 12px;
    text-align: center;
    transition: transform .15s ease;
}

.category-card:hover {
    transform: translateY(-3px);
}

.category-card img {
    height: 70px;
    width: 70px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0 auto;
    display: block;
}

.category-placeholder {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: #eef1ee;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.site-footer {
    background: #eef3ee;
    border-top: 1px solid #dfe7df;
}

.status-circle {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #ccc;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.status-step.active .status-circle {
    background: var(--brand-green);
}

.status-step .small {
    color: #999;
}

.status-step.active .small {
    color: var(--brand-green-dark);
    font-weight: 600;
}

/* ===== Homepage (app-style layout) ===== */

/* Greeting + search */
.greet-hi {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.2;
}

.greet-cart {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--brand-green);
    font-size: 1.2rem;
    text-decoration: none;
}

.greet-cart .cart-badge {
    top: -2px;
    right: -2px;
}

.home-search {
    position: relative;
}

.home-search .bi-search {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #8a9a8a;
}

.home-search input {
    border: 0;
    border-radius: 50rem;
    padding: .8rem 1.2rem .8rem 3rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .07);
}

/* Section headings ("Popular Products" ... "See All") */
.section-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: .75rem;
}

.section-head h5 {
    margin: 0;
    font-weight: 700;
}

.section-head a {
    font-size: .9rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--brand-green);
}

.home-section {
    margin-bottom: 1.75rem;
}

/* Banner slider: native scroll-snap (swipeable on touch) + JS autoplay. 1 slide on mobile, 2 on desktop. */
.banner-track {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.banner-track::-webkit-scrollbar {
    display: none;
}

.banner-slide {
    flex: 0 0 100%;
    scroll-snap-align: start;
}

@media (min-width: 992px) {
    .banner-slide {
        flex-basis: calc((100% - 12px) / 2);
    }
}

.banner-card {
    position: relative;
    display: flex;
    align-items: center;
    aspect-ratio: 2.1 / 1;
    padding: 1.25rem 1.5rem;
    border-radius: 18px;
    overflow: hidden;
    color: #fff;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .1);
}

.banner-card:hover {
    color: #fff;
}

.banner-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.banner-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, .6), rgba(0, 0, 0, .05));
}

.banner-deco {
    position: absolute;
    right: -10px;
    bottom: -18px;
    font-size: 7.5rem;
    opacity: .15;
    line-height: 1;
}

.banner-text {
    position: relative;
    max-width: 75%;
}

.banner-text h4 {
    font-weight: 800;
    font-size: 1.3rem;
    margin-bottom: .25rem;
}

.banner-text p {
    margin: 0;
    font-size: .9rem;
    opacity: .95;
}

@media (min-width: 992px) {
    .banner-text h4 {
        font-size: 1.6rem;
    }
}

.banner-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 10px;
}

.banner-dot {
    width: 8px;
    height: 8px;
    padding: 0;
    border: 0;
    border-radius: 50rem;
    background: #c9d3c9;
    transition: width .2s ease, background-color .2s ease;
}

.banner-dot.active {
    width: 22px;
    background: var(--brand-green);
}

/* Horizontal scrollers (categories + product rows): scrollbar hidden for a native-app feel */
.h-scroll {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    padding: 4px 2px 10px;
    margin: 0 -2px;
    -webkit-overflow-scrolling: touch;
}

.h-scroll::-webkit-scrollbar {
    display: none;
}

.h-scroll.hs-dragging {
    cursor: grabbing;
    scroll-snap-type: none;
    user-select: none;
}

.cat-item {
    flex: 0 0 auto;
    width: 78px;
    text-align: center;
    text-decoration: none;
    color: #212529;
    scroll-snap-align: start;
}

.cat-thumb {
    width: 68px;
    height: 68px;
    margin: 0 auto 6px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .08);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--brand-green);
    font-size: 1.6rem;
}

.cat-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cat-name {
    font-size: .75rem;
    font-weight: 600;
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Product rows: horizontal scroll on mobile, a normal 6-up grid on desktop (mouse users can't swipe) */
.pr-item {
    flex: 0 0 auto;
    width: 158px;
    scroll-snap-align: start;
}

@media (min-width: 992px) {
    .product-row {
        flex-wrap: wrap;
        overflow: visible;
    }

    .pr-item {
        width: calc((100% - 5 * 12px) / 6);
    }
}

/* ===== Mobile bottom navigation ===== */
.bottom-nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1030;
    display: flex;
    justify-content: space-around;
    background: #fff;
    border-top: 1px solid #e5eae5;
    box-shadow: 0 -3px 12px rgba(0, 0, 0, .06);
    padding: 6px 0 calc(6px + env(safe-area-inset-bottom, 0px));
}

.bn-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    text-decoration: none;
    color: #8a9a8a;
    font-size: .7rem;
}

.bn-icon {
    font-size: 1.35rem;
    line-height: 1.2;
}

.bn-item.active {
    color: var(--brand-green);
    font-weight: 700;
}

.bn-badge {
    position: absolute;
    top: -4px;
    right: -10px;
    font-size: .6rem;
}

/* Keep the last bit of page content clear of the fixed bar */
@media (max-width: 991.98px) {
    body {
        padding-bottom: 76px;
    }
}

/* ===== Offers (coupons) page ===== */
.coupon-card {
    border: 0;
    border-radius: 14px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .07);
    overflow: hidden;
}

.coupon-code {
    display: inline-block;
    border: 2px dashed var(--brand-orange);
    color: var(--brand-orange);
    font-weight: 800;
    letter-spacing: 1px;
    border-radius: 8px;
    padding: .25rem .75rem;
}

/* ===== Delivery area pill (homepage header) ===== */
.delivery-pill {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    min-width: 0;
    max-width: calc(100vw - 175px);
    padding: .3rem .8rem;
    border: 1px solid rgba(2, 96, 42, .25);
    background: rgba(2, 96, 42, .06);
    color: var(--brand-green);
    border-radius: 50rem;
    font-size: .8rem;
    font-weight: 600;
    line-height: 1.3;
    cursor: default;
}

.delivery-pill .bi {
    flex-shrink: 0;
}

.delivery-pill .dp-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (min-width: 992px) {
    .delivery-pill {
        max-width: 340px;
        margin-left: .5rem;
        font-size: .85rem;
    }
}
