.nm-games-box .image {
    height: 216px;
}

.nm-games-box .image img {
    height: 100%;
    object-fit: contain;
}

.menu-bar-icon {
    display: none;
}

.phone-btn {
    display: none;
}

.nm-footer-menu-title svg {
    display: none;
}

.menu_phone {
    display: none;
}

.nm-mobile-header {
    display: none;
}

.nm-mobile-header-wrapper {
    display: none;
}

@media (max-width: 1399.98px) {
    .desktop-btn {
        display: flex;
    }

}

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

@media (max-width: 992px) {
    .desktop-btn {
        display: flex;
    }

}

.mobile-menu-wrapper {
    display: none;
}

@media (max-width: 367px) {
    .mobile-menu-wrapper ul li {
        font-size: 15px;
    }
}

@media (max-width: 991px) {
    .thankyou-page table {
        display: none;
    }

    .thankyou-list-mobile {
        display: block;
    }

    .custom-order-detail {
        padding: 16px !important;
    }

    .factor-info {
        min-width: 100% !important;
        flex-direction: column;
        gap: 8px !important;
        padding: 12px !important;
        border-radius: 12px !important;
    }

    .factor-info p {
        margin: 0;
        font-weight: 700 !important;
        font-size: 14px !important;
    }

    .contact-info {
        align-items: flex-start !important;
    }

    .custom-billing-address .contact-info span {
        color: #4F4F4F !important;
    }

    .factor-info form,
    .factor-info form button {
        width: 100% !important;
    }

    .thankyou-page .woocommerce-thankyou-order-details li {
        padding: 0 !important;
    }

    .woocommerce-thankyou-order-received {
        font-weight: 700 !important;
        font-size: 16px !important;
    }

    .woocommerce ul.order_details {
        padding: 0;
    }

    .custom-order-detail {
        margin-bottom: 16px;
    }

    .thankyou-list-item {
        border: 1px solid #E0E0E0;
        border-radius: 12px;
        padding: 16px 16px 0;
        margin-bottom: 8px;
    }

    .thankyou-title {
        display: block;
        font-weight: 700;
        font-size: 14px;
        color: #0031A2;
    }

    .thankyou-list-image img {
        width: 52px;
        height: 52px;
        border-radius: 4px;
        object-fit: contain;
    }

    .thankyou-list-image {
        display: flex;
        margin-top: 12px;
        padding-bottom: 16px;
        border-bottom: 1px solid #E0E0E0;
    }

    .thankyou-list-item ul {
        padding: 0;
        margin: 0;
        list-style: none;
    }

    .thankyou-list-item ul li {
        padding: 16px 0;
        border-bottom: 1px solid #E0E0E0;
        display: flex;
        align-items: center;
        justify-content: space-between;
        font-weight: 700;
        font-size: 14px;
        gap: 28px;
    }

    .thankyou-list-item ul li:last-child {
        border: none;
    }

    .thankyou-list-item ul li span:first-child {
        color: #0031A2;
    }

    .thankyou-list-item ul li span:last-child {
        color: #4F4F4F;
    }

    .thankyou-list-content h3 {
        font-weight: 700;
        font-size: 14px;
        color: #4F4F4F;
        margin: 0 0 8px;
    }

    .thankyou-list-content p {
        margin: 0;
        font-weight: 700;
        font-size: 14px;
        color: #4F4F4F;
    }

    .thankyou-list-content p span {
        color: #828282;
    }

    .mobile-menu-wrapper {
        display: block;
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100%;
        background-color: white;
        box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
        transition: 0.3s ease-in-out;
        opacity: 0;
        visibility: hidden;
        z-index: 341001;
        overflow: scroll;
    }

    .mobile-menu-wrapper ul {
        list-style: none;
        display: flex;
        flex-direction: column;
        padding: 10px 0;
        margin: 0;
    }

    .btn-plus {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        padding: 9px;
        font-size: 14px;
        font-weight: 700;
        color: #FFFFFF;
        background: linear-gradient(174.8deg, #315C8C 4.54%, #173455 138.63%);
        box-shadow: 0px 4px 16px 0px #0031A214;
        border-radius: 8px;
        margin: 0 16px 12px;
    }

    .btn-mag {
        text-align: center;
        display: block;
        background: linear-gradient(172.16deg, #FC7C5F 6.59%, #F14A25 94.55%);
        box-shadow: 0px 4px 16px 0px #0031A214;
        margin: 0 16px;
        padding: 9px;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 700;
        color: #FFFFFF;
    }

    .submenu-open>ul {
        margin-top: 8px;
        border-bottom: 1px solid #E0E0E0
    }

    .submenu-open>a {
        color: #0031A2 !important;
    }

    .mobile-menu-wrapper ul li.submenu-open.menu-item-has-children::after {
        background-image: url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M14 16L10 12L14 8" stroke="%230031A2" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>');
    }

    .mobile-menu-wrapper ul li {
        text-decoration: none;
        padding: 12px 0;
        width: 100%;
        border-right: none;
        border-left: none;
        gap: 8px;
        position: relative;
    }

    .first-menu-mobile {
        position: relative;
        padding: 0 16px;
    }

    .first-menu-mobile .first-menu-mobile:after {
        content: '';
        width: 97%;
        height: 1px;
        background: #BDBDBD;
        display: block;
        position: absolute;
        bottom: 0;
        left: 50%;
        transform: translateX(-50%);
    }

    .mobile-menu-wrapper .menu-item img {
        margin-bottom: -7px;
        margin-left: 8px;
    }

    .mobile-menu-wrapper ul li.menu-item-has-children .toggle-icon {
        content: "";
        width: 24px;
        height: 24px;
        background-image: url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M14 16L10 12L14 8" stroke="%23828282" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>');
        background-repeat: no-repeat;
        background-position: center;
        background-size: contain;
        float: left;
        position: absolute;
        left: 0;
        top: 13px;
        transition: 0.3s;
    }

    /* Default state for sub-menus */
    .mobile-menu-wrapper ul li .sub-menu {
        display: none;
        width: 100%;
    }

    .first-menu-mobile>ul>li>.sub-menu {
        border-top: 1px solid #0031A2;
        padding: 12px 12px 0 0;
        margin-top: 12px;
    }

    .first-menu-mobile ul li .sub-menu a {
        font-weight: 600;
        font-size: 12px;
        color: #828282;
    }

    .first-menu-mobile ul li ul li ul li {
        padding: 0;
        margin-bottom: 12px;
    }

    .first-menu-mobile ul li ul li ul li:last-child {
        margin-bottom: 0;
    }

    .first-menu-mobile ul li ul li ul {
        padding: 8px 0 0 0;
        margin: 0;
    }

    .last-menu-mobile {
        border-top: 1px solid #BDBDBD;
        margin-bottom: 20px;
    }

    .last-menu-mobile ul.mobile-menu>li:first-child>a {
        color: var(--secondary-color);
    }

    .last-menu-mobile ul {
        padding: 0 16px;
    }

    .first-menu-mobile ul li ul li ul li:before {
        content: '';
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: #828282;
        display: inline-block;
        margin: 0 8px;
        ;
    }

    /* Rotate arrow when submenu is open */
    .mobile-menu-wrapper ul li.menu-item-has-children.submenu-open>.toggle-icon {
        transform: rotate(-90deg);
        transition: transform 0.3s ease-in-out;
        color: #0031A2;
        background-image: url('data:image/svg+xml,<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M14 16L10 12L14 8" stroke="%230031A2" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>');
    }

    .mobile-menu-wrapper .mo-head-logo img {
        width: 140px;
        background-color: #EFF4FF;
    }

    .mobile-menu-wrapper ul li a {
        color: #4F4F4F;
        text-decoration: none;
    }

    .mo-head-logo {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 20px 0px;
        background: #EFF4FF;
    }

    .close-menu-btn {
        position: absolute;
        top: 10px;
        left: 10px;
        cursor: pointer;
    }

    /*sidebar shop*/
    .menu-bar-icon {
        display: flex;
    }

    .nm-cart-btn {
        display: none;
    }

    .nm-mega-menu-btn {
        display: none;
    }

    .top-header {
        justify-content: center;
    }

    .top-header-left {
        display: none;
    }

    /*    footer desktop & phone*/
    .nm-footer-menu {
        margin: 10px 0;
        border-bottom: 1px solid #0048EF;
    }

    .nm-footer-menu-title {
        display: flex;
        justify-content: space-between;
        cursor: pointer;
        font-weight: bold;
    }

    .nm-footer-menu ul {
        list-style-type: none;
        padding: 0;
        display: none;
    }

    .nm-footer-menu.active ul {
        display: block;
    }

    .nm-footer-menu.active ul li {
        display: flex;
        align-items: center;
        font-size: 14px;
        font-weight: 600;
        margin: 10px 0;
    }

    .nm-footer-menu.active ul li:before {
        content: "";
        width: 8px;
        height: 8px;
        border-radius: 10px;
        background: #D8E4FF;
        display: flex;
        margin: 0 10px;
    }

    .nm-footer-menu-title svg {
        transition: transform 0.3s;
    }

    .nm-footer-menu.active .nm-footer-menu-title svg {
        transform: rotate(180deg);
    }

    .nm-permissions span {
        margin-block: 1.3rem .6rem;
    }

    .nm-footer-menu-title svg {
        display: block;
    }

    .nm-footer-menu ul li a {
        color: #D8E4FF;
    }

    /*    footer desktop & phone*/
}

@media (max-width: 991px) {

    /* Hide desktop header elements on mobile */
    .nm-main-top-header {
        display: none !important;
    }

    .top-header {
        display: none !important;
    }

    .nm-info-header {
        display: none !important;
    }

    /* Show mobile header */
    .nm-mobile-header-wrapper {
        display: block !important;
    }

    .nm-mobile-header {
        display: flex !important;
    }

    /*start menu phone*/
    .menu_phone {
        text-align: center;
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .menu_phone .content-phone .menu_phone_icon {
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 55px;
    }

    /*menu */
    .menu_phone .content-phone {

        position: fixed;
        bottom: 5px;
        display: flex;
        width: 93%;
        height: 65px;
        margin: 0 auto;
        border-radius: 16px;
        align-items: center;
        z-index: 999;
        justify-content: space-around;
        background-color: #fff;
        border: 1px solid #E0E0E0;
        box-shadow: 0 0 15px 0 #0031A226;

    }

    .menu_phone .content-phone .home {
        position: relative;
    }

    .menu_phone .content-phone .menu_phone_icon {
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 55px;
    }

    .menu_phone .content-phone .menu_phone_icon a {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
    }

    .menu_phone .content-phone .menu_phone_icon>div {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .menu_phone .content-phone .image {
        --border-angle: 0deg;
        --bg: #0048ef;
        /* or whatever your brand color is */

        display: flex;
        height: 60px;
        width: 60px;
        margin-bottom: 2px;
        align-items: center;
        justify-content: center;
        position: relative;
        border-radius: 50%;
        border: 2px solid transparent;
        animation: border-angle-rotate 2s linear infinite;

        background: linear-gradient(#17d574, #15a58b) padding-box,
            conic-gradient(from var(--border-angle),
                var(--bg) 50%,
                #eee) border-box;
        box-shadow: 0px 1px 2px hsl(0 0% 0% / 25%);
        z-index: 1;
    }

    @keyframes border-angle-rotate {
        from {
            --border-angle: 0deg;
        }

        to {
            --border-angle: 360deg;
        }
    }

    @property --border-angle {
        syntax: "<angle>";
        initial-value: 0deg;
        inherits: false;
    }

    .menu_phone span {
        color: #828282;
        font-weight: 700;
        font-size: 10px;
        line-height: 100%;
        text-align: center;
        margin-top: 6px;
    }

    .menu_phone .user span {
        color: #828282;
        font-weight: 700;
        font-size: 9px;
        line-height: 100%;
        text-align: center;
    }

    .menu_phone .bottom-menu-active span {
        color: #0031A2;
    }

    .menu_phone .bottom-menu-active svg path {
        stroke: #0031A2;
    }

    /* نخل پلاس - برجسته وسط */
    .menu_phone .nakhlplus_center {
        position: relative;
        width: 15% !important;
    }

    .menu_phone .nakhlplus_center .nakhlplus_circle {
        --border-angle: 0deg;
        --bg: #0048ef;
        display: flex;
        height: 60px;
        width: 60px;
        margin-bottom: 2px;
        align-items: center;
        justify-content: center;
        position: relative;
        border-radius: 50%;
        border: 2px solid transparent;
        animation: border-angle-rotate 2s linear infinite;
        background: linear-gradient(#294E77, #173455) padding-box, conic-gradient(from var(--border-angle), var(--bg) 50%, #eb0808) border-box;
        box-shadow: 0 1px 2px hsl(0 0% 0% / 25%);
        z-index: 1;
    }

    .nakhlplus_center a {
        margin-bottom: 40px;
    }

    /* گفتگو آنلاین */
    .menu_phone .chat_online a {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-decoration: none;
    }

    .menu_phone .chat_online span {
        font-size: 9px;
    }

    /**/
    /*start index page*/
    .nm-nakhlplus-banner img {
        height: 200px;
    }

    .nm-nakhlplus-section .nakhlplus-swiper .swiper-slide {
        width: 90% !important;
        margin: 0 8px 0 8px !important;
    }

    .last-menu-mobile ul.mobile-menu>li:nth-child(2)>a {
        color: #16A368;
    }

    .nm-nakhlplus-section .col-lg-9 {
        padding: 0;
    }

    .nm-nakhlplus-section .col-lg-9 {
        margin-right: 16px;
    }

    .nm-cat-banners .container {
        padding: 0 16px 0 0;
    }

    .guaranteeswiper .swiper-slide-active {
        width: 90% !important;
        margin: 0 8px 0 8px !important;
    }

    .nm-product-box img {
        height: auto;
    }

    .phone-btn {
        display: flex;
        justify-content: center;
        margin: 1rem 0;
    }

    .nm-game-consoles-head {
        display: flex;
        align-items: flex-start;
        justify-content: center;
        flex-direction: column;
    }

    .nm-game-consoles-tab {
        display: flex;
        margin-top: 20px;
        flex-wrap: wrap;
    }

    .nm-game-consoles-tab ul li {
        font-size: 12.8px;
    }

    .nm-game-consoles-tab ul li::after {
        margin-left: 3px;
        margin-right: 3px;
    }

    .nm-brands-banner {
        width: 100%;
    }

    .nm-brands-slider {
        width: 100%;
    }

    .nm-highlights-box img {
        height: 164px;
        object-fit: cover;
    }

    .nm-banners-footer {
        margin-top: 70px;
    }

    .nm-highlights-box>a {
        height: auto;
    }

    /*end index page*/
    .desktop-btn {
        display: none;
    }

    .banners-swiper .swiper-slide {
        width: 85%;
    }

    .nm-offers-banner {
        height: 432px;
        margin-bottom: 20px;
    }

    .offers-product {
        margin-bottom: 16px;
    }

    .nm-product-box .offers-product-price {
        margin-top: unset;
        padding: 0 5px 5px 5px;
    }

    .nm-product-box .price {
        padding: 0px 5px 5px 5px;
    }
}

/* Mobile Header Styles */
@media (max-width: 991px) {
    .nm-mobile-header-wrapper {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        width: 100%;
        background: linear-gradient(to bottom, #EFF4FF 50%, #FFFFFF 50%);
        padding: 12px;
        z-index: 1000;
        transition: background 0.3s ease, backdrop-filter 0.3s ease;
    }

    /* When scrolled - فقط نصف بالا آبی (بدون شیشه‌ای)، نصف پایین شفاف */
    .nm-mobile-header-wrapper.scrolled {
        background: linear-gradient(to bottom, #EFF4FF 50%, transparent 50%);
    }

    /* Hide mobile header on nakhlplus page */
    body.np .nm-mobile-header-wrapper {
        display: none !important;
    }

    /* Add padding to body to prevent content from hiding under fixed header */
    body {
        padding-top: 85px;
    }

    /* Remove padding-top for nakhlplus page since header is hidden */
    body.np {
        padding-top: 0 !important;
    }

    .nm-mobile-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 12px 16px;
        background-color: #FFFFFF;
        border-radius: 12px;
        direction: rtl;
        box-shadow: 0px 2px 8px rgba(0, 49, 162, 0.08);
    }

    .nm-mobile-search-wrapper {
        flex: 1;
        cursor: pointer;
    }

    .nm-mobile-search {
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 12px 16px;
        background-color: #F5F5F5;
        border-radius: 12px;
        direction: rtl;
    }

    .nm-mobile-search .search-icon {
        flex-shrink: 0;
    }

    .nm-mobile-search .search-text-wrapper {
        display: flex;
        align-items: center;
        gap: 8px;
        flex: 1;
        direction: rtl;
    }

    .nm-mobile-search .search-text {
        font-size: 14px;
        font-weight: 400;
        color: #828282;
        white-space: nowrap;
    }

    .nm-mobile-search .search-logo {
        height: 24px;
        width: auto;
        object-fit: contain;
    }

    .nm-mobile-menu-btn {
        flex-shrink: 0;
    }

    .nm-mobile-menu-btn .menu-bar-icon {
        cursor: pointer;
    }

    /* Responsive adjustments for smaller mobile screens */
    @media (max-width: 380px) {
        .nm-mobile-search .search-text {
            font-size: 12px;
        }
    }
}