/*categories css*/
#categoryTopBar{

    position: fixed;
    top: 60px;
    left: 0;
    width: 100%;
    z-index: 9999;

    display: flex;
    align-items: center;

    gap: 6px;

    overflow-x: auto;
    overflow-y: hidden;

    padding: 6px 8px;

    background: rgba(255,255,255,0.75); /* 🔥 blur effect base */
    backdrop-filter: blur(12px);        /* 🔥 main glass effect */
    -webkit-backdrop-filter: blur(12px);

    border-bottom: 1px solid rgba(0,0,0,0.08);

    white-space: nowrap;

    scrollbar-width: none;

    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
#categoryTopBar::-webkit-scrollbar{
    display:none;
}
/* =======================================================
   CATEGORY BUTTON (PROFESSIONAL PREMIUM)
======================================================= */

.catBtn{

    flex: 0 0 auto;

    display: flex;
    flex-direction: column;

    align-items: center;
    justify-content: center;

    gap: 3px;

    padding: 6px 8px;

    min-width: 62px;
    min-height: 54px;

    background: #fff;

    border: 1.5px solid #e2e2e2;

    border-radius: 18px;

    cursor: pointer;

    transition: all 0.2s ease;

    position: relative;

    box-shadow: 0 1px 6px rgba(0,0,0,0.04);

    overflow: hidden;
}
.catBtn:hover{

    transform: translateY(-2px);

    box-shadow:
    0 6px 14px rgba(0,0,0,0.08);
}

/* =======================================================
   CATEGORY ICON
======================================================= */

.catAvatar{

    width: 36px;
    height: 36px;

    border-radius: 12px;

    object-fit: cover;

    background: linear-gradient(135deg, #f8fafc, #eef2f7);

    padding: 4px;

    border: 1px solid #e9edf3;

    transition: all 0.2s ease;
}
/* =======================================================
   ALL CATEGORY ICON (PREMIUM BIG COLORFUL STYLE)
======================================================= */

.catBtn.allCategory .catAvatar{

min-height: 54px !important;
    padding: 6px 8px !important;
    width: 46px;
    height: 46px;

    border-radius: 16px;

    background: linear-gradient(135deg, #ff6a00, #ee0979, #ffcc00);

    display: flex;
    align-items: center;
    justify-content: center;

    color: #fff;

    font-size: 20px;

    font-weight: bold;

    border: none;

    box-shadow:
    0 6px 14px rgba(255, 106, 0, 0.25);

    transform: scale(1.05);
}
.allAnimatedIcon{
    width: 46px;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.allCategoryImg{

    width: 56px;
    height: 56px;

    object-fit: cover;

    border-radius: 16px;

    background: linear-gradient(135deg, #ff6a00, #ff3d00, #ffcc00);

    padding: 8px;

    box-shadow: 0 6px 14px rgba(255,106,0,0.25);

}
/* optional glow effect */
.catBtn.allCategory .catAvatar::before{
    content: "★";

    font-size: 20px;
    color: #fff;
}
/* =======================================================
   CATEGORY NAME
======================================================= */

.catName{

    font-size: 11px;

    font-weight: 600;

    color: #444;

    text-align: center;

    white-space: nowrap;

    line-height: 1.2;

    max-width: 65px;

    overflow: hidden;

    text-overflow: ellipsis;
}

/* =======================================================
   ACTIVE CATEGORY (SIMPLE UNDERLINE STYLE)
======================================================= */

.catBtn.active{

    background: #fff !important;

    border: 1.5px solid #ff6a00 !important;

    box-shadow:
        0 6px 14px rgba(255, 106, 0, 0.18),
        0 2px 8px rgba(238, 9, 121, 0.10) !important;

    transform: none !important;
}
/* text highlight optional */
.catBtn.active .catName{

    background: linear-gradient(135deg, #ff6a00, #ee0979);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;

    font-weight: 700;
}

/* underline indicator like link */
/* icon no change on active */
.catBtn.active .catAvatar{
    transform: none !important;
    background: inherit;
}
/* =======================================================
   CATEGORY VIEW FIX (LESS GAP TOP/BOTTOM)
======================================================= */
#categoryView{

    margin-top: 82px !important;

    padding-top: 0 !important;
}
/* =======================================================
   CATEGORY PRODUCTS GAP FIX
======================================================= */

#categoryProducts{
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;

    padding-top: 8px; /* 🔥 reduced gap */
}

/* =======================================================
   SMOOTH ANIMATION
======================================================= */

@keyframes fadeCategory{
    from{
        opacity: 0;
        transform: translateY(6px);
    }
    to{
        opacity: 1;
        transform: translateY(0);
    }
}
/*categori sy nechay container*/
#categoryImagePicker{

    width: 100%;

    height: 55px;   /* 🔥 پہلے 70px تھا، اب کم کر دیا */

    background: #fff;

    border-radius: 12px;

    margin-top: 6px;

    margin-bottom: 4px;

    border: 1.5px dashed #cfd6e0;  /* تھوڑا soft + clean */

    display: flex;

    align-items: center;

    justify-content: center;

    overflow: hidden;

    position: relative;

    cursor: pointer;
}
#categoryImagePicker img{

    width: 100%;
    height: 100%;

    object-fit: cover;
}
.categoryImageWrap{
    display:flex;
    width:100%;
    height:220px;
    gap:8px;
}

/* LEFT MAIN IMAGE 75% */
.mainImageBox{
    flex:3;
    overflow:hidden;
    border-radius:12px;
}

.mainImageBox{
    position: relative;
    overflow: hidden;
}

/* blurred background layer */
.mainImageBox::before{
    content:"";
    position:absolute;
    top:0;
    left:0;
    width:100%;
    height:100%;

    background-image: var(--img);
    background-size: cover;
    background-position: center;

    filter: blur(20px);
    transform: scale(1.2);
}

/* real image */
.mainCategoryImg{
    position: relative;
    width:100%;
    height:100%;
    object-fit: contain;
}

/* RIGHT GALLERY 25% */
.galleryBox{
    flex:1;
    display:flex;
    flex-direction:column;
    gap:6px;
}

/* each small image */
.galleryItem{
    flex:1;
    overflow:hidden;
    border-radius:8px;
    border:1px solid #eee;
}

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