/* کانتینر اصلی برای مرکز چین کردن */
.pt-dashboard-wrapper {
    display: flex;
    justify-content: flex-start;
    margin-bottom: 40px;
    direction: rtl;
    font-family: inherit;
}

/* استایل کارت (شبیه به عکس) */
.pt-modern-card {
    background: #3380e357;
    border-radius: 24px;
    padding: 30px;
    width: 100%;
    max-width: 420px; /* عرض پیشفرض برای موبایل و تبلت */
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.04), 0 4px 10px rgba(0, 0, 0, 0.02);
    border: 1px solid #f3f4f6;
}

/* هدر (آواتار و نام) */
.pt-card-header {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.pt-avatar {
    width: 44px;
    height: 44px;
    margin-left: 15px; /* فاصله از سمت چپ چون راست‌چین است */
}

.pt-avatar svg {
    width: 100%;
    height: 100%;
}

.pt-username {
    font-size: 20px !important;
    font-weight: 700 !important;
    color: #111827 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
}

/* ردیف‌های آماری */
.pt-stats-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* خط افقی جداکننده ردیف بالا و پایین */
.pt-border-bottom {
    border-bottom: 1px solid #f3f4f6;
    padding-bottom: 25px;
    margin-bottom: 25px;
}

/* هر آیتم آماری */
.pt-stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    text-align: center;
}

/* برای ردیف پایین که عنوان بالا و عدد پایین است */
.pt-stat-item.pt-reverse {
    flex-direction: column;
}

/* خطوط عمودی بین آیتم‌ها */
.pt-has-divider {
    border-right: 1px solid #f3f4f6; /* چون راست‌چین است خط سمت راست می‌افتد */
}

/* مقادیر (اعداد بزرگ) */
.pt-val {
    font-size: 20px;
    font-weight: 700;
    color: #111827;
    line-height: 1.2;
    margin-bottom: 4px;
}

/* برچسب‌ها (متن خاکستری کوچک) */
.pt-lbl {
    font-size: 13px;
    font-weight: 500;
    color: #6b7280;
}

/* برای حالت معکوس ردیف پایین */
.pt-stat-item.pt-reverse .pt-lbl {
    margin-bottom: 8px;
    margin-top: 0;
}
.pt-stat-item.pt-reverse .pt-val {
    margin-bottom: 0;
}

/* رنگ مشکی‌تر برای باقیمانده */
.pt-text-dark {
    color: #000000;
}

/* ---------- استایل دسکتاپ (Responsive) ---------- */
@media (min-width: 768px) {
    .pt-modern-card {
        max-width: 100%; /* در دسکتاپ کارت باز می‌شود */
        display: flex;
        align-items: center;
        padding: 30px 40px;
    }

    .pt-card-header {
        margin-bottom: 0;
        margin-left: 40px;
        min-width: 200px;
    }

    .pt-card-body {
        display: flex;
        flex: 1;
        align-items: center;
        justify-content: space-between;
    }

    .pt-stats-row {
        flex: 1;
    }

    /* در دسکتاپ خط افقی را حذف و به خط عمودی تبدیل می‌کنیم */
    .pt-border-bottom {
        border-bottom: none;
        border-left: 1px solid #f3f4f6;
        padding-bottom: 0;
        margin-bottom: 0;
        padding-left: 30px;
        margin-left: 30px;
    }
}


/* اصلاح فضای خالی و استایل‌های نگهدارنده بالای محصولات */
.shop-before-loop {
    display: block !important;
    min-height: auto !important;
    padding: 0 !important;
    margin: 0 0 20px 0 !important; /* ۲۰ پیکسل فاصله با محصولات پایین ایجاد می‌کند */
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

/* برای اطمینان از اینکه ویجت شما تمام عرض را می‌گیرد و وسط‌چین می‌ماند */
.shop-before-loop .pt-dashboard-wrapper {
    width: 100%;
    margin: 0 auto;
}



/* اصلاحات صفحه محصول */

/* ۱. مخفی کردن کامل شناسه محصول و دسته‌بندی در صفحه سینگل محصول */
.product_meta {
    display: none !important;
}

/* ۲. وسط‌چین کردن کل بخش خلاصه محصول (عنوان، قیمت و...) */
.summary.entry-summary {
    text-align: center !important;
}

/* ۳. وسط‌چین کردن جدول انتخاب متغیرها (انتخاب سانس) */
.summary.entry-summary table.variations {
    margin: 0 auto 20px auto !important;
    width: auto !important;
}

.summary.entry-summary table.variations th,
.summary.entry-summary table.variations td {
    text-align: center !important;
    padding: 5px 10px !important;
}

/* ۴. وسط‌چین کردن، کاهش فاصله دکمه خرید و فیلد تعداد */
.summary.entry-summary .woocommerce-variation-add-to-cart {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    flex-wrap: wrap;
    gap: 5px !important; /* فاصله را بسیار کم کردیم */
    margin-top: 15px;
}

/* نمایش فیلد تعداد به صورت افقی برای افزودن متن */
.summary.entry-summary .quantity {
    display: flex !important;
    align-items: center !important;
    margin: 0 !important;
}
/* افزودن عبارت فقط در صورتی که فیلد عددی (وارد کردن تعداد) درون کادر وجود داشته باشد */
.summary.entry-summary .quantity:has(input[type="number"])::before {
    content: "تعداد بلیط را وارد کنید:";
    margin-left: 8px; /* فاصله متن تا کادر در راست‌چین */
    font-weight: 500;
    font-size: 14px;
    color: #444;
    white-space: nowrap;
}




/* اصلاح استایل فیلد تعداد برای هماهنگی بهتر */
.summary.entry-summary .quantity {
    margin: 0 !important;
}
