﻿.cart-overlay{

    position:fixed;

    inset:0;

    background:rgba(0,0,0,.45);

    backdrop-filter:blur(2px);

    opacity:0;

    visibility:hidden;

    transition:.30s ease;

    z-index:9998;

}

.cart-overlay.active{

    opacity:1;

    visibility:visible;

}

/*==============================
DRAWER
==============================*/

.cart-drawer{

    position:fixed;

    top:0;

    right:-100%;

    width:420px;

    max-width:100%;

    height:100vh;

    background:#fff;

    overflow-y:auto;

    overflow-x:hidden;

    -webkit-overflow-scrolling: touch;

    display:block;

    transition:right .35s ease;

    z-index:9999;

}

.cart-drawer.active{

    right:0;

}

/*==============================
HEADER
==============================*/

.cart-header{

    flex-shrink:0;

    display:flex;

    justify-content:space-between;

    align-items:center;

    padding:20px;

    padding-top:calc(20px + env(safe-area-inset-top));

    background:#fff;

    border-bottom:1px solid #ececec;

}

.cart-header h2{

    font-size:24px;

    font-weight:700;

    color:#222;

}

.cart-header button{

    width:42px;

    height:42px;

    border:none;

    border-radius:12px;

    background:#f5f5f5;

    cursor:pointer;

    transition:.25s;

    font-size:18px;

}

.cart-header button:hover{

    background:#ececec;

}

/*==============================
SCROLL AREA
==============================*/

.cart-items{

    padding:18px;

    background:#fafafa;

    overflow-x:hidden;

    scroll-behavior:smooth;

}

/*==============================
EMPTY CART
==============================*/

.empty-cart{

    height:100%;

    display:flex;

    flex-direction:column;

    justify-content:center;

    align-items:center;

    text-align:center;

    color:#777;

}

.empty-cart h3{

    font-size:24px;

    margin-bottom:10px;

    color:#222;

}

.empty-cart p{

    font-size:15px;

}

/*==============================
FOOTER
==============================*/

.cart-footer{

    padding:20px;

    padding-bottom:calc(40px + env(safe-area-inset-bottom));

    background:#fff;

}

/*==============================
TOTAL
==============================*/

.cart-total{

    display:flex;

    justify-content:space-between;

    align-items:center;

    margin-bottom:18px;

}

.cart-total span{

    font-size:17px;

    color:#666;

}

.cart-total strong{

    font-size:26px;

    color:var(--primary);

    font-weight:700;

}

/*==============================
SUBTOTAL & OFFER ROWS (new, additive only)
==============================*/

.cart-subtotal-row{

    margin-bottom:6px;

}

.cart-subtotal-row span,
.cart-subtotal-row strong{

    font-size:15px;

    color:#888;

    font-weight:500;

}

.cart-discount-row{

    margin-bottom:6px;

}

.cart-discount-row span,
.cart-discount-row strong{

    font-size:15px;

    color:#1aa15e;

    font-weight:600;

}

.cart-bogo-row{

    margin-bottom:6px;

}

.cart-bogo-row span,
.cart-bogo-row strong{

    font-size:15px;

    color:var(--primary);

    font-weight:600;

}

.cart-item-free-tag{

    display:inline-block;

    background:#fff1e2;

    color:var(--primary);

    font-size:11px;

    font-weight:700;

    padding:2px 8px;

    border-radius:20px;

    margin-top:4px;

}
/*==========================================
PART 2
CART ITEMS
==========================================*/

.cart-item{

    display:flex;

    align-items:center;

    gap:14px;

    background:#fff;

    border-radius:18px;

    padding:12px;

    margin-bottom:14px;

    box-shadow:0 3px 10px rgba(0,0,0,.05);

}

.cart-item:last-child{

    margin-bottom:0;

}

/*==============================
IMAGE
==============================*/

.cart-item img{

    width:82px;

    height:82px;

    border-radius:16px;

    object-fit:cover;

    background:#f4f4f4;

    flex-shrink:0;

}

/*==============================
INFO
==============================*/

.cart-item-info{

    flex:1;

    display:flex;

    flex-direction:column;

    justify-content:center;

    min-width:0;

}

.cart-item-info strong{

    font-size:17px;

    color:#222;

    margin-bottom:6px;

    white-space:nowrap;

    overflow:hidden;

    text-overflow:ellipsis;

}

.cart-item-info small{

    font-size:15px;

    color:var(--primary);

    font-weight:600;

    margin-bottom:12px;

}

/*==============================
QUANTITY
==============================*/

.cart-item-actions{

    display:flex;

    align-items:center;

    gap:10px;

}

.cart-item-actions button{

    width:34px;

    height:34px;

    border:none;

    border-radius:10px;

    background:var(--primary);

    color:#fff;

    font-size:18px;

    font-weight:700;

    cursor:pointer;

    transition:.25s;

}

.cart-item-actions button:hover{

    background:#e96d00;

    transform:scale(1.05);

}

.cart-item-actions button:active{

    transform:scale(.95);

}

.cart-item-actions span{

    min-width:22px;

    text-align:center;

    font-size:16px;

    font-weight:700;

    color:#222;

}
/*==========================================
PART 3
CHECKOUT
==========================================*/

.checkout-form{

    display:flex;

    flex-direction:column;

    gap:14px;

    margin-top:18px;

}

.checkout-form input,
.checkout-form textarea{

    width:100%;

    padding:14px 16px;

    border:2px solid #eeeeee;

    border-radius:14px;

    background:#ffffff;

    font-size:15px;

    font-family:inherit;

    transition:.25s;

    outline:none;

    resize:none;

}

.checkout-form input::placeholder,
.checkout-form textarea::placeholder{

    color:#999;

}

.checkout-form input:focus,
.checkout-form textarea:focus{

    border-color:var(--primary);

    box-shadow:0 0 0 4px rgba(255,122,0,.12);

}

.checkout-form textarea{

    min-height:90px;

    max-height:140px;

}

.location-status{

    margin-top:2px;

}

.location-status:empty{

    display:none;

}

/* Idle â€” tap-to-enable CTA */

.location-cta{

    width:100%;

    display:flex;

    align-items:center;

    gap:10px;

    background:#fff8f0;

    border:1px dashed #ffcc99;

    border-radius:12px;

    padding:12px 14px;

    font-size:13px;

    font-weight:600;

    color:var(--primary);

    cursor:pointer;

    text-align:left;

}

.location-cta-icon{

    font-size:16px;

    flex-shrink:0;

}

/* Detecting â€” spinner row */

.location-status--detecting{

    display:flex;

    align-items:center;

    gap:10px;

    padding:12px 14px;

    font-size:13px;

    color:#888;

    background:#fafaf8;

    border-radius:12px;

}

.location-spinner{

    width:14px;

    height:14px;

    border-radius:50%;

    border:2px solid #ddd;

    border-top-color:var(--primary);

    flex-shrink:0;

    animation:location-spin .7s linear infinite;

}

@keyframes location-spin{

    to{ transform:rotate(360deg); }

}

/* Detected â€” success card */

.location-status--detected{

    display:flex;

    align-items:center;

    gap:10px;

    padding:12px 14px;

    background:#eefaf1;

    border:1px solid #cdeed9;

    border-radius:12px;

}

.location-status-icon{

    width:22px;

    height:22px;

    min-width:22px;

    border-radius:50%;

    display:flex;

    align-items:center;

    justify-content:center;

    font-size:12px;

    font-weight:700;

    color:#fff;

}

.location-status-icon--ok{

    background:#22a35a;

}

.location-status-icon--warn{

    background:#e0782a;

}

.location-status-text{

    flex:1;

    min-width:0;

    display:flex;

    flex-direction:column;

    gap:2px;

}

.location-status-text strong{

    font-size:13px;

    color:#1f3b2c;

    overflow:hidden;

    text-overflow:ellipsis;

    white-space:nowrap;

}

.location-status--blocked .location-status-text strong{

    color:#7a3418;

}

.location-status-text small{

    font-size:11.5px;

    color:#4c7a5f;

    line-height:1.35;

}

.location-status--blocked .location-status-text small{

    color:#9a5a30;

}

.location-change-btn{

    background:none;

    border:none;

    padding:0;

    font-size:12px;

    font-weight:700;

    color:var(--primary);

    cursor:pointer;

    text-decoration:underline;

    flex-shrink:0;

}

/* Blocked â€” warning card */

.location-status--blocked{

    display:flex;

    align-items:flex-start;

    gap:10px;

    padding:12px 14px;

    background:#fff4ec;

    border:1px solid #ffdcc0;

    border-radius:12px;

}

/* Saved address chips */

.saved-address-chips{

    display:flex;

    flex-wrap:wrap;

    gap:8px;

    margin-bottom:2px;

}

.saved-address-chips:empty{

    display:none;

    margin:0;

}

.saved-address-chip{

    display:flex;

    align-items:center;

    gap:6px;

    background:#fff;

    border:1.5px solid #eee;

    border-radius:999px;

    padding:7px 14px;

    font-size:12.5px;

    font-weight:600;

    color:#2c2c2a;

    cursor:pointer;

}

.saved-address-chip:active{

    background:#fff8f0;

    border-color:var(--primary);

}

.saved-address-chip .chip-remove{

    color:#bbb;

    font-size:14px;

    line-height:1;

    padding:0 0 0 2px;

}

/* Location action buttons (Choose on Map / Save this address) â€”
   styled as a proper secondary button pair, matching the app's
   existing card/icon language instead of floating text links. */

.location-actions{

    display:flex;

    gap:10px;

    margin-top:2px;

}

.location-action-btn{

    flex:1;

    display:flex;

    align-items:center;

    justify-content:center;

    gap:7px;

    background:#fff;

    border:1.5px solid #eee;

    border-radius:12px;

    padding:11px 10px;

    font-size:12.5px;

    font-weight:600;

    color:#2c2c2a;

    cursor:pointer;

    transition:border-color .15s, background .15s;

}

.location-action-btn svg{

    width:15px;

    height:15px;

    stroke:var(--primary);

    flex-shrink:0;

}

.location-action-btn:active{

    background:#fff8f0;

    border-color:#ffcc99;

}

/* Map modal (Choose on Map) */

.map-modal{

    display:none;

    position:fixed;

    top:50%;

    left:50%;

    transform:translate(-50%,-50%);

    width:min(92vw,480px);

    max-height:88vh;

    background:#fff;

    border-radius:18px;

    z-index:10001;

    padding:20px;

    display:none;

    flex-direction:column;

    gap:12px;

    box-shadow:0 20px 60px rgba(0,0,0,.25);

}

.map-modal.active{

    display:flex;

}

.map-modal-header{

    display:flex;

    align-items:center;

    justify-content:space-between;

}

.map-modal-header h2{

    font-size:18px;

}

.map-search-row{

    display:flex;

    gap:8px;

}

.map-search-row input{

    flex:1;

    padding:11px 14px;

    border:1px solid #ddd;

    border-radius:10px;

    font-size:14px;

}

.map-search-row button{

    background:#2c2c2a;

    color:#fff;

    border:none;

    border-radius:10px;

    padding:0 16px;

    font-size:13px;

    font-weight:600;

    cursor:pointer;

}

.map-container{

    width:100%;

    height:280px;

    border-radius:14px;

    overflow:hidden;

    background:#eee;

}

.map-hint{

    font-size:12px;

    color:#888;

    text-align:center;

}

.map-confirm-btn{

    background:var(--primary);

    color:#fff;

    border:none;

    border-radius:12px;

    padding:14px;

    font-size:15px;

    font-weight:600;

    cursor:pointer;

}

#mapOverlay.active{

    z-index:10000;

}

.checkout-name-phone-row{

    display:flex;

    gap:10px;

}

.checkout-name-phone-row input{

    flex:1;

    min-width:0;

}

.checkout-form input[readonly]{

    background:#fafaf8;

    color:#555;

    border-color:#eeeeee;

}

.add-note-toggle{

    align-self:flex-start;

    background:none;

    border:none;

    padding:0;

    font-size:13px;

    font-weight:600;

    color:var(--primary);

    cursor:pointer;

}
@media (max-width:768px){

    .cart-footer{

        padding-bottom:80px;

    }

}
/*==============================
PLACE ORDER BUTTON
==============================*/

#placeOrder{

    width:100%;

    height:56px;

    border:none;

    border-radius:16px;

    background:linear-gradient(135deg,#ff8a00,#ff6b00);

    color:#fff;

    font-size:18px;

    font-weight:700;

    cursor:pointer;

    transition:.25s;

    margin-top:6px;

    box-shadow:0 8px 20px rgba(255,122,0,.25);

}

#placeOrder:hover{

    transform:translateY(-2px);

    box-shadow:0 12px 24px rgba(255,122,0,.35);

}

#placeOrder:active{

    transform:scale(.98);

}

#placeOrder:disabled{

    opacity:.7;

    cursor:not-allowed;

    transform:none;

    box-shadow:none;

}

/*==============================
SCROLLBAR
==============================*/

.cart-items::-webkit-scrollbar{

    width:6px;

}

.cart-items::-webkit-scrollbar-thumb{

    background:#d7d7d7;

    border-radius:10px;

}

.cart-items::-webkit-scrollbar-thumb:hover{

    background:#bfbfbf;

}
/*==========================================
PART 4
RESPONSIVE
==========================================*/

/* Tablet */

@media (max-width:991px){

    .cart-drawer{

        width:420px;

    }

}

/* Mobile */

@media (max-width:768px){

    .cart-drawer{

        width:100%;

        max-width:100%;

        right:-100%;

        border-radius:0;

    }

    .cart-drawer.active{

        right:0;

    }

    .cart-header{

        padding:18px;

    }

    .cart-header h2{

        font-size:22px;

    }

    .cart-items{

        padding:16px;

    }

    .cart-item{

        gap:12px;

        padding:12px;

    }

    .cart-item img{

        width:72px;

        height:72px;

    }

    .cart-item-info strong{

        font-size:16px;

    }

    .cart-item-info small{

        font-size:14px;

    }

    .cart-item-actions button{

        width:32px;

        height:32px;

        font-size:17px;

    }

    .checkout-form input,

    .checkout-form textarea{

        font-size:15px;

    }

}

/* Small Phones */

@media (max-width:480px){

    .cart-item{

        align-items:flex-start;

    }

    .cart-item img{

        width:65px;

        height:65px;

    }

    .cart-item-info{

        width:100%;

    }

    .cart-item-actions{

        margin-top:8px;

    }

    .cart-total strong{

        font-size:22px;

    }

    #placeOrder{

        height:54px;

        font-size:17px;

    }

}

/*==========================================
BOTTOM CART
==========================================*/

.bottom-cart{

    position:fixed;

    left:12px;

    right:12px;

    bottom:12px;

    height:70px;

    background:linear-gradient(135deg,#ff8a00,#ff6b00);

    border-radius:20px;

    display:flex;

    align-items:center;

    justify-content:space-between;

    padding:0 18px;

    color:#fff;

    box-shadow:0 12px 35px rgba(255,122,0,.30);

    z-index:9997;

    transition:.25s;

}

.bottom-cart.hidden{

    opacity:0;

    visibility:hidden;

    transform:translateY(100px);

}

.bottom-cart:not(.hidden){

    opacity:1;

    visibility:visible;

    transform:translateY(0);

}

.cart-left strong{

    display:block;

    font-size:18px;

}

.cart-left small{

    font-size:13px;

    opacity:.9;

}

.cart-right{

    display:flex;

    align-items:center;

    gap:15px;

}

.cart-right strong{

    font-size:20px;

    font-weight:700;

}

.cart-right button{

    width:42px;

    height:42px;

    border:none;

    border-radius:50%;

    background:#fff;

    color:var(--primary);

    cursor:pointer;

    font-size:22px;

    transition:.25s;

}

.cart-right button:hover{

    transform:scale(1.08);

}

/*==========================================
SMOOTH ANIMATIONS
==========================================*/

.cart-item,
.checkout-form input,
.checkout-form textarea,
#placeOrder,
.cart-item-actions button{

    transition:all .25s ease;

}

*{

    -webkit-tap-highlight-color:transparent;

}
/*==================================================
ORDER TYPE
==================================================*/

.order-type{
    margin:8px 0 4px;
}

.order-type-title{
    font-size:22px;
    font-weight:700;
    color:#222;
    margin-bottom:16px;
}

.order-options{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:14px;
}

.order-card{

    position:relative;

    padding:22px 18px;

    border:2px solid #ececec;

    border-radius:22px;

    background:#fff;

    cursor:pointer;

    transition:.30s;

    text-align:center;

}

.order-card:hover{

    transform:translateY(-3px);

    border-color:#ffb86a;

}

.order-card.active{

    border-color:var(--primary);

    background:#fff8f2;

    box-shadow:0 12px 28px rgba(255,122,0,.15);

}

.order-icon{

    width:70px;

    height:70px;

    margin:auto;

    margin-bottom:16px;

    border-radius:50%;

    background:#fff2e5;

    display:flex;

    align-items:center;

    justify-content:center;

    color:var(--primary);

}

.order-icon svg{

    width:34px;

    height:34px;

    stroke-width:2.2;

}

.order-card.active .order-icon{

    background:#ffe4c7;

}

.order-body h4{

    margin:0;

    font-size:24px;

    color:#222;

}

.order-body p{

    margin-top:10px;

    color:#666;

    font-size:15px;

    line-height:1.5;

}

.order-check{

    position:absolute;

    top:14px;

    right:14px;

    width:30px;

    height:30px;

    border-radius:50%;

    background:var(--primary);

    color:#fff;

    display:none;

    align-items:center;

    justify-content:center;

    font-weight:bold;

}

.order-card.active .order-check{

    display:flex;

}

/*==================================================
SHOP LOCATION
==================================================*/

.shop-location-card{

    margin-top:14px;

    background:#fff9f2;

    border:2px solid #ffe1bf;

    border-radius:20px;

    padding:20px;

}

.shop-location-card{

    margin-top:14px;

    background:#fff9f2;

    border:2px solid #ffe1bf;

    border-radius:20px;

    padding:20px;

}

/* Heading */

.shop-location-card h4{

    display:flex;

    align-items:center;

    gap:10px;

    margin:0 0 12px;

    color:var(--primary);

    font-size:22px;

    font-weight:700;

}

.shop-location-card h4 svg{

    width:22px;

    height:22px;

    stroke-width:2.2;

}

/* Address */

.shop-location-card p{

    margin:0;

    color:#444;

    line-height:1.8;

}

/* Opening Time */

.shop-time{

    display:flex;

    align-items:center;

    gap:10px;

    margin-top:14px;

    color:#666;

    font-size:15px;

}

.shop-time svg{

    width:18px;

    height:18px;

    stroke-width:2.2;

    flex-shrink:0;

}

/* Dine Note */

.dine-note{

    display:flex;

    align-items:flex-start;

    gap:10px;

    margin-top:18px;

    padding:14px;

    border-radius:12px;

    background:#fff;

    border-left:4px solid var(--primary);

}

.dine-note svg{

    width:20px;

    height:20px;

    color:var(--primary);

    stroke-width:2.2;

    flex-shrink:0;

    margin-top:2px;

}

.dine-note span{

    line-height:1.6;

}

/*==================================================
MOBILE
==================================================*/

@media(max-width:600px){

.order-options{

grid-template-columns:1fr 1fr;

gap:10px;

}

.order-card{

padding:14px 10px;

border-radius:18px;

}

.order-icon{

width:46px;

height:46px;

margin-bottom:10px;

}

.order-icon svg{

width:22px;

height:22px;

}

.order-body h4{

font-size:15px;

line-height:1.25;

}

.order-body p{

margin-top:5px;

font-size:11.5px;

line-height:1.35;

}

.order-check{

top:8px;

right:8px;

width:22px;

height:22px;

font-size:12px;

}

}

@media(max-width:360px){

.order-body p{

display:none;

}

.order-icon{

margin-bottom:6px;

}

}