/*
 Theme Name:   xstore-child
 Theme URI:    http://8theme.com/
 Description:  XStore Child Theme
 Author:       8theme
 Author URI:   http://8theme.com
 Template:     xstore
 Version:      1.0
 Text Domain:  xstore-child
*/
.type-product ul, .content ul, .type-product ol, .content ol {
    padding-left: 0px !important;
}
.e-con {
    padding-right: 0px !important;
    padding-left: 0px !important;
}

/* Sidebar Styling */
.my-account-sidebar {

    left: 0;
    top: 80px; /* Adjust based on header height */
    width: 250px;
    height: calc(100vh - 80px);
    background-color: #006559;
    border-right: 1px solid #e1e1e1;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    padding-top: 20px;
    overflow-y: auto;
    z-index: 1000;
    transition: width 0.3s ease-in-out, left 0.3s ease-in-out;
}
/* Basic CSS for dropdown functionality */
.my-account-sidebar .sub-menu {
    display: none;
    padding-left: 15px;
}

.my-account-sidebar .menu-item-has-children.active > .sub-menu {
    display: block;
}

.my-account-sidebar .menu-item-has-children > a {
    position: relative;
    display: flex;
    
    align-items: center;
}

.my-account-sidebar .dropdown-arrow {
    transition: transform 0.3s ease;
}

.my-account-sidebar .menu-item-has-children.active .dropdown-arrow {
    transform: rotate(180deg);
}

/* Add responsive styles for sidebar toggle */
.my-account-sidebar.collapsed {
    width: 60px;
}

.my-account-sidebar.collapsed .user-name,
.my-account-sidebar.collapsed span:not(.dropdown-arrow) {
    display: none;
}
/* Collapsed Sidebar */
.my-account-sidebar.collapsed {
    width: 80px; /* Increased width for better spacing */
}

/* Hide Profile Picture but Keep Toggle Button Visible */
.my-account-sidebar.collapsed .user-profile {
    display: none;
}

/* Reposition Toggle Button in Collapsed State */
.my-account-sidebar.collapsed .toggle-container {
    text-align: center;
    padding: 10px 0; /* Adjust padding for better spacing */
}

/* User Profile Section */
.user-profile {
    text-align: center;
    padding: 20px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.user-profile img {
    width: 80px;
    height: 80px;
    border-radius: 50% !important;
    border: 3px solid #fff;
    box-shadow: 0 2px 5px rgba(255, 255, 255, 0.2);
    object-fit: cover;
}

.user-name {
    font-weight: bold;
    color: #ffffff !important;
    font-size: 16px;
    margin-top: 8px;
}

/* Sidebar Links */
.my-account-sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.my-account-sidebar ul li {
    margin: 0;
}

.my-account-sidebar ul li a {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    font-size: 16px;
    font-weight: 500;
    color: #ffffff;
    text-decoration: none;
    transition: background 0.3s ease;
}

.my-account-sidebar ul li a i {
    font-size: 18px;
    margin-right: 12px;
    color: #ffffff;
    transition: color 0.3s ease;
}

/* Hover Effect */
.my-account-sidebar ul li a:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Active Link */
.my-account-sidebar ul li a.active {
    background-color: rgba(255, 255, 255, 0.3);
}

/* Collapsed State - Hide Text and Center Icons */
.my-account-sidebar.collapsed .user-name,
.my-account-sidebar.collapsed ul li span {
    display: none;
}

.my-account-sidebar.collapsed ul li a {
    justify-content: center;
    padding: 12px 0; /* Adjust padding for centered icons */
}

.my-account-sidebar.collapsed ul li a i {
    margin-right: 0; /* Remove margin for icons */
    font-size: 20px; /* Slightly increase icon size for better visibility */
}

/* Toggle Switch */
.toggle-container {
    text-align: center;
    padding: 15px;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 25px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 25px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 19px;
    width: 19px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #28a745;
}

input:checked + .slider:before {
    transform: translateX(25px);
}

/* Mobile Responsiveness */
/* Mobile Responsiveness */
@media (max-width: 768px) {
    /* Hide Sidebar by Default */
    .my-account-sidebar {
        position: fixed;
        left: -270px; /* Start closed on mobile */
        top: 0;
        width: 270px; /* Full width for mobile sidebar */
        height: 100vh; /* Full height */
        background-color: #006559;
        border-right: 1px solid #e1e1e1;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
        padding-top: 20px;
        overflow-y: auto;
        z-index: 1000;
        transition: left 0.3s ease-in-out; /* Smooth transition */
    }

    /* Show Sidebar When Toggled */
    .my-account-sidebar.open {
        left: 0; /* Show sidebar when toggled */
    }

    /* Ensure Toggle Button is Always Visible */
    .toggle-container {
        position: fixed;
        top: 20px; /* Adjust based on your header height */
        left: 20px; /* Adjust position as needed */
        z-index: 1001; /* Ensure it's above other elements */
    }

    /* Hide Profile and Other Elements on Mobile */
    .my-account-sidebar .user-profile,
    .my-account-sidebar .user-name,
    .my-account-sidebar ul li span {
        display: none;
    }

    /* Center Icons in Collapsed State */
    .my-account-sidebar ul li a {
        justify-content: center;
        padding: 12px 0; /* Adjust padding for centered icons */
    }

    .my-account-sidebar ul li a i {
        margin-right: 0; /* Remove margin for icons */
        font-size: 20px; /* Slightly increase icon size for better visibility */
    }
}