/* --- 1. TOP SPACING - FORCED GAP --- */

/* WoodMart accordion headings reuse the original SVG assets and dimensions. */
.woocommerce-tabs[data-gs-tabs] .wd-accordion-title[data-accordion-index] .wd-accordion-title-text::before {
    content: "";
    display: inline-block;
    width: 24px;
    height: 24px;
    margin-right: 13px;
    background-size: contain;
    background-repeat: no-repeat;
    vertical-align: middle;
}
.woocommerce-tabs[data-gs-tabs] #tab-item-title-additional_information .wd-accordion-title-text::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2397a500'%3E%3Cpath d='M11 17h2v-6h-2v6zm1-8q.425 0 .713-.288T13 8q0-.425-.288-.713T12 7q-.425 0-.713.288T11 8q0 .425.288.713T12 9zm0 13q-2.075 0-3.9-.788t-3.175-2.137q-1.35-1.35-2.137-3.175T2 12q0-2.075.788-3.9t2.137-3.175q1.35-1.35 3.175-2.137T12 2q2.075 0 3.9.788t3.175 2.137q1.35 1.35 2.137 3.175T22 12q0 2.075-.788 3.9t-2.137 3.175q-1.35 1.35-3.175 2.137T12 22zm0-2q3.35 0 5.675-2.325T20 12q0-3.35-2.325-5.675T12 4q-3.35 0-5.675 2.325T4 12q0 3.35 2.325 5.675T12 20z'/%3E%3C/svg%3E");
}
.woocommerce-tabs[data-gs-tabs] #tab-item-title-coverage_calc_tab .wd-accordion-title-text::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2397a500'%3E%3Cpath d='M7 17h2v-2H7v2zm4 0h2v-2h-2v2zm4 0h2v-5h-2v5zM7 13h2v-2H7v2zm4 0h2v-2h-2v2zm4-4h2V7h-2v2zm-4 0h2V7h-2v2zM7 9h2V7H7v2zM5 21q-.825 0-1.413-.588T3 19V5q0-.825.588-1.413T5 3h14q.825 0 1.413.588T21 5v14q0 .825-.588 1.413T19 21H5zm0-2h14V5H5v14z'/%3E%3C/svg%3E");
}
.woocommerce-tabs[data-gs-tabs] #tab-item-title-product_resources_tab .wd-accordion-title-text::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2397a500'%3E%3Cpath d='M5 21q-.825 0-1.413-.588T3 19V5q0-.825.588-1.413T5 3h12l4 4v12q0 .825-.588 1.413T19 21H5zm0-2h14V7.85L16.15 5H5v14zm7-3q.825 0 1.413-.588T14 14q0-.825-.588-1.413T12 12q-.825 0-1.413.588T10 14q0 .825.588 1.413T12 16zM6 9h9V6H6v3z'/%3E%3C/svg%3E");
}
.site-main div.woocommerce-tabs[data-gs-tabs] {
    margin-top: -3px !important;    /* Increased to push away from description */
    margin-bottom: 0px !important;
    clear: both !important;         /* This prevents it from "climbing" up next to images */
    display: block !important;
    float: none !important;
    width: 100% !important;
}						

/* 2. TAB NAVIGATION (LAYOUT & CENTERED) */
.woocommerce-tabs[data-gs-tabs] ul.tabs {
    display: flex !important;
    flex-direction: row; 
    justify-content: center !important; /* Centers tabs horizontally on desktop */
    border-bottom: none !important;
    margin-bottom: 3 !important;
    padding: 13 !important;
}

/* 3. INDIVIDUAL TAB BUTTONS */
.woocommerce-tabs[data-gs-tabs] ul.tabs li {
    border-radius: 8px 8px 0 0 !important; 
    margin: 0 4px !important; /* Small gap between tabs */
    border: 1px solid #eeeeee !important;
    border-bottom: none !important;
    background-color: #f1f1f1 !important;
    position: relative;
    top: 1px; /* Overlaps content panel border for seamless connection */
    z-index: 2;
    transition: all 0.2s ease;
}

.woocommerce-tabs[data-gs-tabs] ul.tabs li a {
    display: flex;
    align-items: center;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none !important;
    color: #666 !important;
    padding: 12px 25px !important;
}

/* 4. ACTIVE & HOVER STATES */
.woocommerce-tabs[data-gs-tabs] ul.tabs li.active {
    background-color: #97a500 !important;
    border-color: #97a500 !important;
}

.woocommerce-tabs[data-gs-tabs] ul.tabs li.active a {
    color: #ffffff !important;
    font-weight: 700;
}

/* 5. SVG ICON SETUP */
.woocommerce-tabs[data-gs-tabs] ul.tabs li a::before {
    content: ""; 
    display: inline-block;
    width: 24px;
    height: 24px;
    margin-right: 13px;
    background-size: contain;
    background-repeat: no-repeat;
    vertical-align: middle;
}

/* Info Icon - Additional Information */
.woocommerce-tabs[data-gs-tabs] ul.tabs li.additional_information_tab a::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2397a500'%3E%3Cpath d='M11 17h2v-6h-2v6zm1-8q.425 0 .713-.288T13 8q0-.425-.288-.713T12 7q-.425 0-.713.288T11 8q0 .425.288.713T12 9zm0 13q-2.075 0-3.9-.788t-3.175-2.137q-1.35-1.35-2.137-3.175T2 12q0-2.075.788-3.9t2.137-3.175q1.35-1.35 3.175-2.137T12 2q2.075 0 3.9.788t3.175 2.137q1.35 1.35 2.137 3.175T22 12q0 2.075-.788 3.9t-2.137 3.175q-1.35 1.35-3.175 2.137T12 22zm0-2q3.35 0 5.675-2.325T20 12q0-3.35-2.325-5.675T12 4q-3.35 0-5.675 2.325T4 12q0 3.35 2.325 5.675T12 20z'/%3E%3C/svg%3E");
}

/* Calculator Icon - Coverage Calc */
.woocommerce-tabs[data-gs-tabs] ul.tabs li.coverage_calc_tab_tab a::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2397a500'%3E%3Cpath d='M7 17h2v-2H7v2zm4 0h2v-2h-2v2zm4 0h2v-5h-2v5zM7 13h2v-2H7v2zm4 0h2v-2h-2v2zm4-4h2V7h-2v2zm-4 0h2V7h-2v2zM7 9h2V7H7v2zM5 21q-.825 0-1.413-.588T3 19V5q0-.825.588-1.413T5 3h14q.825 0 1.413.588T21 5v14q0 .825-.588 1.413T19 21H5zm0-2h14V5H5v14z'/%3E%3C/svg%3E");
}

/* File Save Icon - Resources */
.woocommerce-tabs[data-gs-tabs] ul.tabs li.product_resources_tab_tab a::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2397a500'%3E%3Cpath d='M5 21q-.825 0-1.413-.588T3 19V5q0-.825.588-1.413T5 3h12l4 4v12q0 .825-.588 1.413T19 21H5zm0-2h14V7.85L16.15 5H5v14zm7-3q.825 0 1.413-.588T14 14q0-.825-.588-1.413T12 12q-.825 0-1.413.588T10 14q0 .825.588 1.413T12 16zM6 9h9V6H6v3z'/%3E%3C/svg%3E");
}

/* Turn Icons White when Tab is Active */
.woocommerce-tabs[data-gs-tabs] ul.tabs li.active a::before {
    filter: brightness(0) invert(1) !important;
}

/* 6. THE CONTENT BOX (ROUNDED SHAPE) */
.woocommerce-tabs[data-gs-tabs] .woocommerce-Tabs-panel {
    border-radius: 12px !important; 
    border: 1px solid #eeeeee !important;
    border-top: 2px solid #97a500 !important; /* Brand line connects to active tab */
    background: #fbfbfb !important;
    padding: 30px !important;
    box-shadow: 0 5px 15px rgba(0,0,0,0.03);
    clear: both;
}

/* 7. ATTRIBUTE TABLE STYLING (ADDITIONAL INFO) */
.woocommerce-tabs[data-gs-tabs] table.woocommerce-product-attributes td, 
.woocommerce-tabs[data-gs-tabs] table.woocommerce-product-attributes th {
    border-bottom: 0.25px solid #c2c0c0; 
    padding: 0.75rem 0;
}
.woocommerce-tabs[data-gs-tabs] table.woocommerce-product-attributes tr:last-child td,
.woocommerce-tabs[data-gs-tabs] table.woocommerce-product-attributes tr:last-child th {
    border-bottom: none;
}

/* 8. RESOURCES TAB INTERNAL LINKS (DOWNLOAD ARROW) */
.woocommerce-tabs[data-gs-tabs] #tab-product_resources_tab a {
    display: inline-flex !important;
    align-items: center;
    gap: 12px;
    text-decoration: none !important;
    color: #444 !important;
    font-weight: 600;
    margin-bottom: 16px;
    transition: all 0.2s ease;
}
.woocommerce-tabs[data-gs-tabs] #tab-product_resources_tab a::before {
    content: "";
    display: inline-block;
    width: 22px;
    height: 22px;
    background-size: contain;
    background-repeat: no-repeat;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2397a500'%3E%3Cpath d='M12 16l-5-5h3V3h4v8h3l-5 5zm-7 2h14v2H5v-2z'/%3E%3C/svg%3E");
}
.woocommerce-tabs[data-gs-tabs] #tab-product_resources_tab a:hover { color: #97a500 !important; }

/* 9. MOBILE & IPAD CENTERED STACKING */
@media (max-width: 767px) {
    .woocommerce-tabs[data-gs-tabs] { margin-top: 40px !important; }

    .woocommerce-tabs[data-gs-tabs] ul.tabs {
        flex-direction: column !important; 
        align-items: center !important; /* Centers the tabs stack */
    }

    .woocommerce-tabs[data-gs-tabs] ul.tabs li {
        width: 100% !important; /* Button-style width on mobile */
        margin: 0 0 0px 0 !important;
        border-radius: 8px !important; /* Fully rounded on mobile for "button" feel */
        border-bottom: 1px solid #ddd !important;
    }

    .woocommerce-tabs[data-gs-tabs] ul.tabs li a {
        justify-content: center; /* Centers icon + text inside mobile buttons */
    }

    .woocommerce-tabs[data-gs-tabs] .woocommerce-Tabs-panel {
        border-radius: 12px !important;
        margin-top: 0px;
    }
}
