/*
Theme Name: Antisa Child
Theme URI: http://www.wpbingosite.com/antisa
Author: wpbingo
Description: This is a child theme for Antisa
Version: 1.3.0
Author URI: http://wpbingosite.com
Template: antisa
Text Domain: antisa-child
*/

/* ============================================================
   ۱. تنظیمات کلی و پرفورمنس (لایت‌اسپید و نمایش عمومی)
   ============================================================ */

/* جلوگیری از اسکرول افقی صفحه */
html,
body {
    max-width: 100%;
    overflow-x: hidden !important;
}

/* مخفی کردن قطعی دکمه‌های نمایش بر اساس ساختار اختصاصی قالب */
.content-top ul.display {
    display: none !important;
}

/* افکت لود تصاویر (مربوط به افزونه LiteSpeed Cache) */
img[data-lazyloaded] {
    opacity: 0;
}
img.litespeed-loaded {
    -webkit-transition: opacity .5s linear .2s;
    -moz-transition: opacity .5s linear .2s;
    transition: opacity .5s linear .2s;
    opacity: 1;
}

/* ============================================================
   ۲. هدر، منوها و عنوان صفحات
   ============================================================ */

/* پس‌زمینه کادر عنوان صفحات با رنگ سفارشی */
div.page-title.bwp-title {
    background-image: none !important;
    background-color: #f6f5f0 !important;
    padding: 25px 0 !important;
    min-height: 0 !important;
    height: auto !important;
}

/* رنگ تیتر اصلی برای خوانایی روی پس‌زمینه روشن */
div.page-title.bwp-title h1.text-title-heading {
    color: #191411 !important;
    margin: 0 !important;
}

/* آیتم‌های منوی جدید */
.menu-new-menu-container ul li {
    padding: 16px;
    font-weight: bolder !important;
}

/* ۳. منوی همبرگری و آف‌کانواس (Off-Canvas)
============================================================ */

/* سایه کانتینر آف‌کانواس */
div#nm-offcanvas {
    box-shadow: 4px 0px 20px 0px #80808063 !important;
}

/* --- نگهدارنده منو در هدر (ادغام آیکون و متن) --- */
.nm-menu-wrapper {
    display: inline-flex;
    align-items: center;
    gap: 8px; /* فاصله بین آیکون و متن */
    white-space: nowrap; /* جلوگیری از شکستن خط و پرش هنگام لود سایت */
    min-height: 24px; /* تثبیت ارتفاع برای جلوگیری از جابجایی */
}

/* دکمه همبرگری (قابل کلیک و مینیمال) */
.nm-hamburger {
    background: none;
    border: none;
    cursor: pointer; /* موس فقط روی آیکون به حالت کلیک در می‌آید */
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px; 
    padding: 0; 
    width: 24px; 
    height: 100%;
}
.nm-hamburger span {
    display: block;
    width: 100%;
    height: 1px; 
    background-color: #191411;
    transition: transform 0.4s cubic-bezier(.22, .9, .24, 1);
}
.nm-hamburger:hover span:nth-child(1) { transform: translateY(-1px); } 
.nm-hamburger:hover span:nth-child(3) { transform: translateY(1px); } 

/* --- استایل کلمه MENU (بدون هاور و غیرقابل کلیک) --- */
.nm-menu-text {
    font-size: 14px; 
    font-weight: 400; 
    text-transform: uppercase;
    letter-spacing: 0.12em; 
    color: #191411;
    line-height: 1; /* جلوگیری از تغییر ارتفاع متن هنگام لود فونت */
    
    /* غیرفعال کردن کامل کلیک، هاور و انتخاب متن */
    pointer-events: none; 
    user-select: none; 
}

/* پنل کشویی منو */
.nm-offcanvas-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 420px;
    max-width: 100vw;
    height: 100vh;
    background-color: #f6f5f0;
    z-index: 999999;
    transform: translateX(-100%);
    visibility: hidden;
    opacity: 0;
    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), visibility 0.7s, opacity 0.7s;
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(25, 20, 17, 0.05);
    box-shadow: none !important;
}
.nm-offcanvas-menu.is-active {
    transform: translateX(0);
    visibility: visible;
    opacity: 1;
}

/* هدر پنل و دکمه بستن */
.nm-offcanvas-header {
    padding: 40px;
    display: flex;
    justify-content: flex-end;
}
.nm-close-menu {
    background: none;
    border: none;
    font-size: 42px;
    font-weight: 300;
    color: #191411;
    cursor: pointer;
    line-height: 1;
    transition: transform 0.4s;
}
.nm-close-menu:hover { transform: rotate(90deg); }

/* لینک‌های داخل منو */
.nm-offcanvas-links {
    padding: 0 60px;
    display: flex;
    flex-direction: column;
    gap: 22px;
    margin-top: 40px;
}
.nm-offcanvas-links a {
    text-decoration: none;
    color: #191411;
    font-size: 15px !important;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    transition: opacity 0.3s, transform 0.3s cubic-bezier(.22, .9, .24, 1);
}
.nm-offcanvas-links a:hover {
    opacity: 0.5;
    transform: translateX(5px);
}
/* ============================================================
   ۴. ووکامرس (لیست محصولات، تب‌ها و دکمه‌های سبد خرید)
   ============================================================ */

/* نگه‌دارنده محصولات در لیست‌ها */
.item-products-wrap.wpb-check {
    justify-content: center;
    display: flex;
    width: 80%;
    align-items: center;
}

/* رنگ سفید متن دکمه‌های سبد خرید و دراپ‌داون‌ها */
button.single_add_to_cart_button.button.alt.ajax-loading,
span.pwb-dropdown-toggle.dropdown-toggle,
button.button.btn.btn-primary.buy-together-add-all-to-cart {
    color: #fff !important;
}

/* مخفی کردن تب نظرات */
li#tab-title-reviews {
    display: none;
}

/* نگه‌دارنده دکمه‌های متغیر (قیمت و افزودن به سبد خرید) */
.single_variation_wrap {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

/* ============================================================
   ۵. متغیرهای محصول — سواچ‌های سایز و رنگ
   ------------------------------------------------------------
   فلسفه این بخش: ما فقط «شکل، ابعاد و چیدمان» را کنترل می‌کنیم؛
   «رنگ‌ها» (حالت انتخاب‌شده و هاور) از خود قالب ارث‌بری می‌شود.
   هیچ background-color یا color روی حالت selected تنظیم نکنید.
   ============================================================ */

/* --- ۵.۱) ساختار جدول متغیرها: لیبل بالای سواچ‌ها و چپ‌چین
   (مشابه مرجع: Color و Size به‌عنوان تیتر بالای هر ردیف) --- */
form.variations_form table.variations,
form.variations_form table.variations tbody {
    display: block !important;
    width: 100% !important;
}
form.variations_form table.variations tr {
    display: block !important;
    width: 100% !important;
    margin: 0 0 18px 0 !important;
    text-align: left !important;
}
form.variations_form table.variations td {
    display: block !important;
    width: 100% !important;
    text-align: left !important;
}

/* لیبل ردیف‌ها (Color / Size) */
form.variations_form table.variations td.label {
    display: block !important;
    padding: 0 0 10px 0 !important;
    border: none !important;
    background: transparent !important;
}
form.variations_form table.variations td.label label {
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #191411 !important;
    text-transform: capitalize !important;
    letter-spacing: 0.02em;
    margin: 0 !important;
    display: inline-block !important;
}

/* --- ۵.۲) ریست سلول مقدارها (حذف کادر و پس‌زمینه‌های مزاحم) --- */
tr.type_attribute.select {
    width: 100%;
}
table.variations td.value,
tr.type_attribute.select td.value,
div.tawcvs-swatches,
tr.type_attribute.select,
table.variations tr {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
    border-radius: 0 !important;
}

/* سواچ‌ها از چپ شروع شوند (نه وسط‌چین) */
form.variations_form table.variations td.value .tawcvs-swatches {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: flex-start !important;
    align-items: center !important;
    text-align: left !important;
}

/* --- ۵.۳) حذف قطعی هر نوع گردی (بمب specificity)
   تکرار کلاس‌ها عمدی است تا بر رول‌های !important قالب غلبه کند.
   این بلاک را کوتاه یا ساده نکنید. --- */
html body .tawcvs-swatches.tawcvs-swatches.tawcvs-swatches.tawcvs-swatches .swatch.swatch.swatch,
html body .tawcvs-swatches.tawcvs-swatches.tawcvs-swatches.tawcvs-swatches .swatch-item-wrapper,
html body .tawcvs-swatches.tawcvs-swatches.tawcvs-swatches.tawcvs-swatches [class*="swatch"] {
    border-radius: 0 !important;
    -webkit-border-radius: 0 !important;
}

/* --- ۵.۴) حذف گردی و سایه روی سواچ و متن داخلی --- */
form.variations_form table.variations td.value .tawcvs-swatches .swatch-item-wrapper,
form.variations_form table.variations td.value .tawcvs-swatches .swatch,
form.variations_form table.variations td.value .tawcvs-swatches .swatch-shape-circle,
form.variations_form table.variations td.value .tawcvs-swatches .swatch-label,
form.variations_form table.variations td.value .tawcvs-swatches .swatch .text {
    border-radius: 0 !important;
    -webkit-border-radius: 0 !important;
    overflow: visible !important;
    box-shadow: none !important;
}

/* --- ۵.۵) آزاد کردن wrapper از ابعاد و حاشیه دایره‌ای قالب --- */
form.variations_form table.variations td.value .tawcvs-swatches .swatch-item-wrapper {
    width: auto !important;
    height: auto !important;
    min-width: 0 !important;
    min-height: 0 !important;
    border: none !important;
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
    display: inline-block !important;
    overflow: visible !important;
}

/* --- ۵.۶) حذف حلقه‌های ساخته‌شده با ::before و ::after --- */
form.variations_form table.variations td.value .tawcvs-swatches .swatch::before,
form.variations_form table.variations td.value .tawcvs-swatches .swatch::after,
form.variations_form table.variations td.value .tawcvs-swatches .swatch-item-wrapper::before,
form.variations_form table.variations td.value .tawcvs-swatches .swatch-item-wrapper::after {
    content: none !important;
    display: none !important;
    border: none !important;
    opacity: 0 !important;
}

/* --- ۵.۷) سواچ سایز: مستطیل مینیمال
   فقط ابعاد و چیدمان؛ رنگ‌ها با خود قالب. --- */
form.variations_form table.variations td.value .tawcvs-swatches .swatch-type-label {
    width: 65px !important;
    height: 45px !important;
    min-width: 65px !important;
    min-height: 45px !important;
    line-height: 1 !important;
    border-width: 1px !important;
    border-style: solid !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 8px 8px 0 !important;
    padding: 0 !important;
    font-size: 14px !important;
    cursor: pointer;
    box-sizing: border-box !important;
    position: relative !important;
    z-index: 1;
}

/* --- ۵.۸) رفع باگ «حذف شدن یک ضلع کادر» در حالت انتخاب:
   قالب برای حالت selected ضخامت بردر را تغییر می‌دهد/با
   pseudo-element خط می‌کشد که ما حذفش کرده‌ایم؛ در نتیجه کادر
   ناقص رندر می‌شد. اینجا کادر انتخاب را خودمان با outline کامل
   می‌کشیم. outline خارج از باکس رندر می‌شود، هر ۴ ضلع را
   تضمین می‌کند و جای المنت‌ها را هم به‌هم نمی‌ریزد.
   رنگ آن currentColor است، یعنی از رنگ متن قالب ارث‌بری می‌شود
   و هیچ رنگ ثابتی تحمیل نمی‌کنیم. --- */
form.variations_form table.variations td.value .tawcvs-swatches .swatch-type-label.selected {
    border-width: 1px !important;
    border-style: solid !important;
    outline: 1px solid currentColor !important;
    outline-offset: -1px !important;
    z-index: 2;
}

/* --- ۵.۹) سواچ رنگ: مربع با حاشیه سفید داخلی
   رنگ حاشیه از قالب ارث‌بری می‌شود؛ فقط شکل و ابعاد اینجاست. --- */
form.variations_form table.variations td.value .tawcvs-swatches .swatch-type-color {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    min-height: 32px !important;
    box-shadow: inset 0 0 0 2px #ffffff !important;
    margin: 0 8px 8px 0 !important;
    border-radius: 0 !important;
    padding: 0 !important;
    cursor: pointer;
    box-sizing: border-box !important;
}

/* --- ۵.۱۰) فاصله‌گذاری کلی نگه‌دارنده سواچ‌ها --- */
.tawcvs-swatches.oss- {
    margin-right: 0 !important;
    margin-bottom: 0 !important;
    margin-top: 10px !important;
}

.single-product .product_meta { display: none !important; }