/**
 * Pileh Product UI
 * Product Vertical Tabs
 * File: assets/css/tabs.css
 * Version: 1.0.0
 */

/* رنگ‌ها و تنظیمات اصلی */
:root {
    --pileh-tab-green: #064a31;
    --pileh-tab-green-hover: #006837;
    --pileh-tab-green-light: #f2f8f5;
    --pileh-tab-text: #303633;
    --pileh-tab-border: #e3eae6;
    --pileh-tab-background: #ffffff;
    --pileh-tab-radius: 18px;
}

/* چیدمان کلی */
.single-product .pileh-tabs {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    gap: 30px;
    align-items: start;
    width: 100%;
    direction: rtl;
}

/* ستون منو */
.single-product .pileh-sidebar {
    width: 100%;
    min-width: 0;
}

/* حذف ظاهر پیش‌فرض منوی وودمارت */
.single-product .pileh-sidebar .wd-nav-wrapper {
    width: 100%;
    margin: 0;
}

.single-product .pileh-sidebar .wc-tabs {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 9px;

    width: 100%;
    margin: 0 !important;
    padding: 10px !important;

    list-style: none;

    background: var(--pileh-tab-background);
    border: 1px solid var(--pileh-tab-border);
    border-radius: var(--pileh-tab-radius);

    box-shadow: 0 10px 30px rgba(6, 74, 49, 0.06);
}

/* حذف خطوط تزئینی پیش‌فرض */
.single-product .pileh-sidebar .wc-tabs::before,
.single-product .pileh-sidebar .wc-tabs::after {
    display: none !important;
    content: none !important;
}

/* هر آیتم منو */
.single-product .pileh-sidebar .wc-tabs > li {
    display: block;
    width: 100%;
    margin: 0 !important;
    padding: 0 !important;

    background: transparent !important;
    border: 0 !important;
}

/* لینک هر تب */
.single-product .pileh-sidebar .wc-tabs > li > a {
    position: relative;

    display: flex !important;
    align-items: center;
    gap: 12px;

    width: 100%;
    min-height: 56px;

    padding: 13px 17px !important;

    color: var(--pileh-tab-text) !important;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.6;
    text-align: right;

    background: transparent;
    border: 1px solid transparent;
    border-radius: 13px;

    box-shadow: none !important;

    transition:
        background-color 0.25s ease,
        border-color 0.25s ease,
        color 0.25s ease,
        transform 0.25s ease;
}

/* حذف خط زیر تب وودمارت */
.single-product .pileh-sidebar .wc-tabs > li > a::after {
    display: none !important;
}

/* هاور */
.single-product .pileh-sidebar .wc-tabs > li > a:hover {
    color: var(--pileh-tab-green) !important;
    background: var(--pileh-tab-green-light);
    border-color: #d7e7df;

    transform: translateX(-3px);
}

/* تب فعال */
.single-product .pileh-sidebar .wc-tabs > li.active > a {
    color: var(--pileh-tab-green) !important;
    font-weight: 700;

    background: var(--pileh-tab-green-light);
    border-color: #cfe2d8;
}

/* نوار سبز کنار تب فعال */
.single-product .pileh-sidebar .wc-tabs > li.active > a::after {
    position: absolute;
    top: 10px;
    right: -1px;
    bottom: 10px;

    display: block !important;
    width: 4px;

    content: "";

    background: var(--pileh-tab-green);
    border-radius: 5px 0 0 5px;
}

/* آیکون مشترک */
.single-product .pileh-sidebar .wc-tabs > li > a::before {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 24px;
    width: 24px;
    height: 24px;

    color: currentColor;

    font-family: FontAwesome;
    font-size: 18px;
    font-style: normal;
    font-weight: normal;
    text-align: center;

    opacity: 0.85;
}

/* آیکون توضیحات */
.single-product
    .pileh-sidebar
    .description_tab
    > a::before {
    content: "\f0f6";
}

/* آیکون ارسال */
.single-product
    .pileh-sidebar
    .shipping_tab
    > a::before,
.single-product
    .pileh-sidebar
    .wd_additional_tab_tab
    > a::before {
    content: "\f0d1";
}

/* آیکون نظرات */
.single-product
    .pileh-sidebar
    .reviews_tab
    > a::before {
    content: "\f0e6";
}

/* آیکون فروشنده */
.single-product
    .pileh-sidebar
    .seller_tab
    > a::before {
    content: "\f007";
}

/* آیکون محصولات بیشتر */
.single-product
    .pileh-sidebar
    .more_seller_product_tab
    > a::before {
    content: "\f009";
}

/* محتوای سمت چپ */
.single-product .pileh-content {
    width: 100%;
    min-width: 0;
    min-height: 250px;

    padding: 35px 38px;

    background: var(--pileh-tab-background);
    border: 1px solid var(--pileh-tab-border);
    border-radius: var(--pileh-tab-radius);

    box-shadow: 0 10px 30px rgba(6, 74, 49, 0.06);
}

/* حذف ظاهر آکاردئونی از پنل‌ها */
.single-product
    .pileh-content
    .woocommerce-Tabs-panel {
    width: 100%;
    margin: 0 !important;
    padding: 0 !important;

    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;

    animation: pilehTabFade 0.3s ease;
}

/* محتوای داخلی */
.single-product .pileh-content .wc-tab-inner {
    padding: 0 !important;
}

/* عنوان اولین بخش */
.single-product .pileh-content h2:first-child,
.single-product .pileh-content h3:first-child {
    margin-top: 0;
}

/* آخرین پاراگراف */
.single-product .pileh-content p:last-child {
    margin-bottom: 0;
}

/* تصاویر داخل تب */
.single-product .pileh-content img {
    max-width: 100%;
    height: auto;
}

/* تب فروشنده */
.single-product
    .pileh-content
    .woocommerce-Tabs-panel--seller
    ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.single-product
    .pileh-content
    .woocommerce-Tabs-panel--seller
    li {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;

    padding: 12px 0;

    border-bottom: 1px solid var(--pileh-tab-border);
}

.single-product
    .pileh-content
    .woocommerce-Tabs-panel--seller
    li:last-child {
    border-bottom: 0;
}

/* انیمیشن نمایش محتوا */
@keyframes pilehTabFade {
    from {
        opacity: 0;
        transform: translateY(7px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* تبلت و موبایل */
@media (max-width: 992px) {
    .single-product .pileh-tabs {
        display: block;
    }

    .single-product .pileh-sidebar {
        margin-bottom: 18px;
    }

    .single-product .pileh-sidebar .wc-tabs {
        flex-direction: row !important;

        overflow-x: auto;
        overflow-y: hidden;

        padding: 8px !important;

        scrollbar-width: thin;
    }

    .single-product .pileh-sidebar .wc-tabs > li {
        flex: 0 0 auto;
        width: auto;
    }

    .single-product .pileh-sidebar .wc-tabs > li > a {
        width: auto;
        min-height: 48px;

        padding: 10px 14px !important;

        white-space: nowrap;
    }

    .single-product
        .pileh-sidebar
        .wc-tabs
        > li.active
        > a::after {
        top: auto;
        right: 14px;
        bottom: -1px;
        left: 14px;

        width: auto;
        height: 3px;

        border-radius: 3px 3px 0 0;
    }

    .single-product .pileh-content {
        min-height: 180px;
        padding: 25px 21px;
    }
}

/* موبایل کوچک */
@media (max-width: 575px) {
    .single-product .pileh-content {
        padding: 21px 16px;
        border-radius: 15px;
    }
}