@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@400;700&display=swap');
body.in-pwa{padding-bottom:70px!important;font-family:'Vazirmatn',sans-serif!important;background:#e9ecf1!important;background-image:linear-gradient(135deg,#f5f7fa 0%,#c3cfe2 100%)!important;overflow-x:hidden!important}body.in-pwa header.wp-block-template-part,body.in-pwa footer.wp-block-template-part{display:none!important}body.in-pwa main.wp-block-group{margin-top:0!important;padding:15px!important;background:none!important}.woocommerce ul.products[class*="columns"]{display:grid!important;grid-template-columns:1fr!important;gap:15px!important}.woocommerce ul.products li.product{width:100%!important;float:none!important;margin:0!important;padding:0!important;list-style:none!important;border:none!important;background:none!important;box-shadow:none!important;grid-column:auto!important}.woocommerce ul.products li.product>*:not(.product-card){display:none!important}.woocommerce ul.products li.product .product-card{display:flex!important}.product-card{width:100%;border-radius:16px!important;border:1px solid rgba(255,255,255,0.4)!important;background:rgba(255,255,255,0.6)!important;backdrop-filter:blur(12px)!important;-webkit-backdrop-filter:blur(12px)!important;box-shadow:0 8px 32px 0 rgba(0,0,0,0.1)!important;display:flex;justify-content:space-between;align-items:center;padding:20px!important;font-family:'Vazirmatn',sans-serif;box-sizing:border-box}.product-card .product-title{font-size:16px!important;font-weight:700!important;color:#1a202c;margin:0 0 10px 0}.product-card .product-meta{display:flex;flex-direction:column;align-items:flex-start;gap:5px;font-size:14px;color:#4a5568}.product-card .product-price ins{text-decoration:none}.product-card .product-price .woocommerce-Price-amount{font-weight:700!important;color:#2d3748}.product-card .card-actions{display:flex;flex-direction:column;align-items:center;gap:10px}.product-card .raymand-qty-input{width:70px;height:40px;text-align:center;border:1px solid #cbd5e0;border-radius:8px;padding:8px;font-size:16px;box-sizing:border-box}.product-card .raymand-add-to-cart-button{display:inline-block!important;border-radius:8px!important;padding:10px 20px!important;font-weight:700!important;font-size:14px!important;background-color:#3182ce!important;color:white!important;border:none!important;transition:background-color .2s}.product-card .raymand-add-to-cart-button:hover{background-color:#2b6cb0!important}.product-card .raymand-add-to-cart-button.added_to_cart{background-color:#38a169!important}.product-card .out-of-stock-label{color:#e53e3e;font-weight:700}.raymand-bottom-nav{position:fixed;bottom:0;left:0;right:0;height:60px;background-color:#fff;border-top:1px solid #e0e0e0;display:flex;justify-content:space-around;align-items:center;z-index:1000;box-shadow:0 -2px 5px rgba(0,0,0,0.05)}.raymand-bottom-nav .nav-item{display:flex;flex-direction:column;align-items:center;justify-content:center;text-decoration:none;color:#888;flex-grow:1}.raymand-bottom-nav .nav-item .icon{font-size:24px}.raymand-bottom-nav .nav-item .label{font-size:12px;margin-top:2px;font-family:'Vazirmatn',sans-serif!important}.raymand-bottom-nav .nav-item.active{color:#000}
/* --- استایل های جدید و نهایی برای صفحه لاگین --- */

/* کنترل کامل body برای حذف اسکرول */
body.raymand-login-page,
body.raymand-login-page html {
    overflow: hidden !important; 
    touch-action: none; 
    margin: 0 !important; 
    padding: 0 !important;
}

body.raymand-login-page main.wp-block-group {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* کانتینر اصلی تمام صفحه با گرادیانت و لوگوی پس زمینه */
.raymand-login-container {
    width: 100vw;
    height: 100vh;
    display: flex;
    top: 0;
    left: 0;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background-color: #f0f2f5;
    background-image: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-sizing: border-box;
    position: fixed; /* برای جایگذاری لوگوی پس زمینه */
    overflow: hidden;
}

/* لوگوی محو در پس زمینه */
.raymand-login-container::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    max-width: 300px;
    height: 300px;
    background-image: linear-gradient(135deg, #667eea 0%, #764ba2 100%); /* لوگو را از ریشه پلاگین می خواند */
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.08; /* بسیار محو */
    z-index: 1;
}

/* کارت شیشه ای ورود با انیمیشن */
.login-card {
    position: relative;
    z-index: 2; /* روی لوگوی پس زمینه قرار می گیرد */
    width: 100%;
    max-width: 400px;
    padding: 40px 30px;
    background: rgba(255, 255, 255, 0.25); /* شیشه ای تر */
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-radius: 20px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    /* انیمیشن ورود */
    animation: slideUpFadeIn 0.7s ease-out forwards;
}

/* تعریف انیمیشن */
@keyframes slideUpFadeIn {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* عنوان فرم */
.form-title {
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    color: #fff; /* رنگ سفید برای خوانایی روی پس زمینه تیره */
    text-shadow: 0 1px 3px rgba(0,0,0,0.2);
    margin-bottom: 25px;
}

/* ردیف های فرم */
.raymand-login-form .form-row {
    margin-bottom: 20px;
}
.raymand-login-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #f7fafc;
    font-size: 14px;
}

/* فیلدهای ورودی با ظاهر شیشه ای */
.raymand-login-form .input-text {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 8px;
    font-size: 16px;
    box-sizing: border-box;
    background: rgba(255, 255, 255, 0.15); /* پس زمینه نیمه شفاف */
    color: #fff;
    transition: all 0.2s;
}
.raymand-login-form .input-text::placeholder {
    color: rgba(255, 255, 255, 0.6);
}
.raymand-login-form .input-text:focus {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.8);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.2);
    outline: none;
}

/* دکمه ورود */
.raymand-login-form .button {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    background-color: #fff;
    color: #667eea;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}
.raymand-login-form .button:hover {
    background-color: #f0f2f5;
    transform: translateY(-2px);
}
.raymand-login-form .button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

/* --- استایل های داشبورد حساب کاربری --- */

.raymand-dashboard {
    padding: 20px 10px;
    text-align: center;
}
.dashboard-header h1 {
    font-size: 28px; font-weight: 700;
    margin-bottom: 8px; color: #1a202c;
}
.dashboard-header p {
    font-size: 16px; color: #4a5568; margin-bottom: 30px;
}
.dashboard-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 20px;
}
.dashboard-card {
    display: flex; flex-direction: column; align-items: center;
    justify-content: center; text-decoration: none; padding: 20px;
    min-height: 120px; border-radius: 16px; transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.6); backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px); box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
}
.dashboard-card:hover {
    transform: translateY(-5px); box-shadow: 0 12px 35px 0 rgba(0, 0, 0, 0.15);
}
.dashboard-card .card-icon { font-size: 36px; margin-bottom: 10px; }
.dashboard-card .card-label { font-size: 14px; font-weight: 700; color: #2d3748; }
/* زمانی که داشبورد سفارشی ما فعال است... */
body.raymand-dashboard-active .woocommerce-MyAccount-navigation {
    display: none !important; /* منوی کناری پیش فرض را کاملا مخفی کن */
}

body.raymand-dashboard-active .woocommerce-MyAccount-content {
    width: 100% !important; /* محتوای اصلی را تمام عرض کن */
}

/* استایل برای لودر */
.raymand-loader {
    border: 5px solid #f3f3f3;
    border-top: 5px solid #3498db;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 50px auto;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* ======================================================= */
/* ====== اصلاحات جدید برای صفحه فروشگاه (قالب بلاک) ====== */
/* ======================================================= */

/* مرحله 1: مخفی کردن تمام اجزای پیش فرض کارت محصول ووکامرس */
ul.wc-block-product-template li.product>* {
    display: none;
}

/* مرحله 2: نمایش دادن فقط کارت سفارشی ما */
ul.wc-block-product-template li.product>.product-card {
    display: flex;
    /* یا display: block بسته به نیاز طراحی */
    width: 100%;
}

/* مرحله 3: تک ستونه کردن محصولات در صفحات موبایل */
@media (max-width: 782px) {
    ul.wc-block-product-template {
        /* این خط گرید را مجبور به نمایش یک ستون می کند */
        grid-template-columns: 1fr !important;
    }
}

/* ======================================================= */
/* ====== استایل های جدید برای هدر صفحه فروشگاه (نهایی) ====== */
/* ======================================================= */

/* 1. مخفی کردن کامل Breadcrumbs و ردیف مرتب سازی */
.wc-block-breadcrumbs,
.wp-block-woocommerce-catalog-sorting,
.wc-block-product-results-count {
    display: none !important;
}

/* 2. استایل کانتینر اصلی فرم جستجو */
.raymand-product-search-container {
    margin-bottom: 25px;
}

/* 3. استایل خود فرم */
.raymand-product-search-form {
    position: relative; /* برای قرارگیری آیکون در داخل */
    width: 100%;
}

/* 4. استایل فیلد ورودی جستجو */
.raymand-search-field {
    width: 100%;
    height: 50px;
    padding: 10px 45px 10px 20px; /* فضای کافی برای آیکون در سمت راست (برای RTL) */
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    background-color: #ffffff;
    font-size: 16px;
    font-family: 'Vazirmatn', sans-serif;
    transition: all 0.2s ease-in-out;
    box-sizing: border-box;
    -webkit-appearance: none;
}

.raymand-search-field:focus {
    border-color: #3182ce;
    box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.2);
    outline: none;
}

/* 5. استایل کانتینر آیکون */
.search-icon-wrapper {
    position: absolute;
    top: 0;
    right: 0; /* آیکون در سمت راست برای زبان فارسی */
    height: 100%;
    width: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none; /* اجازه می دهد کلیک از روی آیکون عبور کند */
}

/* 6. استایل خود آیکون */
.search-icon {
    color: #a0aec0; /* رنگ خاکستری برای آیکون */
}

/* ======================================================= */
/* ====== استایل نهایی و مدرن برای کارت محصول ====== */
/* ======================================================= */

/* 1. بازنویسی استایل اصلی آیتم محصول */
ul.wc-block-product-template li.product {
    padding: 0 !important;
    border: none !important;
    background: none !important;
    box-shadow: none !important;
    margin: 0 !important;
}

/* 2. استایل کانتینر اصلی کارت محصول (.product-card) */
.product-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
    padding: 20px;
    display: flex;
    flex-direction: column; /* چیدمان عمودی برای محتوا و اقدامات */
    justify-content: space-between;
    height: 100%; /* برای هم قد شدن کارت ها در یک ردیف */
}

/* 3. استایل بخش محتوا (عنوان، قیمت، موجودی) */
.product-card .card-content {
    flex-grow: 1; /* این بخش تا جای ممکن فضا را اشغال می کند */
    margin-bottom: 20px; /* فاصله با بخش اقدامات */
}

.product-card .product-title {
    font-size: 17px !important;
    font-weight: 700 !important;
    color: #1a202c;
    margin: 0 0 12px 0 !important;
}

.product-card .product-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: #4a5568;
}

.product-card .product-price .woocommerce-Price-amount {
    font-weight: 700 !important;
    color: #2d3748;
}

/* 4. استایل بخش اقدامات (فرم افزودن به سبد خرید) */
.product-card .card-actions {
    margin-top: auto; /* این بخش را به پایین کارت می چسباند */
}

/* فرم ووکامرس را تمام عرض و flex می کنیم */
.product-card form.cart {
    display: flex;
    width: 100%;
    margin: 0 !important;
}

/* مخفی کردن لیبل فیلد تعداد */
.product-card form.cart .quantity label {
    display: none;
}

/* استایل فیلد ورودی تعداد */
.product-card form.cart .quantity input.qty {
    height: 44px;
    width: 60px;
    text-align: center;
    border: 1px solid #cbd5e0;
    border-left: none; /* حذف بردر چپ برای چسبیدن به دکمه */
    border-radius: 0;
    border-top-right-radius: 8px; /* گرد کردن گوشه بالا-راست */
    border-bottom-right-radius: 8px; /* گرد کردن گوشه پایین-راست */
    padding: 8px;
    font-size: 16px;
    box-sizing: border-box;
    min-width: 60px; /* جلوگیری از کوچک شدن بیش از حد */
    -moz-appearance: textfield; /* حذف فلش های بالا/پایین در فایرفاکس */
}
/* حذف فلش های بالا/پایین در کروم و سافاری */
.product-card form.cart .quantity input.qty::-webkit-outer-spin-button,
.product-card form.cart .quantity input.qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ======================================================= */
/* ====== استایل نهایی کارت محصول (با سلکتورهای قوی) ====== */
/* ======================================================= */

/* افزایش قدرت سلکتورها با استفاده از کلاس والد */

.woocommerce-shop ul.wc-block-product-template li.product {
    padding: 0 !important;
    border: none !important;
    background: none !important;
    box-shadow: none !important;
    margin: 0 !important;
}

.woocommerce-shop .product-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    width: 100%; /* اطمینان از تمام عرض بودن کارت */
}

.woocommerce-shop .product-card .card-content {
    flex-grow: 1;
    margin-bottom: 20px;
}

.woocommerce-shop .product-card .product-title {
    font-size: 17px !important;
    font-weight: 700 !important;
    color: #1a202c;
    margin: 0 0 12px 0 !important;
}

.woocommerce-shop .product-card .product-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: #4a5568;
}

.woocommerce-shop .product-card .product-price .woocommerce-Price-amount {
    font-weight: 700 !important;
    color: #2d3748;
}

.woocommerce-shop .product-card .card-actions {
    margin-top: auto;
}

.woocommerce-shop .product-card form.cart {
    display: flex;
    width: 100%;
    margin: 0 !important;
    gap: 10px;
}

.woocommerce-shop .product-card form.cart .quantity label {
    display: none;
}

.woocommerce-shop .product-card form.cart .quantity input.qty {
    height: 44px;
    width: 70px !important; /* !important برای غلبه بر استایل های احتمالی */
    text-align: center;
    border: 1px solid #cbd5e0 !important;
    border-radius: 12px !important;
    padding: 8px !important;
    font-size: 16px !important;
    background-color: #f7fafc !important;
    box-sizing: border-box;
    -moz-appearance: textfield;
}

.woocommerce-shop .product-card form.cart .quantity input.qty::-webkit-outer-spin-button,
.woocommerce-shop .product-card form.cart .quantity input.qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.woocommerce-shop .product-card .quantity input.qty:focus {
    border-color: #3182ce !important;
    box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.2) !important;
    outline: none;
}

.woocommerce-shop .product-card form.cart button.single_add_to_cart_button {
    flex-grow: 1;
    height: 44px;
    border-radius: 12px !important;
    background-color: #3182ce !important;
    color: white !important;
    font-weight: 700 !important;
    font-size: 14px !important;
    border: none !important;
    box-shadow: 0 4px 14px 0 rgba(49, 130, 206, 0.3) !important;
    transition: all 0.2s ease-in-out;
    white-space: nowrap;
    padding: 10px 20px !important; /* اضافه کردن پدینگ برای اطمینان */
    line-height: normal !important; /* برای ترازبندی عمودی متن */
}

.woocommerce-shop .product-card form.cart button.single_add_to_cart_button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 rgba(49, 130, 206, 0.25) !important;
}

.woocommerce-shop .product-card form.cart button.single_add_to_cart_button.loading,
.woocommerce-shop .product-card form.cart button.single_add_to_cart_button.added {
    transform: translateY(0);
    box-shadow: none !important;
}

.woocommerce-shop .product-card form.cart button.single_add_to_cart_button.added {
    background-color: #38a169 !important;
}