
/**
 * BuyTuga Product Tabs Organizer
 * Organiza os separadores Descrição / Especificações / Avaliações no produto.
 */

body.single-product .woocommerce-tabs,
body.single-product .wc-tabs-wrapper,
body.single-product div.product .woocommerce-tabs {
    clear: both;
    width: 100%;
    max-width: 1120px;
    margin: 48px auto 56px;
    padding: 0 18px;
    box-sizing: border-box;
}

/* Barra dos separadores */
body.single-product .woocommerce-tabs ul.tabs,
body.single-product div.product .woocommerce-tabs ul.tabs,
body.single-product .wc-tabs {
    display: flex !important;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 10px;
    list-style: none !important;
    margin: 0 auto 24px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    text-align: center;
}

body.single-product .woocommerce-tabs ul.tabs::before,
body.single-product .woocommerce-tabs ul.tabs::after,
body.single-product div.product .woocommerce-tabs ul.tabs::before,
body.single-product div.product .woocommerce-tabs ul.tabs::after {
    display: none !important;
}

/* Item do separador */
body.single-product .woocommerce-tabs ul.tabs li,
body.single-product div.product .woocommerce-tabs ul.tabs li,
body.single-product .wc-tabs li {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    float: none !important;
    position: relative !important;
}

/* Link do separador */
body.single-product .woocommerce-tabs ul.tabs li a,
body.single-product div.product .woocommerce-tabs ul.tabs li a,
body.single-product .wc-tabs li a {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 11px 22px !important;
    border-radius: 999px;
    border: 1px solid #e3e8ef;
    background: #ffffff;
    color: #0f2742 !important;
    font-size: 15px;
    font-weight: 700 !important;
    line-height: 1.2;
    text-decoration: none !important;
    box-shadow: 0 4px 14px rgba(15, 39, 66, 0.06);
    transition: transform .18s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease;
}

body.single-product .woocommerce-tabs ul.tabs li a:hover,
body.single-product div.product .woocommerce-tabs ul.tabs li a:hover,
body.single-product .wc-tabs li a:hover {
    transform: translateY(-1px);
    border-color: #ffc400;
    box-shadow: 0 8px 20px rgba(15, 39, 66, 0.10);
}

/* Separador ativo */
body.single-product .woocommerce-tabs ul.tabs li.active a,
body.single-product div.product .woocommerce-tabs ul.tabs li.active a,
body.single-product .wc-tabs li.active a {
    background: #ffc400 !important;
    border-color: #ffc400 !important;
    color: #10243d !important;
}

/* Painel de conteúdo */
body.single-product .woocommerce-tabs .panel,
body.single-product div.product .woocommerce-tabs .panel,
body.single-product .woocommerce-Tabs-panel {
    width: 100% !important;
    max-width: 1060px;
    margin: 0 auto !important;
    padding: 30px 34px !important;
    border: 1px solid #eef2f6;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 10px 30px rgba(15, 39, 66, 0.06);
    color: #1b2b3d;
    box-sizing: border-box;
    text-align: left;
}

/* Títulos internos do painel */
body.single-product .woocommerce-tabs .panel > h2:first-child,
body.single-product .woocommerce-Tabs-panel > h2:first-child {
    margin-top: 0;
    margin-bottom: 18px;
    color: #0f2742;
    font-size: 22px;
    line-height: 1.25;
}

/* Texto da descrição */
body.single-product .woocommerce-tabs .panel p,
body.single-product .woocommerce-Tabs-panel p {
    font-size: 15px;
    line-height: 1.75;
    color: #24364a;
    margin: 0 0 14px;
}

body.single-product .woocommerce-tabs .panel strong,
body.single-product .woocommerce-Tabs-panel strong,
body.single-product .woocommerce-tabs .panel b,
body.single-product .woocommerce-Tabs-panel b {
    color: #0f2742;
    font-weight: 800;
}

/* Listas e características */
body.single-product .woocommerce-tabs .panel ul,
body.single-product .woocommerce-Tabs-panel ul {
    margin: 12px 0 18px 22px;
    padding: 0;
}

body.single-product .woocommerce-tabs .panel li,
body.single-product .woocommerce-Tabs-panel li {
    margin-bottom: 8px;
    line-height: 1.65;
}

/* Tabela de especificações WooCommerce */
body.single-product .woocommerce-product-attributes {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    overflow: hidden;
    border: 1px solid #eef2f6;
    border-radius: 14px;
}

body.single-product .woocommerce-product-attributes th,
body.single-product .woocommerce-product-attributes td {
    padding: 13px 16px !important;
    border: 0 !important;
    border-bottom: 1px solid #eef2f6 !important;
    background: #fff !important;
    font-size: 14px;
    line-height: 1.55;
}

body.single-product .woocommerce-product-attributes tr:last-child th,
body.single-product .woocommerce-product-attributes tr:last-child td {
    border-bottom: 0 !important;
}

body.single-product .woocommerce-product-attributes th {
    width: 32%;
    color: #0f2742;
    font-weight: 800;
    background: #f7f9fc !important;
}

/* Avaliações */
body.single-product #reviews {
    max-width: 100%;
}

body.single-product #reviews #comments,
body.single-product #reviews #review_form_wrapper {
    margin-top: 18px;
}

body.single-product #review_form input,
body.single-product #review_form textarea {
    border-radius: 10px;
    border: 1px solid #dbe3ec;
    padding: 10px 12px;
}

/* Remove estilos antigos que deixam tabs em coluna/sem organização */
body.single-product .woocommerce-tabs ul.tabs li::before,
body.single-product .woocommerce-tabs ul.tabs li::after {
    display: none !important;
}

/* Mobile */
@media (max-width: 768px) {
    body.single-product .woocommerce-tabs,
    body.single-product .wc-tabs-wrapper,
    body.single-product div.product .woocommerce-tabs {
        margin: 34px auto 42px;
        padding: 0 12px;
    }

    body.single-product .woocommerce-tabs ul.tabs,
    body.single-product div.product .woocommerce-tabs ul.tabs,
    body.single-product .wc-tabs {
        gap: 8px;
        justify-content: stretch;
    }

    body.single-product .woocommerce-tabs ul.tabs li,
    body.single-product div.product .woocommerce-tabs ul.tabs li,
    body.single-product .wc-tabs li {
        flex: 1 1 100%;
    }

    body.single-product .woocommerce-tabs ul.tabs li a,
    body.single-product div.product .woocommerce-tabs ul.tabs li a,
    body.single-product .wc-tabs li a {
        width: 100%;
        padding: 12px 14px !important;
        box-sizing: border-box;
    }

    body.single-product .woocommerce-tabs .panel,
    body.single-product div.product .woocommerce-tabs .panel,
    body.single-product .woocommerce-Tabs-panel {
        padding: 22px 18px !important;
        border-radius: 14px;
    }

    body.single-product .woocommerce-product-attributes th,
    body.single-product .woocommerce-product-attributes td {
        display: block;
        width: 100%;
        box-sizing: border-box;
    }
}
