/* ===== TOPBAR ===== */
.topbar{
    background:#2f3545;
    color:#fff;
    padding:8px 5%;
    display:flex;
    justify-content:space-between;
    align-items:center;
    font-size:13px;
    flex-wrap:wrap;
    gap:8px;
}
.topbar a{ color:#fff; font-weight:500; }

@media(max-width:768px){
    .topbar{
        font-size:11px;
        padding:8px 3%;
        gap:5px;
    }
    .topbar span{
        flex:1;
        min-width:150px;
    }
}

/* ===== HEADER ===== */
.header{
    position: sticky;
    top:0;
    z-index:1001;
    background:#fff;
    padding:12px 5%;
    display:flex;
    justify-content:space-between;
    align-items:center;
}

@media(max-width:768px){
    .header{
        padding:10px 3%;
    }
}


.header-left{
    display:flex;
    align-items:center;
    gap:12px;
}
.logo{ 
    height:50px;
    max-width:100%;
    object-fit:contain;
}
.location{
    font-size:14px;
    color:#444;
}

@media(max-width:768px){
    .header-left{
        gap:8px;
    }
    .logo{
        height:40px;
    }
    .location{
        font-size:12px;
        display:none;
    }
}

@media(max-width:480px){
    .logo{
        height:35px;
    }
}

/* HEADER RIGHT ICONS */
.header-right{
    display:flex;
    align-items:center;
    gap:18px;
    font-size:20px;
}
.header-right a{
    color:#333;
    text-decoration:none;
}
.header-right a:hover{
    color:#431469;
}
.customer-care-link{
    display:flex;
    align-items:center;
    justify-content:center;
    width:40px;
    height:40px;
    border-radius:50%;
    background:#f1f4ff;
    transition:all 0.3s ease;
}
.customer-care-link:hover{
    background:#431469;
    color:#fff !important;
}

@media(max-width:768px){
    .header-right{
        gap:12px;
        font-size:18px;
    }
    .customer-care-link{
        width:36px;
        height:36px;
    }
}

@media(max-width:480px){
    .header-right{
        gap:8px;
        font-size:16px;
    }
    .customer-care-link{
        width:32px;
        height:32px;
    }
}
.cart-icon{
    position:relative;
    width:42px;
    height:42px;
    border-radius:50%;
    background:#f1f4ff;
    display:flex;
    justify-content:center;
    align-items:center;
    font-size:18px;
}

.cart-badge{
    position:absolute;
    top:-6px;
    right:-8px;
    background:red;
    color:#fff;
    font-size:11px;
    width:16px;
    height:16px;
    border-radius:50%;
    display:flex;
    justify-content:center;
    align-items:center;
}

.cart-wrapper{ 
    display:flex; 
    align-items:center; 
    gap:10px; 
    cursor:pointer; 
}

.cart-text{
    display:flex;
    flex-direction:column;
}

@media(max-width:768px){
    .cart-icon{
        width:36px;
        height:36px;
        font-size:16px;
    }
    .cart-badge{
        width:14px;
        height:14px;
        font-size:10px;
    }
}

@media(max-width:480px){
    .cart-icon{
        width:32px;
        height:32px;
        font-size:14px;
    }
}

.mobile-nav{
    background:#f5f9fc;
    padding:12px;
    display:flex;
    flex-direction:column;
    gap:12px;

    position:sticky;
    top:0;
    left:0;
    width:100%;

    display:none;
    z-index:1000;
}

.mobile-nav a{
    background:#eef4f8;
    padding:14px 16px;
    border-radius:10px;
    font-size:20px;
}



/* ===== DESKTOP ===== */
@media(min-width:992px){
    .hamburger{ display:none !important; }

    .mobile-nav{
        position:sticky;
        top:75px;
        display:flex !important;
        flex-direction:row;
        justify-content:center;
        gap:25px;
        background:#fff;
        padding:10px 0;
        box-shadow:0 2px 5px rgba(0,0,0,0.1);
        z-index:1000;
    }

    .mobile-nav a{
        background:none;
        padding:0;
        font-size:15px;
        color:dark purple;
    }
    
    .mobile-nav a:hover{
        transform:none;
        color:#431469;
    }
}

/* ===== PROFILE DROPDOWN ===== */
.profile-dropdown{
    position:relative;
}

.profile-trigger{
    display:flex;
    align-items:center;
    gap:6px;
    cursor:pointer;
    font-size:14px;
    font-weight:500;
    color:#333;
}

.profile-trigger i{
    font-size:16px;
}

.profile-menu{
    position:absolute;
    right:0;
    top:120%;
    background:#fff;
    min-width:160px;
    border-radius:8px;
    box-shadow:0 8px 20px rgba(0,0,0,0.12);
    display:none;
    flex-direction:column;
    overflow:hidden;
    z-index:2000;
}

.profile-menu a{
    padding:12px 15px;
    text-decoration:none;
    color:#333;
    font-size:14px;
    display:flex;
    align-items:center;
    gap:8px;
    transition:.2s;
}

.profile-menu a:hover{
    background:#f5f5f5;
}

.profile-menu .logout{
    color:#dc3545;
}

.profile-menu.show{
    display:flex;
}

/* Mobile fix */
@media(max-width:768px){
    .profile-trigger span{
        display:none;
    }
}


/* ===== MOBILE FIXES ===== */
@media (max-width: 991px) {

    /* hide cart text (My Cart + Rs) */
    .cart-text{
        display: none;
    }

    /* hamburger visible */
    .hamburger{
        display:block;
        font-size:22px;
        cursor:pointer;
    }
}

/* LOGIN PANEL */
.login-panel{
    position:fixed;
    top:0;
    right:-100%;
    width:380px;
    height:100%;
    background:linear-gradient(180deg,#7b2ff7,#f107a3);
    padding:30px 25px;
    transition:.5s ease;
    z-index:9999;
    color:#fff;
    box-shadow:-10px 0 30px rgba(0,0,0,.4);
}

.login-panel.active{right:0;}

.login-box{
    background:#fff;
    color:#333;
    padding:25px;
    border-radius:18px;
    margin-top:40px;
    animation:slideUp .5s ease;
}

@keyframes slideUp{
    from{transform:translateY(20px);opacity:0;}
    to{transform:translateY(0);opacity:1;}
}

.login-panel h2{
    text-align:center;
    margin-bottom:20px;
    color:#1e1e2f;
}

.login-panel .form-group{
    position:relative;
    margin-bottom:18px;
}

.login-panel .form-group input{
    width:100%;
    padding:14px;
    border-radius:10px;
    border:1px solid #ddd;
    font-size:15px;
    outline:none;
    box-sizing:border-box;
}

.login-panel .form-group input:focus{
    border-color:#7b2ff7;
}

.login-panel button{
    width:100%;
    padding:14px;
    border:none;
    border-radius:12px;
    background:linear-gradient(135deg,#7b2ff7,#f107a3);
    color:#fff;
    font-size:16px;
    font-weight:600;
    cursor:pointer;
    transition:.3s;
}

.login-panel button:hover{
    opacity:.9;
    transform:translateY(-1px);
}

.login-panel .close{
    position:absolute;
    top:15px;
    right:20px;
    font-size:26px;
    cursor:pointer;
    color:#fff;
}

.login-panel .small-text{
    text-align:center;
    font-size:13px;
    color:#666;
    margin-top:12px;
}

.login-panel .error{
    color:#e63946;
    text-align:center;
    margin-top:10px;
}

@media(max-width:480px){
    .login-panel{width:100%;}
}

/* ===== TOAST (add to cart success) ===== */
.site-toast{
    position:fixed;
    bottom:24px;
    left:50%;
    transform:translateX(-50%) translateY(80px);
    background:#2f3545;
    color:#fff;
    padding:12px 24px;
    border-radius:10px;
    font-size:14px;
    box-shadow:0 4px 20px rgba(0,0,0,.25);
    z-index:9999;
    opacity:0;
    transition:transform .3s ease, opacity .3s ease;
    pointer-events:none;
}
.site-toast.show{
    transform:translateX(-50%) translateY(0);
    opacity:1;
}
