/* ========================================================================
   DOLGIO — poprawki po uwagach klienta 2026-08-17
   ======================================================================== */

/* 5 + 13: menu — normalna grubość, bold wyłącznie dla dokładnie aktywnej pozycji. */
#site-navigation-wrap .dropdown-menu > li > a,
#site-navigation-wrap .dropdown-menu > li.current-menu-parent > a,
#site-navigation-wrap .dropdown-menu > li.current-menu-ancestor > a,
#site-navigation-wrap .dropdown-menu > li.current_page_parent > a,
#site-navigation-wrap .dropdown-menu > li.current_page_ancestor > a {
    font-weight: 400 !important;
}

#site-navigation-wrap .dropdown-menu > li.current-menu-item > a,
#site-navigation-wrap .dropdown-menu > li.current_page_item > a {
    font-weight: 700 !important;
}

@media (min-width: 992px) {
    #site-navigation-wrap .dropdown-menu > li > a {
        white-space: nowrap;
        padding-left: 12px;
        padding-right: 12px;
    }

    #site-navigation-wrap,
    #site-navigation-wrap .dropdown-menu {
        max-width: 100%;
    }
}

/* 6 + 9: galeria produktu — NIE nadpisujemy stylów FlexSlider/Zoom WooCommerce.
   Poprzednia wersja wymuszała opacity/visibility/max-width na wszystkich obrazkach,
   przez co zoomImg był stale widoczny, a ikona 360° rosła do ogromnych rozmiarów. */
.single-product .woocommerce-product-gallery,
.single-product .gallery_content {
    visibility: visible;
}

/* 360° — dokładnie mały przycisk jak w wersji produkcyjnej. */
.single-product .gallery_content_button {
    position: absolute;
    bottom: 20%;
    left: 0;
    right: 0;
    z-index: 5;
    pointer-events: none;
}

.single-product .gallery_content_button p {
    display: flex;
    align-items: center;
    gap: 0;
    width: max-content;
    max-width: calc(100% - 30px);
    margin: auto;
    background: #dc9816;
    border-radius: 18px;
    color: #fff;
    padding: .5rem 3rem;
    font-family: "ClashDisplay-Medium";
    cursor: pointer;
    transition: all .3s;
    pointer-events: auto;
}

.single-product .gallery_content_button p:hover {
    background: #dc1620;
}

.single-product .gallery_content_button p img {
    display: inline-block !important;
    width: 35px !important;
    min-width: 35px !important;
    max-width: 35px !important;
    height: auto !important;
    margin: 0 0 0 1rem !important;
    opacity: 1 !important;
    visibility: visible !important;
    object-fit: contain;
    vertical-align: middle;
}

/* Nie pozwalamy przyciskowi 360° zasłaniać miniaturek galerii. */
.single-product .flex-control-thumbs,
.single-product .woocommerce-product-gallery__trigger {
    position: relative;
    z-index: 10;
}

.single-product .dolgio_baner_inner img,
.single-product .dolgio_baner_inner .col-xl-4 img,
.single-product .dolgio_baner_inner .col-lg-4 img {
    width: auto;
    max-width: 100% !important;
    height: auto !important;
    object-fit: contain !important;
    object-position: center;
}

.single-product .dolgio_baner_inner,
.single-product .dolgio_baner_inner [class*="col-"] {
    overflow: visible !important;
}

/* 8: WooCommerce related products wyłączamy także CSS-em jako zabezpieczenie motywu. */
.single-product section.related.products,
.single-product .related.products {
    display: none !important;
}

/* Stary customowy slider produktów pod kartą produktu wyłącza dodatkowo JS.
   Nie chowamy .b_button, bo klient chce zostawić CTA „Zobacz wszystkie produkty”. */
.single-product .dolgio-client-legacy-products-hidden {
    display: none !important;
}

/* 9: NIE UKRYWAMY sekcji ACF produktu.
   Wszystkie sekcje z `product_site` mają pozostać widoczne.
   Nie zastępujemy ich hardkodowanymi sekcjami klienta. */

/* Nowe sekcje produktu. */
.dolgio-client-section {
    position: relative;
    width: 100%;
    overflow: hidden;
    padding: 72px 0;
    font-family: "Inter", sans-serif;
}

.dolgio-client-section .container {
    width: min(1180px, calc(100% - 40px));
    max-width: 1180px;
    margin: 0 auto;
}

.dolgio-client-section h2 {
    max-width: 940px;
    margin: 0 0 24px;
    font-family: "Playfair Display", serif;
    font-size: clamp(32px, 4vw, 54px);
    line-height: 1.12;
    color: #1c1917;
}

.dolgio-client-section h3 {
    margin: 0 0 12px;
    font-family: "Playfair Display", serif;
    font-size: 24px;
    line-height: 1.2;
    color: #1c1917;
}

.dolgio-client-section p,
.dolgio-client-section li {
    font-size: 16px;
    line-height: 1.75;
    color: #57534e;
}

.dolgio-client-eyebrow {
    margin: 0 0 12px !important;
    color: #836128 !important;
    font-size: 13px !important;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.dolgio-client-mask-intro,
.dolgio-client-how-use,
.dolgio-client-faq {
    background: #fafaf9;
}

.dolgio-client-benefits,
.dolgio-client-product-cta {
    background: #f2eee8;
}

.dolgio-client-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    margin-top: 34px;
}

.dolgio-client-cards > [class*="col-"] {
    width: 100%;
    max-width: none;
    padding: 0;
}

.dolgio-client-card {
    height: 100%;
    padding: 28px;
    background: #fff;
    border: 1px solid #e7e5e4;
}

.dolgio-client-benefits__list,
.dolgio-client-how-use ol {
    max-width: 900px;
    margin: 24px 0 0;
    padding-left: 24px;
}

.dolgio-client-benefits__list li,
.dolgio-client-how-use li {
    margin-bottom: 10px;
}

/* FAQ — niezależne od Bootstrap, więc nie ma konfliktu z jego collapse. */
.dolgio-client-accordion {
    max-width: 900px;
    margin-top: 30px;
}

.dolgio-client-accordion__item {
    border: 1px solid #e7e5e4;
    border-bottom: 0;
    background: #fff;
}

.dolgio-client-accordion__item:last-child {
    border-bottom: 1px solid #e7e5e4;
}

.dolgio-client-accordion__button {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 20px 24px;
    border: 0;
    background: transparent;
    color: #1c1917;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.45;
    text-align: left;
    cursor: pointer;
}

.dolgio-client-accordion__button:hover,
.dolgio-client-accordion__button:focus {
    background: #f5f3f0;
}

.dolgio-client-accordion__icon {
    flex: 0 0 auto;
    color: #836128;
    font-size: 26px;
    font-weight: 300;
}

.dolgio-client-accordion__body {
    padding: 0 24px 22px;
}

.dolgio-client-accordion__body p {
    margin: 0;
}

.dolgio-client-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    margin: 12px 10px 0 0;
    padding: 12px 24px;
    border: 1px solid #836128;
    background: #836128;
    color: #fff !important;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    text-decoration: none !important;
}

.dolgio-client-button--light {
    background: transparent;
    color: #836128 !important;
}

/* 7: treść "Poznaj świat DOLGIO". */
.dolgio-world-copy h2 {
    margin: 0 0 28px;
    font-family: "Playfair Display", serif;
    font-size: clamp(34px, 4vw, 58px);
    line-height: 1.12;
}

.dolgio-world-copy h3 {
    margin: 38px 0 14px;
    font-family: "Playfair Display", serif;
    font-size: clamp(24px, 2.6vw, 34px);
    line-height: 1.2;
}

.dolgio-world-copy p,
.dolgio-world-copy li {
    font-size: 16px;
    line-height: 1.75;
}

.dolgio-world-copy ul {
    margin: 18px 0 22px;
    padding-left: 22px;
}

.dolgio-world-copy__signature {
    margin-top: 34px !important;
}


/* 15: dodatkowe zabezpieczenie, jeśli koszyk jest zbudowany blokami. */
.woocommerce-cart .cross-sells,
.woocommerce-cart .wc-block-cart__cross-sells,
.woocommerce-cart .wp-block-woocommerce-cart-cross-sells-block {
    display: none !important;
}

@media (max-width: 991px) {
    .dolgio-client-section {
        padding: 52px 0;
    }

    .dolgio-client-cards {
        grid-template-columns: 1fr;
    }

    .dolgio-client-section .container {
        width: min(100% - 28px, 1180px);
    }
}

@media (max-width: 767px) {
    .single-product .dolgio_baner_inner img {
        max-height: none !important;
    }

    .dolgio-client-section {
        padding: 40px 0;
    }

    .dolgio-client-accordion__button {
        padding: 18px;
        font-size: 15px;
    }

    .dolgio-client-accordion__body {
        padding: 0 18px 18px;
    }
}

/* HOTFIX 360 — overlay jak na produkcji + działający przycisk/close. */
.single-product .iframe_content {
    opacity: 0;
    visibility: hidden;
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    background: #fff;
    pointer-events: none;
    z-index: -1;
    transition: opacity .3s ease, visibility .3s ease;
}

.single-product .iframe_content.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    z-index: 999999999;
}

.single-product .iframe_content iframe {
    display: block;
    width: 100%;
    height: 100%;
    padding: 5rem;
    border: 0;
    background: #fff;
}

.single-product .iframe_content .quit_button {
    position: absolute;
    top: 2%;
    right: 2%;
    z-index: 1000000000;
    display: block;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #c3150e;
    color: #fff;
    font-size: 3rem;
    line-height: 50px;
    text-align: center;
    cursor: pointer;
}

html.dolgio-360-open,
body.dolgio-360-open {
    overflow: hidden !important;
}

@media (max-width: 767px) {
    .single-product .iframe_content iframe {
        padding: 3.5rem .75rem .75rem;
    }

    .single-product .iframe_content .quit_button {
        width: 38px;
        height: 38px;
        font-size: 24px;
        line-height: 38px;
    }
}

/* ========================================================================
   DOLGIO — domknięcie punktów możliwych bez nowych treści klienta 2026-08-18
   ======================================================================== */

/* Punkt 3 — dodatkowy przycisk do maski na obu szamponach.
   Jest celowo przyciskiem drugorzędnym: obrys DOLGIO, żeby nie konkurował
   z głównym „Dodaj do koszyka”, ale wyglądał jak element tej samej karty. */
.single-product a.dolgio-mask-pair-button.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    margin: 10px 0 0 10px;
    padding: 12px 24px;
    border: 1px solid #836128 !important;
    border-radius: 0;
    background: transparent !important;
    color: #836128 !important;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.35;
    letter-spacing: .08em;
    text-transform: uppercase;
    text-decoration: none !important;
    box-shadow: none !important;
    transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.single-product a.dolgio-mask-pair-button.button:hover,
.single-product a.dolgio-mask-pair-button.button:focus {
    border-color: #836128 !important;
    background: #836128 !important;
    color: #fff !important;
}

/* Cel przycisku „Zobacz, jak działa” nie chowa się pod sticky headerem. */
.single-product .effect,
.single-product #sposob {
    scroll-margin-top: 120px;
}

/* Punkty 8 + 9 — ten legacy wrapper zawierał duplikat opinii + slider produktów. */
.single-product .product_slider_section {
    display: none !important;
}

/* Puste sekcje ACF nie zostawiają kilkuset pikseli pustej przestrzeni. */
.single-product .dolgio-empty-acf-section {
    display: none !important;
}

/* Jeden CTA po karcie produktu — zostaje po wyłączeniu starego slidera. */
.single-product .dolgio-all-products-cta-wrap {
    width: min(1180px, calc(100% - 40px));
    max-width: 1180px;
    margin: 42px auto 56px;
    text-align: center;
}

.single-product .dolgio-all-products-cta-wrap .dolgio-all-products-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    padding: 13px 26px;
    border: 1px solid #836128;
    background: #836128;
    color: #fff !important;
    text-decoration: none !important;
    text-transform: uppercase;
    letter-spacing: .06em;
}

/* Punkty 2 + 10 — FAQ bez zależności od Bootstrap collapse. */
.dolgio-native-faq-section {
    padding: 64px 0;
}

.dolgio-native-faq {
    max-width: 980px;
    margin: 28px auto 0;
    border-top: 1px solid rgba(131, 97, 40, .28);
}

.dolgio-native-faq__item {
    margin: 0;
    border-bottom: 1px solid rgba(131, 97, 40, .28);
}

.dolgio-native-faq__question {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 20px 4px;
    color: inherit;
    font-weight: 600;
    line-height: 1.45;
    cursor: pointer;
    list-style: none;
}

.dolgio-native-faq__question::-webkit-details-marker {
    display: none;
}

.dolgio-native-faq__icon {
    position: relative;
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
}

.dolgio-native-faq__icon::before,
.dolgio-native-faq__icon::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 1px;
    background: #836128;
    transform: translate(-50%, -50%);
    transition: transform .2s ease;
}

.dolgio-native-faq__icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
}

.dolgio-native-faq__item[open] .dolgio-native-faq__icon::after {
    transform: translate(-50%, -50%) rotate(0deg);
}

.dolgio-native-faq__answer {
    padding: 0 36px 22px 4px;
}

.dolgio-native-faq__answer > :last-child {
    margin-bottom: 0;
}

@media (max-width: 767px) {
    .single-product .dolgio-mask-pair-button {
        margin: 10px 0 0;
        width: 100%;
    }

    .single-product .single_extra_button {
        width: 100%;
    }

    .single-product .dolgio-all-products-cta-wrap {
        width: calc(100% - 28px);
        margin: 32px auto 42px;
    }

    .dolgio-native-faq-section {
        padding: 44px 0;
    }
}


/* FINAL: awaryjne zabezpieczenie przed drugim blokiem opinii starego szablonu. */
.single-product .woocommerce-Reviews + .woocommerce-Reviews {
    display: none !important;
}


/* ========================================================================
   DOLGIO — HEADER / MENU 2026-08-18
   Na kartach produktu stary single-product.css ustawia KAŻDE .col-xl-8 na 50%,
   co zwęża kolumnę linków w nagłówku. Przywracamy prawidłowe 8/12 tylko
   w headerze. Nie dotykamy układu samej karty produktu.
   ======================================================================== */
@media (min-width: 1200px) {
    body.single-product .header_main_fixed > .row > .col-xl-8,
    body.single-product .header_main_fixed .row.align-items-center > .col-xl-8 {
        -webkit-box-flex: 0 !important;
        -ms-flex: 0 0 66.666667% !important;
        flex: 0 0 66.666667% !important;
        max-width: 66.666667% !important;
    }

    body.single-product .header_main_fixed .header_main_links {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-align: center;
        -ms-flex-align: center;
        align-items: center;
        -ms-flex-wrap: nowrap;
        flex-wrap: nowrap;
        width: 100%;
    }

    body.single-product .header_main_fixed .header_main_links_link,
    body.single-product .header_main_fixed .header_main_links_link a {
        white-space: nowrap;
    }
}

/* Menu: zwykłe pozycje 400, dokładnie aktywna 600.
   W HTML „Sklep” ma hardkodowany <strong>, dlatego zerujemy jego wagę przez
   inherit i aktywność nadajemy klasą .dolgio-menu-current z JS. */
.header_main_links .header_main_links_link > p > a,
.header_main_links .header_main_links_link > p > a strong {
    font-weight: 400 !important;
}

.header_main_links .header_main_links_link > p > a.dolgio-menu-current,
.header_main_links .header_main_links_link > p > a.dolgio-menu-current strong {
    font-weight: 600 !important;
}


/* DOLGIO HARD FIX 7/8/9 */
.single-product .product_slider_section { display: none !important; }
.single-product section.dolgio-empty-acf-section { display: none !important; }
.single-product .dolgio_baner {
    box-sizing: border-box !important;
    min-height: clamp(360px, 35.84vw, 516px) !important;
    padding: clamp(120px, 18vw, 260px) 0 clamp(70px, 8vw, 130px) !important;
    background-size: contain !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
}
@media (max-width: 767px) {
    .single-product .dolgio_baner { min-height: 280px !important; padding: 90px 0 55px !important; background-size: cover !important; }
}

/* 2026-08-28: pH pod tytułem produktu + ukrycie technicznej kategorii na karcie. */
.single-product .dolgio-product-ph {
    margin: -4px 0 14px;
    font-size: 16px;
    line-height: 1.4;
    font-weight: 600;
}

.single-product .product_meta .posted_in {
    display: none !important;
}


/* ========================================================================
   DOLGIO 2026-08-28 — oficjalne treści klienta dla Mask / Shower / Foot / Mist.
   Sekcja jest całkowicie scope'owana, aby nie wpływać na szampony ani resztę WP.
   ======================================================================== */
.single-product .dolgio-official-product-info {
    padding: 64px 0 52px;
    background: #faf8f4;
}

.single-product .dolgio-official-product-info__eyebrow {
    margin: 0 0 8px;
    font-size: 14px;
    line-height: 1.5;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.single-product .dolgio-official-product-info__heading {
    max-width: 900px;
    margin: 0 0 18px;
}

.single-product .dolgio-official-product-info__intro {
    max-width: 980px;
    margin: 0 0 30px;
    font-size: 17px;
    line-height: 1.7;
}

.single-product .dolgio-official-product-info__cards > [class*="col-"] {
    display: flex;
    margin-bottom: 20px;
}

.single-product .dolgio-official-product-info__card {
    width: 100%;
    padding: 26px;
    background: #fff;
    border: 1px solid rgba(110, 73, 19, .18);
}

.single-product .dolgio-official-product-info__card h3 {
    margin: 0 0 14px;
    font-size: 20px;
}

.single-product .dolgio-official-product-info__card p,
.single-product .dolgio-official-product-info__card li {
    font-size: 15px;
    line-height: 1.65;
}

.single-product .dolgio-official-product-info__card ul {
    margin: 0;
    padding-left: 20px;
}

.single-product .dolgio-official-product-info__note {
    margin: 8px 0 0;
    padding: 16px 18px;
    background: #fff;
    border-left: 3px solid currentColor;
    font-size: 14px;
    line-height: 1.65;
}

@media (max-width: 767px) {
    .single-product .dolgio-official-product-info {
        padding: 42px 0 34px;
    }

    .single-product .dolgio-official-product-info__card {
        padding: 20px;
    }
}

/* ========================================================================
   DOLGIO — końcowe poprawki checklisty klienta 2026-08-28
   ======================================================================== */

/* Punkt 8: sekcja O nas bez mocnego brązowego tła — wyłącznie neutralna paleta DOLGIO. */
body.page-template-page-o-nas .dolgio-differences,
body.page-template-page-o-nas .dolgio-differences__header,
body.page-template-page-o-nas .dolgio-differences__summary,
body.page-id-0 .dolgio-differences {
    background-color: #faf8f4 !important;
    background-image: none !important;
}

/* Punkt 13: żaden stan WordPressa ani hardkodowany <strong> nie pogrubia całego menu.
   Aktywność kontrolujemy wyłącznie klasą dolgio-menu-current nadawaną w JS. */
.header_main_links .header_main_links_link > p > a,
.header_main_links .header_main_links_link > p > a strong,
.header_main_links .header_main_links_link.current-menu-item > p > a,
.header_main_links .header_main_links_link.current-menu-parent > p > a,
.header_main_links .header_main_links_link.current-menu-ancestor > p > a {
    font-weight: 400 !important;
}
.header_main_links .header_main_links_link > p > a.dolgio-menu-current,
.header_main_links .header_main_links_link > p > a.dolgio-menu-current strong {
    font-weight: 600 !important;
}


/* Punkt 15: zabezpieczenie także dla niestandardowych bloków rekomendacji w koszyku. */
.woocommerce-cart .cross-sells,
.woocommerce-cart .upsells,
.woocommerce-cart .wc-block-cart__cross-sells,
.woocommerce-cart .wp-block-woocommerce-cart-cross-sells-block {
    display: none !important;
}


/* ========================================================================
   DOLGIO 2026-08-31 — 360° tylko dla Shampoo 1000 ml
   ======================================================================== */
/*
 * Klasa body jest nadawana w PHP. Dzięki temu na Shampoo 250 ml, Hair Mask,
 * Shower Gel, Kremie do stóp, Mgiełce i innych produktach przycisk 360° nie pojawia się
 * nawet na moment podczas ładowania strony. Standardowa galeria WooCommerce
 * pozostaje bez zmian.
 */
.single-product.dolgio-no-360 .gallery_content_button,
.single-product.dolgio-no-360 .iframe_content {
    display: none !important;
}
