/* =========================================
   BEANO CART PAGE
========================================= */

.beano-cart-page {

    width: 100%;

    min-height: 100vh;

    box-sizing: border-box;

    padding:
        22px 18px 70px;

    background:
        linear-gradient(
            180deg,
            #f8f3e7 0%,
            #f4f0e4 35%,
            #e9eadb 68%,
            #dce5d5 100%
        );

    color:
        #123b25;

}


/* =========================================
   CART HEADER
========================================= */

.beano-cart-header {

    position: relative;

    width: 100%;

    min-height: 125px;

    display: flex;

    align-items: flex-start;

    justify-content: center;

    margin-bottom: 35px;

}


/* =========================================
   CONTINUE SHOPPING
========================================= */

.beano-cart-back {

    position: absolute;

    left: 0;

    top: 14px;

    display: inline-flex;

    align-items: center;

    gap: 8px;

    color:
        #123b25;

    text-decoration: none;

    font-size: 12px;

    font-weight: 800;

}


.beano-cart-back span {

    font-size: 20px;

    line-height: 1;

}


/* =========================================
   CENTER BRAND AREA
========================================= */

.beano-cart-brand {

    display: flex;

    flex-direction: column;

    align-items: center;

    justify-content: center;

}


/* =========================================
   CART PAGE LOGO
========================================= */

.beano-cart-logo-link {

    display: flex;

    align-items: center;

    justify-content: center;

    text-decoration: none;

    margin-bottom: 12px;

}


.beano-cart-logo-image {

    display: block;

    width: 118px;

    height: auto;

    object-fit: contain;

}


/* =========================================
   CART TITLE
========================================= */

.beano-cart-title {

    margin: 0;

    color:
        #123b25;

    font-size: 42px;

    line-height: .95;

    letter-spacing: -2px;

    font-weight: 950;

    text-align: center;

}

/* =========================================
   LAYOUT
========================================= */

.beano-cart-layout {

    width: 100%;

    display: flex;

    flex-direction: column;

    gap: 20px;
}


/* =========================================
   CART ITEMS
========================================= */

.beano-cart-items {

    display: flex;

    flex-direction: column;

    gap: 12px;
}


/* =========================================
   ITEM CARD
========================================= */

.beano-cart-item {

    position: relative;

    display: grid;

    grid-template-columns:
        88px 1fr;

    gap: 14px;

    width: 100%;

    padding: 12px;

    box-sizing: border-box;

    background:
        #fffdf7;

    border:
        1px solid
        rgba(18,59,37,.08);

    border-radius: 23px;

    box-shadow:
        0 8px 25px
        rgba(18,59,37,.055);
}


/* =========================================
   PRODUCT IMAGE
========================================= */

.beano-cart-item__image {

    width: 88px;

    height: 108px;

    overflow: hidden;

    border-radius: 17px;

    background:
        #ece5d4;
}


.beano-cart-item__image img {

    width: 100%;

    height: 100%;

    display: block;

    object-fit: cover;
}


/* =========================================
   DETAILS
========================================= */

.beano-cart-item__details {

    min-width: 0;

    padding:
        3px 25px 3px 0;
}


.beano-cart-item__name {

    margin: 0;

    color:
        #123b25;

    font-size: 15px;

    line-height: 1.15;

    font-weight: 900;
}


.beano-cart-item__id {

    display: block;

    margin-top: 6px;

    color:
        rgba(18,59,37,.35);

    font-size: 8px;

    font-weight: 800;

    letter-spacing: .7px;
}


.beano-cart-item__price {

    margin-top: 9px;

    color:
        #123b25;

    font-size: 15px;

    font-weight: 900;
}


/* =========================================
   REMOVE
========================================= */

.beano-cart-item__remove {

    position: absolute;

    top: 11px;

    right: 11px;

    width: 28px;

    height: 28px;

    padding: 0;

    display: flex;

    align-items: center;

    justify-content: center;

    border: 0;

    border-radius: 50%;

    background:
        #f0ede2;

    color:
        #123b25;

    font-size: 18px;

    cursor: pointer;
}


/* =========================================
   ITEM QUANTITY
========================================= */

.beano-cart-item__quantity {

    display: flex;

    align-items: center;

    gap: 9px;

    margin-top: 10px;
}


.beano-cart-item__qty-button {

    width: 27px;

    height: 27px;

    padding: 0;

    display: flex;

    align-items: center;

    justify-content: center;

    border:
        1px solid
        rgba(18,59,37,.15);

    border-radius: 50%;

    background:
        #ffffff;

    color:
        #123b25;

    font-size: 15px;

    cursor: pointer;
}


.beano-cart-item__quantity-number {

    min-width: 18px;

    text-align: center;

    font-size: 12px;

    font-weight: 900;
}


/* =========================================
   SUMMARY
========================================= */

.beano-cart-summary {

    width: 100%;

    padding:
        23px 19px 19px;

    box-sizing: border-box;

    border-radius: 28px;
    margin-top: 40px;

    background:
    radial-gradient(
        circle at 85% 10%,
        rgba(48, 117, 70, 0.45) 0%,
        transparent 35%
    ),
    linear-gradient(
        145deg,
        #092b1a 0%,
        #0d3b24 48%,
        #082718 100%
    );

    box-shadow:
        0 18px 45px
        rgba(18,59,37,.16);
}


/* =========================================
   SUMMARY HEADING
========================================= */

.beano-cart-summary__heading {

    display: flex;

    align-items: center;

    justify-content: space-between;

    margin-bottom: 25px;

    color:
        rgba(255,255,255,.5);

    font-size: 9px;

    font-weight: 900;

    letter-spacing: 1.5px;
}


/* =========================================
   SUBTOTAL
========================================= */

.beano-cart-summary__row {

    display: flex;

    align-items: center;

    justify-content: space-between;
}


.beano-cart-summary__row span {

    font-size: 14px;

    color:
        rgb(255, 255, 255);
}


.beano-cart-summary__row strong {

    font-size: 17px;
color: #e7e3dc;
    font-weight: 900;
}


/* =========================================
   DELIVERY
========================================= */

.beano-cart-summary__delivery {

    max-width: 220px;

    margin-top: 12px;

    margin-left: auto;

    color:
        rgb(255, 255, 255);

    font-size: 9px;

    line-height: 1.45;

    text-align: right;
}


/* =========================================
   DIVIDER
========================================= */

.beano-cart-summary__line {

    width: 100%;

    height: 1px;

    margin:
        20px 0;

    background:
        rgba(255, 255, 255, 0.12);
}


/* =========================================
   TOTAL
========================================= */

.beano-cart-summary__total {

    display: flex;

    align-items: center;

    justify-content: space-between;
}


.beano-cart-summary__total span {

    font-size: 18px;
color: #e7e3dc;
    font-weight: 900;
}


.beano-cart-summary__total strong {

    color:
        #dcde5bd9;

    font-size: 25px;

    font-weight: 950;
}


/* =========================================
   BIG WHITE CHECKOUT BUTTON
========================================= */

.beano-cart-checkout {

    width: 100%;

    min-height: 58px;

    margin-top: 23px;

    padding:
        0 17px;

    display: flex;

    align-items: center;

    justify-content: space-between;

    box-sizing: border-box;

    border: 0;

    border-radius: 16px;

    background:
        #ffffff;

    color:
        #123b25;

    font-family: inherit;

    font-size: 14px;

    font-weight: 950;

    letter-spacing: -.2px;

    cursor: pointer;

    box-shadow:
        0 7px 18px
        rgba(0,0,0,.14);

    transition:
        transform .18s ease,
        box-shadow .18s ease;
}


.beano-cart-checkout:active {

    transform:
        scale(.98);

    box-shadow:
        0 3px 10px
        rgba(0,0,0,.12);
}


.beano-cart-checkout__arrow {

    width: 34px;

    height: 34px;

    display: flex;

    align-items: center;

    justify-content: center;

    border-radius: 50%;

    background:
        #123b25;

    color:
        #ffffff;

    font-size: 19px;

    line-height: 1;
}


/* =========================================
   TRUST
========================================= */

.beano-cart-note {

    margin-top: 13px;

    color:
        rgba(255,255,255,.4);

    font-size: 9px;

    text-align: center;
}


.beano-cart-note span {

    margin-right: 4px;

    color:
        #f4d33b;
}


/* =========================================
   EMPTY CART
========================================= */

.beano-cart-empty {

    display: none;

    min-height: 300px;

    align-items: center;

    justify-content: center;

    flex-direction: column;

    text-align: center;
}


.beano-cart-empty.is-visible {

    display: flex;
}


.beano-cart-empty__icon {

    width: 70px;

    height: 70px;

    display: flex;

    align-items: center;

    justify-content: center;

    border-radius: 50%;

    background:
        #123b25;

    color:
        #f4d33b;

    font-size: 30px;
}


.beano-cart-empty h2 {

    margin:
        19px 0 7px;

    color:
        #123b25;

    font-size: 23px;

    font-weight: 950;
}


.beano-cart-empty p {

    margin: 0;

    color:
        rgba(18,59,37,.5);

    font-size: 12px;
}


.beano-cart-empty__button {

    margin-top: 20px;

    padding:
        13px 19px;

    display: inline-flex;

    align-items: center;

    gap: 12px;

    border-radius: 999px;

    background:
        #123b25;

    color:
        #ffffff;

    text-decoration: none;

    font-size: 12px;

    font-weight: 900;
}


.beano-cart-empty__button span {

    color:
        #f4d33b;

    font-size: 17px;
}


/* =========================================
   PRODUCT FLY TO CART
========================================= */

.beano-flying-product {

    position: fixed;

    z-index: 999999;

    width: 85px;

    height: 105px;

    object-fit: contain;

    pointer-events: none;

    border-radius: 14px;

    transform-origin: center center;

    will-change:
        transform,
        opacity;

    transition:
        transform 0.75s cubic-bezier(.22,.75,.28,1),
        opacity 0.75s ease;
}


/* =========================================
   CART RECEIVES PRODUCT
========================================= */

#beanoHeaderCart.beano-cart-receiving {

    animation:
        beanoCartReceive .45s ease;
}


@keyframes beanoCartReceive {

    0% {
        transform: scale(1);
    }

    40% {
        transform: scale(1.18);
    }

    70% {
        transform: scale(.94);
    }

    100% {
        transform: scale(1);
    }

}


/* =========================================
   ADDED TO CART STATE
========================================= */

.product-card__cart.is-added,
.product-slide__cart.is-added {

    background:
        #123b25;

    color:
        #ffffff;

    pointer-events:
        auto;
}


/* =========================================
   FLOATING CART
========================================= */

.beano-floating-cart {

    position: fixed;

    left: 20px;
    bottom: 24px;

    width: 104px;
    height: 84px;
    border-radius: 24px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: #07552f;

    color: #ffffff;

    text-decoration: none;

    z-index: 99999;

    box-shadow:
        7px 8px 12px rgba(0, 0, 0, .28);

    transition:
        transform .25s ease,
        box-shadow .25s ease;

}


/* Cart icon */

.beano-floating-cart i {

    font-size: 30px;

}


/* Item count badge */

.beano-floating-cart__badge {

    position: absolute;

    top: 7px;
    right: 18px;

    width: 25px;
    height: 25px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: #e62d2d;

    color: #ffffff;

    border-radius: 50%;

    border: 2px solid #ffffff;

    font-size: 13px;
    font-weight: 700;

    line-height: 1;

}


/* Small tap feedback */

.beano-floating-cart:active {

    transform: scale(.94);

}


/* Hidden until cart has an item */

.beano-floating-cart.is-hidden {

    display: none;

}


/* Little arrival animation */

.beano-floating-cart.beano-floating-cart--show {

    animation:
        beanoFloatingCartShow .45s ease both;

}


@keyframes beanoFloatingCartShow {

    0% {

        opacity: 0;

        transform:
            translateY(25px)
            scale(.85);

    }

    70% {

        opacity: 1;

        transform:
            translateY(-4px)
            scale(1.03);

    }

    100% {

        opacity: 1;

        transform:
            translateY(0)
            scale(1);

    }

}


/* =========================================
   DESKTOP CART LAYOUT
   Desktop only. Existing mobile CSS untouched.
========================================= */

@media screen and (min-width: 901px) {

    /* Main page */
    .beano-cart-page {
        min-height: 100vh;
        padding: 36px 24px 70px;
        box-sizing: border-box;
    }

    /* Header */
    .beano-cart-header {
        width: 100%;
        max-width: 1100px;
        min-height: 125px;
        margin: 0 auto 28px;
    }

    .beano-cart-back {
        top: 18px;
        font-size: 14px;
    }

    .beano-cart-logo-image {
        width: 140px;
    }

    .beano-cart-title {
        font-size: 48px;
        letter-spacing: -2px;
    }

    /* Centered cart layout */
    .beano-cart-layout {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 22px;

        width: 100%;
        max-width: 1050px;
        margin: 0 auto;
        align-items: start;
    }

    /* Product list: one large outer card */
    .beano-cart-items-area {
        width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    .beano-cart-items {
        display: flex;
        flex-direction: column;
        gap: 12px;

        width: 100%;
        padding: 18px;

        background: #fffdf7;
        border: 1px solid rgba(18, 59, 37, 0.09);
        border-radius: 26px;

        box-shadow: 0 14px 36px rgba(18, 59, 37, 0.08);
        box-sizing: border-box;
    }

    /* Individual product rows */
    .beano-cart-item {
        grid-template-columns: 100px minmax(0, 1fr);
        gap: 18px;

        padding: 16px;
        border-radius: 18px;
        box-shadow: 0 4px 14px rgba(18, 59, 37, 0.04);
    }

    /* Product image */
    .beano-cart-item__image {
        width: 100px;
        height: 115px;
        border-radius: 14px;
    }

    .beano-cart-item__details {
        padding: 4px 32px 4px 0;
    }

    .beano-cart-item__name {
        font-size: 16px;
        line-height: 1.3;
    }

    .beano-cart-item__id {
        font-size: 10px;
    }

    .beano-cart-item__price {
        margin-top: 10px;
        font-size: 16px;
    }

    .beano-cart-item__remove {
        top: 12px;
        right: 12px;
    }

    .beano-cart-item__quantity {
        gap: 10px;
        margin-top: 12px;
    }

    .beano-cart-item__qty-button {
        width: 30px;
        height: 30px;
    }

    /* Order summary beneath the product card */
    .beano-cart-summary {
        width: 100%;
        margin-top: 0;
        padding: 28px;

        border-radius: 24px;
        box-sizing: border-box;
    }

    .beano-cart-summary__heading {
        margin-bottom: 28px;
        font-size: 10px;
    }

    .beano-cart-summary__row span {
        font-size: 15px;
    }

    .beano-cart-summary__row strong {
        font-size: 18px;
    }

    .beano-cart-summary__total span {
        font-size: 20px;
    }

    .beano-cart-summary__total strong {
        font-size: 28px;
    }

    .beano-cart-checkout {
        min-height: 60px;
        margin-top: 24px;
        padding: 0 20px;
        font-size: 15px;
    }

    /* Empty-cart state */
    .beano-cart-empty {
        min-height: 340px;
        padding: 30px;
        box-sizing: border-box;
        background: #fffdf7;
        border-radius: 26px;
        box-shadow: 0 14px 36px rgba(18, 59, 37, 0.08);
    }
}
