/**
 * Solink Product Page — Custom Tab Nav
 * Overrides WooCommerce's default .woocommerce-tabs styling to match the
 * Solink design system: clean horizontal bar, thin grey baseline running
 * full-width, active tab marked by a red underline.
 *
 * Uses .woocommerce div.product specificity to beat WooCommerce defaults.
 */

/* ─── Sentinel: sits immediately above the tabs block ─────────────────────── */
.absites-tabs-sentinel {
    display: block;
    height: 0;
    pointer-events: none;
}

/* ─── Wrapper: white tab card with thin grey border all around ──────────────── */
.woocommerce div.product .woocommerce-tabs {
    margin: 0 0 24px;
    padding: 0;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    background: #fff;
    overflow: hidden;
}

/* ─── Tab list (the nav bar) ────────────────────────────────────────────────── */
.woocommerce div.product .woocommerce-tabs ul.tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;          /* Firefox */
    -ms-overflow-style: none;       /* IE/Edge */

    list-style: none;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    border-bottom: 1px solid #e5e5e5 !important;
    position: relative;
    z-index: 10;
}

.woocommerce div.product .woocommerce-tabs ul.tabs::-webkit-scrollbar {
    display: none;
}

/* WooCommerce wraps the list in its own ::before / ::after curves — kill them */
.woocommerce div.product .woocommerce-tabs ul.tabs::before,
.woocommerce div.product .woocommerce-tabs ul.tabs::after {
    display: none !important;
    content: none !important;
    border: 0 !important;
    background: transparent !important;
}

/* ─── Individual tab items: strip ALL WooCommerce defaults ──────────────────── */
.woocommerce div.product .woocommerce-tabs ul.tabs li {
    flex: 0 0 auto;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    display: block;
}

/* The notorious WooCommerce pill curves on each li */
.woocommerce div.product .woocommerce-tabs ul.tabs li::before,
.woocommerce div.product .woocommerce-tabs ul.tabs li::after {
    display: none !important;
    content: none !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

/* ─── Tab links ──────────────────────────────────────────────────────────────── */
.woocommerce div.product .woocommerce-tabs ul.tabs li a {
    position: relative;
    display: block;
    padding: 16px 24px;
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--deep-black, #1a1a1a);
    text-decoration: none;
    white-space: nowrap;
    background: transparent;
    border: 0;
    transition: color 0.2s ease;
}

/* Red underline indicator — sits ON TOP of the grey baseline */
.woocommerce div.product .woocommerce-tabs ul.tabs li a::after {
    content: '';
    position: absolute;
    left: 24px;
    right: 24px;
    bottom: -1px;
    height: 2px;
    background: transparent;
    transition: background-color 0.2s ease;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a:hover,
.woocommerce div.product .woocommerce-tabs ul.tabs li a:focus {
    color: var(--solink-red, #F60012);
    background: transparent;
    text-decoration: none;
}

/* ─── Active tab: red underline ─────────────────────────────────────────────── */
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a,
.woocommerce div.product .woocommerce-tabs ul.tabs li[aria-selected="true"] a {
    color: var(--solink-red, #F60012);
    background: transparent;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active a::after,
.woocommerce div.product .woocommerce-tabs ul.tabs li[aria-selected="true"] a::after {
    background: var(--solink-red, #F60012);
}

/* WooCommerce gives the active li its own background — neutralize it */
.woocommerce div.product .woocommerce-tabs ul.tabs li.active {
    background: transparent !important;
    border-color: transparent !important;
}

/* ─── Tab panels ─────────────────────────────────────────────────────────────── */
.woocommerce div.product .woocommerce-tabs .panel {
    margin: 0;
    padding: 32px 24px;
    border: 0;
    background: #fff;
}

/* Placeholder message for tabs with no template assigned */
.absites-tab-panel > p:only-child {
    margin: 0;
    color: #999;
    font-style: italic;
}

/* ─── Sticky state: only the tab BAR sticks, not the panel ──────────────────── */
.woocommerce-tabs.is-sticky ul.tabs {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 9999;
    background: #fff !important;
    border-bottom: 1px solid #e5e5e5 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.10);
    padding: 0 24px !important;
}

/* Spacer keeps the card's visual height stable when the bar leaves the flow */
.absites-tabs-spacer {
    width: 100%;
}

/* ─── Mobile adjustments ─────────────────────────────────────────────────────── */
@media (max-width: 767px) {
    .woocommerce div.product .woocommerce-tabs ul.tabs li a {
        padding: 14px 16px;
        font-size: 12px;
    }

    .woocommerce-tabs.is-sticky ul.tabs {
        top: 0;
        padding: 0 12px !important;
    }
}

/* ─── Overview tab ─────────────────────────────────────────────────────────── */
/* Structured per-product layout: headline + body + up to 4 features (left)    */
/* and a hero image (right). Accent colour pulled from Elementor's primary     */
/* global with Solink red as a fallback.                                       */

.solink-overview {
    display: grid;
    grid-template-columns: 45% 55%;
    gap: 0;
    align-items: center;
    font-family: 'Montserrat', sans-serif;
    color: var(--deep-black, #1a1a1a);
    position: relative;
    overflow: hidden;
}

.solink-overview--no-image {
    grid-template-columns: 1fr;
}

.solink-overview__left {
    min-width: 0;
    position: relative;
    z-index: 2;
    padding-right: 24px;
}

.solink-overview__headline {
    margin: 0 0 18px;
    font-weight: 500;
    text-transform: uppercase;
    line-height: 1.05;
    letter-spacing: -0.01em;
    font-size: clamp(28px, 3.2vw, 44px);
}

.solink-overview__headline-1,
.solink-overview__headline-2 {
    display: block;
    font-weight: 500;
}

.solink-overview__headline-1 {
    color: var(--deep-black, #1a1a1a);
}

.solink-overview__headline-2 {
    color: var(--solink-red, #F60012);
    text-shadow: 0 0 4px rgba(246, 0, 18, 0.18);
}

.solink-overview__body {
    margin: 0 0 26px;
    font-size: 15px;
    line-height: 1.6;
    color: var(--deep-black, #1a1a1a);
    max-width: 56ch;
}

.solink-overview__body p:first-child { margin-top: 0; }
.solink-overview__body p:last-child { margin-bottom: 0; }

.solink-overview__body a {
    color: var(--e-global-color-primary, var(--solink-red, #F60012));
    text-decoration: none;
}

.solink-overview__body a:hover { text-decoration: underline; }

/* Features row — 4 across on desktop, 2x2 on tablet & mobile */
.solink-overview__features {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px 16px;
}

.solink-overview__feature {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
    min-width: 0;
}

.solink-overview__feature-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin-bottom: 4px;
    color: var(--solink-red, #F60012);
    line-height: 1;
}

.solink-overview__feature-icon-img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    display: block;
}

.solink-overview__feature-icon-fa {
    font-size: 30px;
    color: inherit;
    text-shadow: 0 0 4px rgba(246, 0, 18, 0.18);
}

.solink-overview__feature-label {
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--deep-black, #1a1a1a);
    line-height: 1.2;
}

.solink-overview__feature-sub {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 12px;
    color: var(--dark-gray, #6b6b6b);
    line-height: 1.35;
}

.solink-overview__right {
    min-width: 0;
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.solink-overview__hero {
    display: block;
    margin-left: auto;
    margin-right: auto;
    width: 100%;
    height: auto;
    max-height: 420px;
    object-fit: contain;
}

/* Tablet — stack columns, keep features 2x2 */
@media (max-width: 900px) {
    .solink-overview {
        grid-template-columns: 1fr;
        gap: 28px;
        overflow: visible;
    }

    .solink-overview__left {
        padding-right: 0;
    }

    .solink-overview__right {
        margin-left: 0;
    }

    .solink-overview__features {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .solink-overview__hero {
        max-height: 360px;
    }
}

/* Mobile — 2x2 features (per spec) */
@media (max-width: 480px) {
    .solink-overview__headline {
        font-size: clamp(24px, 7vw, 32px);
    }

    .solink-overview__body {
        font-size: 14px;
    }

    .solink-overview__features {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 18px 12px;
    }

    .solink-overview__feature-icon {
        width: 36px;
        height: 36px;
    }

    .solink-overview__feature-icon-fa {
        font-size: 26px;
    }
}

/* ─── Specifications tab ───────────────────────────────────────────────────── */
/* Structured per-product layout: title + intro + spec list (left column),    */
/* and an optional technical drawing image (right column). Red accent comes   */
/* from --solink-red.                                                          */

.solink-spec {
    display: grid;
    grid-template-columns: minmax(0, 40fr) minmax(0, 60fr);
    gap: 32px;
    align-items: center;
    font-family: 'Montserrat', sans-serif;
    color: var(--deep-black, #1a1a1a);
}

.solink-spec--no-image {
    grid-template-columns: 1fr;
}

.solink-spec__left {
    min-width: 0;
}

.solink-spec__right {
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.solink-spec__title {
    margin: 0 0 14px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    line-height: 1.1;
    font-size: clamp(22px, 2.4vw, 30px);
    color: var(--deep-black, #1a1a1a);
}

.solink-spec__intro {
    margin: 0 0 20px;
    font-size: 15px;
    line-height: 1.6;
    color: var(--deep-black, #1a1a1a);
}

.solink-spec__intro p:first-child { margin-top: 0; }
.solink-spec__intro p:last-child  { margin-bottom: 0; }

.solink-spec__intro a {
    color: var(--solink-red, #F60012);
    text-decoration: none;
}
.solink-spec__intro a:hover { text-decoration: underline; }

.solink-spec__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Each row: icon | label | value, separated by a thin divider. */
.solink-spec__row {
    display: grid;
    grid-template-columns: 28px minmax(120px, 0.9fr) minmax(0, 1.6fr);
    align-items: center;
    gap: 14px;
    padding: 10px 0;
    border-bottom: 1px solid rgba(107, 107, 107, 0.18);
}

.solink-spec__row:last-child {
    border-bottom: 0;
}

.solink-spec__row-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    color: var(--solink-red, #F60012);
    font-size: 18px;
    line-height: 1;
    flex: 0 0 auto;
}

.solink-spec__row-icon i {
    font-size: inherit;
    color: inherit;
}

.solink-spec__row-label {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--deep-black, #1a1a1a);
    line-height: 1.25;
}

.solink-spec__row-value {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: var(--deep-black, #1a1a1a);
    line-height: 1.4;
    /* tabular numerals so 11.1V / 72g / 58.5mm line up nicely */
    font-variant-numeric: tabular-nums;
}

.solink-spec__image-img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 420px;
    object-fit: contain;
}

/* Tablet — stack the drawing below the list. */
@media (max-width: 900px) {
    .solink-spec {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .solink-spec__image-img {
        max-height: 320px;
    }
}

/* Mobile — tighten the row grid so long values still fit on a phone. */
@media (max-width: 480px) {
    .solink-spec__title {
        font-size: clamp(20px, 6vw, 26px);
    }

    .solink-spec__intro {
        font-size: 14px;
    }

    .solink-spec__row {
        grid-template-columns: 22px minmax(0, 0.9fr) minmax(0, 1.4fr);
        gap: 10px;
        padding: 9px 0;
    }

    .solink-spec__row-icon {
        font-size: 15px;
        width: 18px;
        height: 18px;
    }

    .solink-spec__row-label {
        font-size: 12px;
    }

    .solink-spec__row-value {
        font-size: 13px;
    }
}

/* ─── FAQ tab ──────────────────────────────────────────────────────────────── */
/* Structured per-product Q&A accordion, styled to match the Overview and      */
/* Specifications tabs: clean white rows separated by hairline dividers, red   */
/* accent only on the +/– icon and hover state. No filled pill bars.           */
/*                                                                              */
/* Selectors are scoped under .woocommerce div.product .woocommerce-tabs to    */
/* beat WooCommerce/Elementor button-element defaults that otherwise paint     */
/* the question buttons in the theme's primary colour (the pink/grey bars).   */

.solink-faq {
    font-family: 'Montserrat', sans-serif;
    color: var(--deep-black, #1a1a1a);
    max-width: 880px;
    margin: 0 auto;
    min-width: 0;
}

.solink-faq,
.solink-faq * {
    box-sizing: border-box;
}

.solink-faq__title {
    margin: 0 0 14px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    line-height: 1.1;
    font-size: clamp(22px, 2.4vw, 30px);
    color: var(--deep-black, #1a1a1a);
    text-align: center;
}

.solink-faq__intro {
    margin: 0 0 24px;
    font-size: 15px;
    line-height: 1.6;
    color: var(--deep-black, #1a1a1a);
    text-align: center;
}

.solink-faq__intro p:first-child { margin-top: 0; }
.solink-faq__intro p:last-child  { margin-bottom: 0; }

.solink-faq__intro a {
    color: var(--solink-red, #F60012);
    text-decoration: none;
}
.solink-faq__intro a:hover { text-decoration: underline; }

.solink-faq__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
    min-width: 0;
    width: 100%;
}

.solink-faq__item {
    border-bottom: 1px solid rgba(107, 107, 107, 0.22);
    background: transparent;
    min-width: 0;
    width: 100%;
}

.solink-faq__item:first-child {
    border-top: 1px solid rgba(107, 107, 107, 0.22);
}

/* Question button — strip ALL native + WooCommerce + theme button styling.
   The high-specificity selector + !important is necessary because the active
   theme paints <button> elements in its primary colour (the pink bar) and
   WC adds its own background/border on .button. */
.solink-faq .solink-faq__question,
.woocommerce div.product .woocommerce-tabs .panel .solink-faq__question,
button.solink-faq__question {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    margin: 0 !important;
    padding: 18px 4px !important;
    background: transparent !important;
    background-color: transparent !important;
    background-image: none !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    cursor: pointer;
    text-align: left;
    text-transform: none !important;
    letter-spacing: 0 !important;
    font-family: 'Montserrat', sans-serif !important;
    font-weight: 600 !important;
    font-size: 15px !important;
    line-height: 1.35;
    color: var(--deep-black, #1a1a1a) !important;
    white-space: normal !important;
    word-break: break-word !important;
    overflow-wrap: break-word !important;
    -webkit-appearance: none;
       -moz-appearance: none;
            appearance: none;
    transition: color 0.2s ease;
}

.solink-faq .solink-faq__question:hover,
.solink-faq .solink-faq__question:focus,
.solink-faq .solink-faq__question:focus-visible,
.solink-faq .solink-faq__question:active,
button.solink-faq__question:hover,
button.solink-faq__question:focus,
button.solink-faq__question:active {
    background: transparent !important;
    background-color: transparent !important;
    color: var(--solink-red, #F60012) !important;
    outline: none;
    box-shadow: none !important;
}

.solink-faq__question-text {
    flex: 1 1 0;
    min-width: 0;
    max-width: 100%;
    white-space: normal !important;
    overflow-wrap: break-word !important;
    word-break: break-word !important;
    hyphens: auto;
}

.solink-faq__question-icon {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    color: var(--solink-red, #F60012);
    font-size: 14px;
    transition: transform 0.25s ease;
}

.solink-faq__question-icon i { color: inherit; }

/* Open state — rotate the plus into an X (visually a minus/close) */
.solink-faq__item.is-open .solink-faq__question-icon {
    transform: rotate(45deg);
}

.solink-faq__item.is-open .solink-faq__question {
    color: var(--solink-red, #F60012) !important;
}

/* Answer panel */
.solink-faq__answer {
    overflow: hidden;
}

.solink-faq__answer[hidden] {
    display: none;
}

.solink-faq__answer-inner {
    padding: 0 4px 18px;
    font-size: 14px;
    line-height: 1.65;
    color: var(--deep-black, #1a1a1a);
}

.solink-faq__answer-inner p:first-child { margin-top: 0; }
.solink-faq__answer-inner p:last-child  { margin-bottom: 0; }

.solink-faq__answer-inner a {
    color: var(--solink-red, #F60012);
    text-decoration: none;
}
.solink-faq__answer-inner a:hover { text-decoration: underline; }

.solink-faq__answer-inner ul,
.solink-faq__answer-inner ol {
    padding-left: 22px;
    margin: 8px 0;
}

@media (max-width: 480px) {
    .solink-faq__title {
        font-size: clamp(20px, 6vw, 26px);
    }

    .solink-faq__intro {
        font-size: 14px;
    }

    .solink-faq .solink-faq__question,
    button.solink-faq__question {
        padding: 16px 2px !important;
        font-size: 14px !important;
        gap: 12px;
    }

    .solink-faq__answer-inner {
        padding: 0 2px 16px;
        font-size: 13px;
    }
}
