
/* =========================
   🔥 GLOBAL PERFORMANCE FIX
========================= */

*,
*::before,
*::after{
    box-sizing: border-box;
}

/* =========================
   1. BASIC RESET
========================= */
body {
    margin: 0;
    padding: 0;
    font-family: "Inter", sans-serif;
    overflow-x: hidden;
    overflow-y: auto;
    background: linear-gradient(180deg,#f8f9fa,#eef1f4);
}

html, body {
    touch-action: manipulation;
}

/* =========================
   2. TYPOGRAPHY
========================= */
h1,h2,h3,h4,h5,h6 {
    font-weight: 600;
}

/* =========================
   3. COLORS
========================= */
a {
    color: #f15a00;   /* 🔥 updated */
    text-decoration: none;
}

.text-primary {
    color: #f15a00 !important;  /* 🔥 updated */
}

/* =========================
   4. BUTTONS
========================= */
.btn-primary {
    background: linear-gradient(135deg, #ff7a1a, #f15a00);  /* 🔥 updated */
    border: none;
    color: #fff;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #f15a00, #d84300);  /* 🔥 updated */
}

/* =========================
   5. SEARCH MODAL
========================= */
#searchModal .modal-header{
    border-bottom: none;
    padding: 8px 10px;
}

#searchModal .search-form{
    display: flex;
    align-items: center;
    gap: 10px;
    background: #ffffff;
    border-radius: 14px;
    padding: 8px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
    width: 92%;
	margin: 0 auto;
}

#searchModal .closeBtn{
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: transparent;
    display:flex;
    align-items:center;
    justify-content:center;
}

#searchModal .search-input{
    flex: 1;
    height: 48px;
    border: none;
    background: #f3f3f3;
    border-radius: 6px;
    padding: 0 12px;
    font-size: 15px;
    outline: none;
}

#searchModal .btn-primary{
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#f15a00;   /* 🔥 updated */
    border:none;
	 margin-left: 10px; 
}

#searchModal{
    background: #f9f9f9;
    z-index: 99999;
}

/* =========================
   🔥 COMMON PAGE CONTAINER
========================= */
.page-container{
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* CENTER BLOCK (ALL PAGES USE) */
.center-box{
    max-width: 420px;
    width: 100%;
    margin: 0 auto;
}


.desktop-spec{
    display:block;
    font-size:14px;
    margin-top:6px;
    color:#444;
}

.desktop-spec b{
    font-weight:600;
    color:#222;
}




/* =========================
   🔥 CART PREMIUM UPGRADE
========================= */

/* MAIN LAYOUT */
.cart-wrapper{
    width: 100%;
    max-width: 1310px;
    margin: 0 auto;
    display: flex;
    gap: 30px;
    align-items: flex-start; /* 🔥 TOP ALIGN FIX */
    padding: 40px 15px;
}

/* LEFT SIDE */

.cart-box{
    flex: 2.5;
    background: #ffffff;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.06);
	border: 1px solid #f1f1f1;
	    width: 100%;

}

/* RIGHT SIDE */
.cart-summary{
    flex: 1;
	 position: relative;
}


/* TABLE */
.cart-table{
    margin-bottom: 0 !important;
	vertical-align: middle;
	 width: 100%;
}

.cart-table th{
    font-size: 15px;
    color: #777;
    font-weight: 600;
    border-bottom: 1px solid #eee !important;
    white-space: nowrap;

}

.cart-table td{
    padding: 20px 12px !important;
    border-bottom: 1px solid #f5f5f5 !important;
}


/* 🔥 PERFECT COLUMN ALIGNMENT */
.cart-table th,
.cart-table td{
    text-align: center;
    vertical-align: middle;
}


/* ROW HOVER */
.cart-row:hover{
    background: #fff5ef;
	    transition: all 0.2s ease;

}

/* PRODUCT IMAGE */
.product-img{
    width: 65px !important;
    height: 65px !important;
    max-width: none !important;
    border-radius: 10px;
    border: 1px solid #eee;
    background: #fff;
}

/* PRODUCT NAME */
.cart-table b a{
    font-size: 15px;
    color: #222;
}

.cart-table b a:hover{
    color: #f15a00;   /* 🔥 updated */
}

/* =========================
   QTY BOX
========================= */
.qty-box{
    display: flex;
    align-items: center;
    gap: 6px;
}

.qty-box button{
    width: 32px;
    height: 32px;
    font-weight: bold;
    border-radius: 8px !important;
    border: none !important;

    background: #f15a00 !important;
    color: #fff;   /* 🔥 IMPORTANT */

    display:flex;
    align-items:center;
    justify-content:center;
}

.qty-box button:hover{
    background: #d84300 !important;
    color: #fff;
    border-color: #f15a00 !important; /* 🔥 updated */
}

.qty-input{
    width: 45px;
    height: 30px;
    text-align: center;
    font-weight: 600;
}

/* =========================
   PRICE COLORS
========================= */
.row-total{
    color: #444 !important;
    font-weight: 700;
    font-size: 16px;
}



/* DELETE ICON */
.delete-item{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #e53935;
	cursor: pointer;
    font-size: 18px;
}


.delete-item:hover{
    transform: scale(1.2);
}

.cart-table td:last-child{
    text-align: center;
    vertical-align: middle;
      width: 60px;
	  
}

.cart-table td:nth-child(2),
.cart-table td:nth-child(3),
.cart-table td:nth-child(4),
.cart-table td:nth-child(5){
    text-align: center;
    white-space: nowrap;
}

.cart-table td:nth-child(2),
.extra-charge{
    font-weight: 500;
    color: #555;
    font-size: 15px;
}

.cart-table td:first-child{
    width: 40%;
}

.cart-table td:first-child,
.cart-table th:first-child{
    text-align: left;
}



.product-details{
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.spec-list div{
    font-size: 14px;
    line-height: 1.4;
}


/* =========================
   TOTAL BOX (RIGHT SIDE)
========================= */
.totals-box{
    background: #ffffff;
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.06);
    position: sticky;
    top: 130px;
	width: 100%;
	border: 1px solid #f1f1f1;
    transition: all 0.3s ease;

}

/* TITLE */
.totals-box h5{
    margin-bottom: 15px;
	font-size: 20px;
    font-weight: 700;
    color: #444 !important;
}

/* ROW */
.total-row{
    display: flex;
    justify-content: space-between;
    font-size: 16px;
	font-weight: 500;
    margin-bottom: 8px;
	
}

/* GRAND */
.total-row.text-warning{
    font-size: 18px;
    font-weight: 700;
    color: #444 !important;
}

#grandTotal{
    font-size: 20px;
    font-weight: 800;
    color: #2e7d32;
}

/* CHECKOUT BUTTON */
.checkout-btn{
    margin-top: 15px;
    padding: 12px;
    border-radius: 30px !important;
    font-weight: 700;
    background: linear-gradient(135deg,#ff7a1a,#d84300) !important;  /* 🔥 updated */
    transition: 0.3s;
	display: block;
	width: 100%;
	text-align: center;
	color: #fff;

	

}

.checkout-btn:hover{
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(0,0,0,0.2);
}

/* =========================
   EMPTY CART (UPGRADE)
========================= */

.empty-cart-box{
    max-width: 420px;
    width: 100%;
    background: linear-gradient(
        180deg,
        rgba(241,90,0,0.04),   /* 🔥 updated */
        rgba(216,67,0,0.08)    /* 🔥 updated */
    );
    padding: 35px 25px;
    border-radius: 18px;
    text-align: center;
    box-shadow: 0 15px 40px rgba(0,0,0,0.08);
    border: 1px solid #f1f1f1;
}

.empty-icon{
    width: 75px;
    height: 75px;
    margin: 0 auto 18px;
    background: linear-gradient(135deg,#ff7a1a,#f15a00);  /* 🔥 updated */
    border-radius: 50%;
    display:flex;
    align-items:center;
    justify-content:center;
}

.empty-icon i{
    color:#fff;
    font-size:28px;
}

.empty-btn{
    display: inline-block;
    margin-top: 15px;
    padding: 12px 22px;
    border-radius: 30px;
    font-weight: 600;
    background: linear-gradient(135deg,#ff7a1a,#f15a00);  /* 🔥 updated */
    color: #fff;
    transition: 0.3s;
}

.empty-btn:hover{
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

/* 🔥 EMPTY CART CENTER FIX */
.empty-cart{
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}



/* TABS FIX */
.tabs-container{
    max-width:1200px;
    margin:30px auto;
	    margin-bottom:60px;  /* ✅ add space before footer */

    
}

.tabs{
    display:flex;
    gap:20px;
    border-bottom:1px solid #ddd;
    margin-bottom:15px;
}

.tab{
    padding:10px 15px;
    cursor:pointer;
    font-weight:500;
    color:#555;
    border-bottom:2px solid transparent;
}

.tab.active{
    color:#ff6a00;
    border-bottom:2px solid #ff6a00;
}

/* 🔥 MOST IMPORTANT */
.tab-content{
    display:none;   /* ❌ hide all by default */
}

.tab-content.active{
    display:block;  /* ✅ only active visible */
}














/* 🔴 INPUT ERROR */
.input-error{
    border:1px solid #ff3b3b !important;
    background:#fff5f5 !important;
}

/* 🔴 SELECT */
select.input-error{
    border:1px solid #ff3b3b !important;
}

/* 🔴 GROUP (payment / section) */
.section-box.input-error,
.payment-box.input-error{
    border:1px solid #ff3b3b !important;
    border-radius:10px;
    padding:10px;
}




/* =========================
   🔥 COMMON UI SYSTEM
========================= */

.common-card{
    background:#fff;
    border-radius:14px;
    padding:15px;
    box-shadow:0 8px 25px rgba(0,0,0,0.05);
    transition:0.3s;
}

.common-card:hover{
    transform: translateY(-5px);
}

/* BUTTON SYSTEM */
.btn-orange{
    background: linear-gradient(135deg,#ff7a1a,#f15a00);   /* 🔥 updated */
    color:#fff;
    border:none;
    border-radius:30px;
    padding:10px 18px;
    font-weight:600;
}

.btn-orange:hover{
    background: linear-gradient(135deg,#f15a00,#d84300);   /* 🔥 updated */
    transform: translateY(-2px);
    box-shadow:0 6px 15px rgba(0,0,0,0.2);
}

/* SCROLLBAR */
::-webkit-scrollbar{
    width:6px;
}

::-webkit-scrollbar-thumb{
    background:#d84300;   /* 🔥 updated */
    border-radius:10px;
}

/* =========================
   🔥 GLOBAL LAYER FIX
========================= */

.main-header,
.mobile-header{
    position: relative;
    z-index: 9999;
}

.popup-alert{
    z-index: 9998;
}

.main-content{
    position: relative;
    z-index: 1;
    padding-top: 120px; /* or adjust */
    padding-bottom: 60px; /* 🔥 footer gap fix */
}

/* =========================
   🔥 WHATSAPP FINAL FIX
========================= */

.wa-popup{
    position: fixed;
    bottom: 90px;
    right: 20px;
    z-index: 9997;

    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all 0.3s ease;
}

.wa-popup.active{
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.wa-popup-box{
    pointer-events: auto;
}

.wa-floating-btn{
    pointer-events: auto;
    z-index: 9998;
}







/* =========================
   MOBILE FIX
========================= */
@media(max-width:768px){

.product-img{
    width: 55px !important;
    height: 55px !important;
}

body{
    padding-bottom: 60px;
}

}




















/* =========================
   🔥 FINAL MOBILE CART FIX
========================= */

@media(max-width:768px){

/* ===== LAYOUT FIX ===== */
.cart-wrapper{
    flex-direction: column;
    gap: 15px;
    padding: 20px 10px;
}

.cart-box,
.cart-summary{
    width: 100%;
    margin-top: 30px !important;
    margin-bottom: 0px !important;
}

/* ===== TABLE → CARD ===== */
.cart-table thead{
    display: none;
}

.cart-table,
.cart-table tbody,
.cart-table tr,
.cart-table td{
    display: block;
    width: 100%;
}

/* ===== CARD STYLE ===== */
.cart-table tr{
    background: #ffffff;
    border-radius: 14px;
    padding: 15px;
    margin-bottom: 15px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.06);
    border: 1px solid #f1f1f1;
}

/* ===== PRODUCT SECTION ===== */
.cart-table td:first-child{
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
    width: 100% !important;
}

.cart-table td:first-child > div{
    gap: 10px;
}

/* IMAGE */
.product-img{
    width: 60px !important;
    height: 60px !important;
    flex-shrink: 0;
}

/* DETAILS */
.product-details{
    width: 100%;
}

/* TEXT WRAP */
.spec-list div{
    font-size: 15px !important;
    line-height: 1.5;
    word-break: break-word;
}

/* ===== COMMON TD ===== */
.cart-table td{
    text-align: left !important;
    padding: 6px 0 !important;
    border: none !important;
    width: 100%;
    font-size: 16px !important;
}

/* =========================
   🔥 ROW ALIGNMENT
========================= */
.cart-table td:nth-child(2),
.cart-table td:nth-child(3),
.cart-table td:nth-child(4),
.cart-table td:nth-child(5){
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* =========================
   🔥 LABELS
========================= */
.cart-table td:nth-child(2)::before{
    content: "Base Price:";
    font-weight: 600;
    font-size: 16px !important;
}

.cart-table td:nth-child(3)::before{
    content: "Quantity:";
    font-weight: 600;
    font-size: 16px !important;
    color: #444;
}

.cart-table td:nth-child(4)::before{
    content: "Extra Charges:";
    font-weight: 600;
    font-size: 16px !important;
	color: #444;
}

.cart-table td:nth-child(5)::before{
    content: "Total:";
    font-weight: 600;
    font-size: 18px !important;
	margin-top: 10px;
}



.cart-table td:nth-child(6)::before{
    content: "Action:";
    font-weight: 600;
    font-size: 16px !important;

}


/* =========================
   🔥 QTY ALIGN
========================= */
.qty-box{
    width: 100%;
    display: flex;
    justify-content: flex-end;
    margin-top: 6px;
    margin-bottom: 10px;
}

/* =========================
   🔥 PRICE STYLE
========================= */
.row-total{
    font-size: 20px;
    font-weight: 700;
}

.extra-charge{
    font-weight: 600;
    color: #e65100;
}

/* =========================
   🔥 DELETE BUTTON
========================= */
    .cart-table td:last-child{
        display: flex !important;
        justify-content: flex-end !important;  /* 🔥 MAIN FIX */
        align-items: center;
        width: 100%;
        padding-top: 10px !important;
    }


 .cart-table td:last-child::before{
        margin-right: auto;
    }



 .action-cell{
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}
	
	




/* =========================
   🔥 SMALL FIXES
========================= */
.cart-table b a{
    font-size: 18px;
}

.totals-box{
    margin-bottom: -40px;
}





.empty-cart{
        padding: 20px 15px;   /* 🔥 left/right gap */
    }

    .empty-cart-box{
        width: 100%;
        max-width: 350px;     /* 🔥 control width */
        margin: 110px auto;       /* 🔥 center */
        padding: 30px 20px;   /* 🔥 inner spacing */

        border-radius: 16px;
    }

    /* 🔥 TEXT SIZE INCREASE */
    .empty-cart-box h3{
        font-size: 20px;
        font-weight: 700;
    }

    .empty-cart-box p{
        font-size: 15px;
    }

    .empty-btn{
        font-size: 16px;
        padding: 12px 20px;
    }


}




.top-alert{
    position: fixed;
    top: 145px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    opacity: 0;
    z-index: 9999;
    transition: all 0.4s ease;
}

.top-alert.show{
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.top-alert.hide{
    transform: translateX(-50%) translateY(-20px);
    opacity: 0;
}

.top-alert-content{
    background: #fff;
    border-radius: 12px;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 280px;
    max-width: 90vw;
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
    border: 1px solid #eee;
}

/* TYPES */
.top-alert-content.success{
    color: #2e7d32 !important;
    
    background: #f1fff3;
}





.top-alert-content.success #globalAlertText{
    color:#2e7d32 !important;
}

/* 🔥 icon also green */
.top-alert-content.success #globalAlertIcon{
    color:#2e7d32 !important;
}

.top-alert-content.error{
    color: #d32f2f !important;
    
    background: #fff5f5;
}

.top-alert-content.warning{
    color: #b28704 !important;
    
    background: #fffbea;
}

.top-alert-content.info{
    color: #333;
    
}


.top-alert-content{
    flex-wrap: wrap;              /* 🔥 allow wrapping */
    word-break: break-word;       /* 🔥 break long text */
    white-space: normal;          /* 🔥 no single line */
    line-height: 1.4;
}


/* CLOSE BUTTON */
.top-alert-close{
    margin-left: auto;
    background: transparent;
    border: none;
    color: #444;
    font-size: 30px;
    cursor: pointer;
    opacity: 0.8;
}

.top-alert-close:hover{
    opacity: 1;
}

@media(max-width:768px){

    .top-alert{
        width: 92%;
        left: 50%;
        transform: translateX(-50%) translateY(-20px);
        top: 100px !important;
    }

    .top-alert-content{
        font-size: 15px;
        padding: 12px 14px;
		align-items: flex-start;
		 
    }

    #globalAlertText{
    margin-top: 10px !important;
    display: block;
    word-break: break-word;
}

}