:root {
    --wd-primary-color: #d60644;
    --wd-alternative-color: #fbbc34;
    --wd-text-color: #777777;
    --wd-title-color: #242424;
    --wd-entities-title-color: #333333;
    --wd-container-w: 1600px;
    --wd-form-brd-radius: 5px;
    --wd-brd-radius: 0;
}

@font-face {
    font-family: "iransans";
    src: url("../fonts/IRANSans-Light-web.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

* { box-sizing: border-box; }

body {
    font-family: "iransans", Arial, Helvetica, sans-serif;
    font-size: 14px;
    color: var(--wd-text-color);
    background: #fff;
    margin: 0;
}

a { text-decoration: none; color: #333; }
a:hover { color: var(--wd-primary-color); }

/* ============ HEADER ============ */
.whb-header { 
    background: #fff; 
    position: static; 
    top: 0; 
    z-index: 100; 
    box-shadow: 0 2px 8px rgba(0,0,0,.04); 
}

/* نوار بالایی (پیام و شبکه‌های اجتماعی) */
.whb-top-notice-bar {
    background-color: #1a1a1a;
    color: #fff;
    padding: 8px 0;
    font-size: 13px;
}
.whb-top-notice-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.top-social-icons {
    display: flex;
    gap: 12px;
}
.top-social-icons a {
    display: inline-block;
    width: 20px;
    height: 20px;
    background-color: #fff;
    mask-size: contain;
    -webkit-mask-size: contain;
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
    mask-position: center;
    -webkit-mask-position: center;
    opacity: 0.7;
    transition: opacity 0.2s;
}
.top-social-icons a:hover {
    opacity: 1;
}

.whb-general-header { /*border-bottom: 1px solid rgba(129,129,129,.2);*/ padding: 6px 0; }
.whb-general-header .whb-flex-row { display: flex; align-items: center; gap: 20px; font-size: 12px;}

.whb-col-left, .whb-col-right { display: flex; align-items: center; gap: 10px; }
.whb-col-center { flex: 1; }

.wd-logo img { height: auto; display: block; }

/* آیکون‌های هدر */
.wd-header-cart, .wd-header-wishlist, .wd-header-compare, .wd-header-my-account {
    position: relative; display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 10px; border-radius: 4px; transition: background .2s;
    color: #333; text-decoration: none;
}
.wd-header-cart:hover, .wd-header-wishlist:hover, .wd-header-compare:hover { background: #f7f7f7; }

.wd-tools-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    font-size: 20px;
}

/* شمارنده‌های کوچک روی آیکون */
.wd-tools-count, .wd-cart-number {
    position: absolute;
    right: -8px;
    background: var(--wd-primary-color); 
    color: #fff;
    border-radius: 50%; 
    font-size: 10px; 
    padding: 1px 5px; 
    min-width: 16px; 
    text-align: center;
    font-weight: 700;
}

.wd-divider { width: 1px; height: 20px; background: #eee; }

/* Dropdown */
.wd-dropdown-wrapper { position: relative; }
.wd-dropdown {
    display: none; position: absolute; top: 100%; right: 0; min-width: 220px;
    background: #fff; border-radius: 6px; box-shadow: 0 5px 20px rgba(0,0,0,.1);
    padding: 12px; z-index: 10;
}
.wd-dropdown-wrapper:hover .wd-dropdown { display: block; }
.wd-dropdown-my-account ul { list-style: none; margin: 0; padding: 0; }
.wd-dropdown-my-account li a { display: block; padding: 6px 8px; border-radius: 4px; }
.wd-dropdown-my-account li a:hover { background: #f7f7f7; }

/* Search */
.wd-search-form { position: relative; flex: 1; width: 50%; max-width: 600px; min-width: 200px}
.wd-search-form form { display: flex; background: #f7f7f7; border-radius: 5px; overflow: hidden; max-height: 40px;}
.wd-search-form .s {
    flex: 1; border: 0; padding: 12px 16px; background: transparent; font-family: inherit; font-size: 12px;
}
.wd-search-form .s:focus { outline: 0; }
.wd-search-form .searchsubmit {
    border: 0; padding: 0 22px; background: var(--wd-primary-color); color: #fff;
    cursor: pointer; font-family: inherit; font-size: 13px;
}

/* Bottom Nav (نوار پایینی) */
.whb-header-bottom { border-bottom: 1px solid #dedede; padding: 0; background: #fff; }

/* ✅ کاهش عرض کانتینر بخش پایینی */
.whb-header-bottom .container {
    margin: 0 auto;
	max-height: 40px;
}

.whb-header-bottom .whb-flex-row {
	font-size: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0;
}

.wd-header-cats { position: relative; }
.wd-header-cats .menu-opener {
    display: inline-flex; gap: 10px; padding: 8px 20px; background: #fff; font-weight: 600;
    cursor: pointer; 
    border-left: 1px solid #eee; /* ✅ تغییر به border-right برای سمت راست */
    border-right: none;
}
.wd-header-cats .wd-dropdown-cats { display: none; }
.wd-header-cats:hover .wd-dropdown-cats { display: block; }
.wd-nav-vertical { list-style: none; margin: 0; padding: 8px 0; }
.wd-nav-vertical a { display: block; padding: 8px 16px; }

/* استایل لینک‌های منوی ناوبری */
.wd-header-main-nav a {
    font-weight: 600;
    color: #333;
    text-decoration: none;
    padding: 2px 0; /* فاصله برای اینکه خط به متن بچسبد */
    position: relative;
    transition: color 0.2s;
}

/* خط زیرین با استفاده از شبه‌عنصر (Pseudo-element) */
.wd-header-main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 2px; /* ضخامت خط */
    background-color: var(--wd-primary-color); /* رنگ اصلی سایت */
    transition: width 0.3s ease; /* انیمیشن برای باز شدن خط */
}

/* هاور: خط باز می‌شود */
.wd-header-main-nav a:hover {
    color: var(--wd-primary-color);
}

.wd-header-main-nav a:hover::after {
    width: 100%;
}

/* لینک فعال (صفحه فعلی): خط همیشه ثابت است */
.wd-header-main-nav a.active {
    color: var(--wd-primary-color);
}

.wd-header-main-nav a.active::after {
    width: 100%;
}

.btn {
    display: inline-block; padding: 8px 20px; border-radius: 4px;
    font-family: inherit; font-size: 13px; cursor: pointer; border: 0;
    text-align: center; transition: all .2s;
}
.btn-color-primary { background: var(--wd-primary-color); color: #fff; }
.btn-color-primary:hover { background: #c40545; color: #fff; }
.btn-size-large { padding: 12px 28px; }
.btn-style-bordered { border: 2px solid #fff; color: #fff; }
.btn-style-bordered-nobg { border: 2px solid #fff; color: #fff; background: none; }
.btn-style-3d { box-shadow: inset 0 -2px 0 rgba(0,0,0,.15); }
/* آیکون سبد خرید */
.wd-header-cart .wd-tools-icon::before { content: '🛒'; font-size: 22px; }
/* آیکون علاقه‌مندی */
.wd-header-wishlist .wd-tools-icon::before { content: '♡'; font-size: 22px; }
/* آیکون مقایسه */
.wd-header-compare .wd-tools-icon::before { content: '⇄'; font-size: 22px; }
 /* دکمه منو (سمت راست) */
.whb-mobile-left {
	flex-shrink: 0;
	display: flex;
	align-items: center;
}

/* لوگو (وسط) */
.whb-mobile-center {
	flex: 1; /* فضای باقی‌مانده را پر می‌کند */
	display: flex;
	justify-content: center; /* وسط‌چین کردن لوگو */
}
.whb-mobile-center .wd-logo img {
	max-width: 100px !important; /* سایز مناسب برای موبایل */
}

/* آیکون‌ها (سمت چپ) */
.whb-mobile-right {
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: flex-end; /* چسبیدن به سمت چپ */
	gap: 12px;
}
/* ============ PAGE ============ */
.main-page-wrapper { padding: 20px 0; }
.wd-content-layout { padding: 0 15px; }

/* Hero Row */
.hero-row { display: grid; grid-template-columns: 1fr 2fr; gap: 20px; margin-bottom: 30px; }
.promo-banner img { width: 100%; height: auto; display: block; border-radius: 15px; box-shadow: 0 2px 6px rgba(0, 0, 0, .1);}

/* Banner Triple */
.banner-triple { display: grid; grid-template-columns: repeat(3,  1fr); gap: 20px; margin-bottom: 30px; }

/* Featured Row */
.featured-row {
    display: grid; grid-template-columns: 200px 1fr; gap: 20px;
    margin-bottom: 40px; background: #EF394E; border-radius: 10px; padding: 20px;
}
.featured-side { display: flex; flex-direction: column; align-items: center; gap: 15px; }
.featured-side img { max-width: 100%; height: auto; border-radius: 10px; }
/*.featured-row .featured-side .btn { background: var(--wd-primary-color); color: #fff; border: 0; }*/

/* Section Title */
.section-title {
    text-align: center; font-size: 18px; margin: 30px 0 20px;
    color: var(--wd-title-color); position: relative;
	 border-bottom: 1px solid #e5e5e5;
}
.section-title::after {
    content: ""; display: block; width: 60px; height: 2px;
    background: var(--wd-primary-color); margin: 12px auto 0;
}

/* Gift Section */
.gift-section { margin-bottom: 40px; }
.gift-carousel { display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px;background: #fff; background-image: url('../images/background-gift.svg'); }
.gift-item {
    border-radius: 10px; padding: 25px 15px; text-align: center;
    transition: transform .2s, box-shadow .2s;
	box-shadow: 0 2px 6px rgba(0, 0, 0, .1);
}
.gift-item:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(0,0,0,.08); }
.gift-item img { display: block; margin: 0 auto 15px; }
.gift-item h6 { margin: 0 0 12px; font-size: 16px; color: var(--wd-title-color); }
.gift-item .btn { background: var(--wd-primary-color); color: #fff; border: 0; border-radius: 15px;}

/* Products Carousel */
.wd-carousel-container { position: relative; }
.wd-carousel-inner { position: relative; }
.wd-nav-arrows { display: flex; gap: 6px; justify-content: center; margin-top: 15px; }
.wd-btn-arrow {
    width: 36px; height: 36px; border: 1px solid #ddd; border-radius: 50%;
    background: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: all .2s;
}
.wd-btn-arrow:hover { background: var(--wd-primary-color); color: #fff; border-color: var(--wd-primary-color); }
.wd-btn-arrow::before { content: "‹"; font-size: 20px; }
.wd-btn-arrow.wd-next::before { content: "›"; }
.wd-btn-arrow.swiper-button-disabled { opacity: .4; cursor: default; }

/* Product Grid Item */
.wd-product { background: #fff; border-radius: 10px; overflow: hidden; transition: box-shadow .2s; box-shadow: 0 2px 6px rgba(0, 0, 0, .1);}
.wd-product:hover { box-shadow: 0 8px 20px rgba(0,0,0,.08); }
.product-wrapper { padding: 10px; }
.product-element-top { position: relative; margin-bottom: 12px; }
.product-element-top .product-image-link img {
    width: 100%; height: auto; padding: 20px; display: block; border-radius: 6px;
}
.product-label {
    position: absolute; top: 10px; left: 10px;
    padding: 1px 6px; font-size: 12px; border-radius: 10px; color: #fff;
}
.product-label.onsale { background: var(--wd-primary-color); }
.product-label.new { background: var(--wd-alternative-color); color: #222; }
/* ============================================
   Product Labels — fix overlap
   ============================================ */

/* اگر onsale هست، new زیرش */
.product-label.onsale + .product-label.new,
.product-label.onsale + .new {
    top: 41px;   /* ← زیر onsale */
}

/* اگر onsale نیست (فقط new)، بالای کارت */
.product-label.new {
    top: 10px;
    left: 10px;
}

.wd-buttons {
    position: absolute; top: 10px; left: 10px; display: flex; flex-direction: column; gap: 6px;
    opacity: 0; transition: opacity .2s;
}
.wd-product:hover .wd-buttons { opacity: 1; }
.wd-btn {
    width: 34px; height: 34px; /*border-radius: 50%;*/ border: 0; background: #ebebeb;
    cursor: pointer; font-size: 20px; box-shadow: 0 2px 6px rgba(0,0,0,.1);
    display: flex; align-items: center; justify-content: center;
}
.wd-btn:hover, .wd-btn.is-active { background: var(--wd-primary-color); color: #fff; }
.wd-btn-cart { font-size: 14px; width: auto; padding: 0 8px; /*border-radius: 17px;*/ }

.wd-entities-title { font-size: 12px; margin: 0 0 8px; line-height: 1.5; font-weight: 500; }
.wd-entities-title a { font-size: 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; /*font-weight: 600;*/ }

.price { display: block; font-size: 13px; color: var(--wd-primary-color); font-weight: 600; padding-right: 20px;}
.price del { color: #999; font-size: 12px;  font-weight: 400; margin-inline-end: 6px; }
.price ins { text-decoration: none; font-size: 13px; }

/* Blog */
.blog-section { margin-bottom: 40px; }
.blog-carousel { display: grid; grid-template-columns: repeat(4,  minmax(0, 1fr)); gap: 20px; align-items: stretch; }
.wd-post {
    background: #fff; border-radius: 10px; overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,.1); transition: transform .2s;
}
.wd-post:hover { transform: translateY(-3px); }
.wd-post-thumb { position: relative; }
.wd-post-thumb img { width: 100%; height: auto; display: block; }
.wd-post-thumb .wd-fill { position: absolute; inset: 0; }
.wd-post-date {
    position: absolute; top: 10px; right: 10px; background: #fff;
    border-radius: 6px; padding: 6px 10px; text-align: center; box-shadow: 0 2px 6px rgba(0,0,0,.1);
}
.wd-post-date .day { display: block; font-size: 18px; font-weight: 700; color: var(--wd-primary-color); }
.wd-post-date .month { display: block; font-size: 10px; }
.wd-post-content { padding: 15px; }
.wd-post-cat { font-size: 11px; color: var(--wd-primary-color); }
.wd-post-content h3 { font-size: 15px; margin: 8px 0; line-height: 1.5; }
.wd-post-meta { font-size: 12px; color: #999; margin-bottom: 10px; }
.wd-post-content p { font-size: 13px; color: #777; line-height: 1.6; }
.read-more { color: var(--wd-primary-color); font-size: 13px; }

/* ============ FOOTER ============ */
.wd-footer { background: #f4f4f4; }
.newsletter-bar { background: #777; color: #fff; padding: 8px; text-align: center; }
.newsletter-bar p { margin: 5px; }
.newsletter-form { display: flex; max-width: 500px; margin: 0 auto; }
.newsletter-form input { flex: 1; padding: 5px 5px; border: 0; border-radius: 4px 0 0 4px; font-family: inherit; }
.newsletter-form button {
    padding: 0 24px; background: var(--wd-primary-color); color: #fff;
    border: 0; border-radius: 0 4px 4px 0; cursor: pointer; font-family: inherit;
}
.success { color: #6ecf8f; margin-top: 10px; }

.footer-widgets { display: grid; grid-template-columns: repeat(4, 1fr) 2fr; gap: 30px; padding: 40px 10px; }
.footer-column h5 { margin: 0 0 5px; font-size: 14px; color: #222; }
.footer-column ul { list-style: none; padding: 0; margin: 0; }
.footer-column li { padding: 2px 0; font-size: 12px; }
.footer-badges img { margin: 5px; }

.wd-copyrights { border-top: 1px solid #ddd; padding-Bottom: 5px; }
.wd-copyrights .container { display: flex; justify-content: space-between; align-items: center; font-size: 13px; }

/* ============ CART SIDEBAR ============ */
.cart-widget-side {
    position: fixed; top: 0; left: 0; width: 380px; max-width: 90vw; height: 100vh;
    background: #fff; z-index: 200; box-shadow: 2px 0 20px rgba(0,0,0,.15);
    transform: translateX(-100%); transition: transform .3s; display: flex; flex-direction: column;
}
.cart-widget-side.wd-opened { transform: translateX(0); }
.wd-heading { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid #eee; }
.wd-heading .title { font-size: 18px; font-weight: 600; }
.close-side-widget { border: 0; background: transparent; cursor: pointer; font-size: 13px; }
.cart_list { list-style: none; margin: 0; padding: 10px; overflow-y: auto; flex: 1; }
.cart-item { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid #f0f0f0; }
.cart-item img { border-radius: 6px; }
.cart-info { flex: 1; }
.cart-info .wd-entities-title { display: block; font-size: 13px; margin-bottom: 4px; }
.cart-info .quantity { font-size: 12px; color: #999; }
.cart-item .remove { border: 0; background: transparent; cursor: pointer; color: #999; font-size: 18px; }
.cart-footer { padding: 15px 20px; border-top: 1px solid #eee; }
.cart-footer .total { margin-bottom: 12px; }
.cart-footer .btn { display: block; width: 100%; margin-bottom: 8px; background: #f7f7f7; }
.cart-footer .btn-color-primary { background: var(--wd-primary-color); color: #fff; }

/* ============ MOBILE NAV ============ */
.mobile-nav {
    position: fixed; top: 0; right: 0; width: 320px; max-width: 90vw; height: 100vh;
    background: #fff; z-index: 200; box-shadow: -2px 0 20px rgba(0,0,0,.15);
    transform: translateX(100%); transition: transform .3s; overflow-y: auto; padding: 16px;
}
.mobile-nav.wd-opened { transform: translateX(0); }
.mobile-menu a, .mobile-categories a { display: block; padding: 10px 0; border-bottom: 1px solid #f0f0f0; }
.mobile-categories h4 { margin: 20px 0 10px; }

/* ============ BOTTOM TOOLBAR (Mobile) ============ */
.wd-toolbar {
    display: none;
    position: fixed; bottom: 0; left: 0; right: 0; height: 60px;
    background: #fff; border-top: 1px solid #eee; z-index: 150;
}
.wd-toolbar .toolbar-item {
    flex: 1; display: flex; flex-direction: column; align-items: center;
    justify-content: center; font-size: 11px; color: #555; gap: 4px;
}
.wd-toolbar .toolbar-item span:first-child { font-size: 18px; }

/* ============ QUICK VIEW ============ */
.wd-quickview-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 300;
    display: flex; align-items: center; justify-content: center; padding: 20px;
}
.wd-quickview-modal {
    background: #fff; border-radius: 10px; padding: 30px; max-width: 800px; width: 100%;
    position: relative; max-height: 90vh; overflow-y: auto;
}
.wd-quickview-content { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; }
.wd-quickview-content img { width: 100%; border-radius: 10px; }
.wd-popup-close {
    position: absolute; top: 10px; left: 10px; border: 0; background: transparent;
    font-size: 24px; cursor: pointer;
}

/* دکمه اسکرول به بالا */
.scrollToTop {
    position: fixed;
    bottom: 30px;
    left: 30px;              /* RTL: چپ */
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #d32f2f;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(0,0,0,.2);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity .25s, visibility .25s, transform .25s, background .2s;
    z-index: 999;
    font-size: 18px;
}
.scrollToTop.is-visible {
    opacity: 0.8;
    visibility: visible;
    transform: translateY(0);
}
.scrollToTop:hover {
    background: #b71c1c;
}
.scrollToTop::before {
    content: "↑";
    font-weight: 700;
    line-height: 1;
}

@media (max-width: 600px) {
    .scrollToTop {
        bottom: 20px;
        left: 20px;
        width: 40px;
        height: 40px;
    }
}

/* Close side overlay */
.wd-close-side { display: none; }
.wd-close-side.wd-fill { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.3); z-index: 150; }

