/* ------------------------------
   Reset przycisków WooCommerce do stylu motywu
------------------------------ */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit,
.woocommerce-cart .button,
.woocommerce-checkout .button,
.woocommerce-page a.button,
.woocommerce-page button.button,
.woocommerce-page input.button {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    height: 54px;
    padding: 0 25px;
    box-sizing: border-box;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
    color: var(--kolorek2);
    background: var(--kolorek);
    border: none;
    outline: none;
    cursor: pointer;
    transition: all 0.5s ease;
    text-transform: uppercase;
    border-radius: 0!important;
}

/* Hover efekt */
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce #respond input#submit:hover,
.woocommerce-cart .button:hover,
.woocommerce-checkout .button:hover {
    box-shadow: inset 10em 0 0 0 var(--kolorek3), inset -10em 0 0 0 var(--kolorek3);
    color: #fff;
}


.woocommerce ul.products li.product .button {
    margin-top: 0!important;
}


.woocommerce ul.products li.product a,
.woocommerce ul.products li.product a span,
.woocommerce ul.products li.product a bdi,
.woocommerce ul.products li.product a ins,
.woocommerce ul.products li.product a del {
    text-decoration: none !important;
    border-bottom: none !important;
    box-shadow: none !important;
    outline: none !important;
}

/* ------------------------------
   Formularze i pola
------------------------------ */
input.input-text,
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.select2-container .select2-selection--single, .orderby {
    height: 54px;
    padding: 0 15px;
    font-size: 16px;
    border: 1px solid #ccc;
    box-sizing: border-box;
    font-family: inherit;
    border-radius: 0;
    background: #fff;
    border-radius: 0;
}

#coupon_code {
min-width: 150px;
}

textarea {
    min-height: 120px!important;
    padding: 10px 15px!important;
    border: 1px solid #ccc!important;
    border-radius: 0!important;
}

/* Focus na polach */
.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce form .form-row select:focus,
.select2-container--default .select2-selection--single:focus {
    border-color: var(--kolorek);
    outline: none;
}

/* Select2 (WooCommerce dropdowns) */
.select2-container--default .select2-selection--single {
    border: 1px solid #ccc;
    height: 54px;
    display: flex;
    align-items: center;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 54px;
}

/* ------------------------------
   Koszyk i Checkout
------------------------------ */

.woocommerce table.shop_table {
    border: 1px solid #eee;
    margin-bottom: 20px;
}

.woocommerce table.shop_table th,
.woocommerce table.shop_table td {
    padding: 12px;
}

/* ------------------------------
   Paginations
------------------------------ */
.woocommerce nav.woocommerce-pagination ul {
    display: flex;
    list-style: none;
    gap: 5px;
    padding: 0;
    justify-content: center;
}

.woocommerce nav.woocommerce-pagination ul li {
    margin: 5px!important;
}

.woocommerce nav.woocommerce-pagination ul li a,
.woocommerce nav.woocommerce-pagination ul li span {
    display: block;
    padding: 8px 12px!important;
    font-weight: 600!important;
    color: #000;
    border: 0!important;
}

.woocommerce nav.woocommerce-pagination ul li span.current {
    background: var(--kolorek)!important;
    color: #fff!important;
    border: 0!important;
}
.woocommerce nav.woocommerce-pagination ul li a:hover {
    background: var(--kolorek3)!important;
    color: #fff!important;
}
.woocommerce nav.woocommerce-pagination ul, .woocommerce nav.woocommerce-pagination ul li {
    border: 0!important;
    border-right: 0!important;
    border-left: 0!important;
}

/* ------------------------------
   Znacznik "Sale"
------------------------------ */
.woocommerce ul.products li.product .onsale, .woocommerce span.onsale {
    background: red!important;
    color: #fff!important;
    padding: 5px 30px 0px 25px!important;
    border-radius: 0!important;
    font-size: 12px!important;
    font-weight: bold!important;
}

/* ------------------------------
   Ilość produktu (quantity input)
------------------------------ */
.woocommerce div.product form.cart div.quantity input.qty {
    height: 54px;
    border: 1px solid #ccc;
    padding: 0 10px;
    font-size: 16px;
}

/* ------------------------------
   Logowanie / rejestracja
------------------------------ */
.woocommerce-form-login,
.woocommerce-form-register {
    border: 1px solid #eee;
    padding: 20px;
    background: #fff;
}

/* ------------------------------
   Przyciski specyficzne WooCommerce
------------------------------ */
.woocommerce .checkout-button,
.woocommerce .woocommerce-form-login__submit,
.woocommerce .woocommerce-form-register__submit,
.woocommerce .single_add_to_cart_button {
    height: 54px !important;
    padding: 0 25px !important;
}


/* Tytuł produktu */
.woocommerce ul.products li.product .woocommerce-loop-product__title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 5px;
}

.woocommerce-loop-product__title,.woocommerce-loop-product__title h2:hover {
color: #000;
}

.woocommerce:where(body:not(.woocommerce-uses-block-theme)) div.product p.price, .woocommerce:where(body:not(.woocommerce-uses-block-theme)) div.product span.price, .woocommerce:where(body:not(.woocommerce-uses-block-theme)) ul.products li.product .price {
color: #000!important;
}

.woocommerce p.price del,
.woocommerce p.price del a,
.woocommerce p.price ins,
.woocommerce p.price ins a {
    text-decoration: none !important;
    border: none !important;
}

.woocommerce div.product form.cart {
margin-bottom:0!important;}


/* Cena */
.woocommerce ul.products li.product .price {
    font-size: 1rem;
    color: #000;
    font-weight: 700;
}

.single-product .products h2 {
text-align: center;
}

.single-product ul.products {
padding-top: 50px!important;
}



/* KAFELKI PRODUKTÓW - układ */
.woocommerce ul.products li.product {
  position: relative;
  overflow: hidden;
  text-align: center;
}

/* Obrazek produktu */
.woocommerce ul.products li.product img {
  width: 100%;
  height: auto;
  display: block;
  transition: all 0.3s ease;
}

/* Tytuł i cena */
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font: 400 14px/30px;
  margin: 10px 0 0;
}
.woocommerce ul.products li.product .price {
  font-weight: 700;
  font-size: 16px;
}

/* Tytuł i cena */
.woocommerce ul.products li.product .woocommerce-loop-product__title,
.woocommerce ul.products li.product .price {
  transition: opacity 0.3s ease;
}

/* Hover - ukrycie tytułu i ceny */
.woocommerce ul.products li.product:hover .woocommerce-loop-product__title,
.woocommerce ul.products li.product:hover .price {
  opacity: 0;
}

/* 1. Wyświetlanie przycisku na stałe (zamiast wysuwania na hover) */
.woocommerce ul.products li.product a.button {
    position: relative !important; /* Zmieniamy z absolute, by nie zasłaniał treści */
    bottom: 0 !important;         /* Resetujemy pozycję */
    left: auto !important;
    transform: none !important;
    opacity: 1 !important;        /* Przycisk jest zawsze widoczny */
    width: 100% !important;       /* Szerokość na 100% kafelka */
    margin-top: 15px !important;  /* Odstęp od ceny */
    visibility: visible !important;
}

/* 2. Zatrzymanie ukrywania tytułu i ceny na hover */
.woocommerce ul.products li.product:hover .woocommerce-loop-product__title,
.woocommerce ul.products li.product:hover .price {
    opacity: 1 !important;
}

/* 3. Dodanie ikonki Font Awesome przed tekstem "Kup" */
.woocommerce ul.products li.product a.button::before,
.woocommerce div.product form.cart .button::before {
    content: "\f07a"; /* Kod ikonki koszyka w Font Awesome */
    font-family: "Font Awesome 5 Free", "Font Awesome 6 Free"; /* Dopasuj do posiadanej wersji */
    font-weight: 900;
    margin-right: 8px;
    display: inline-block;
}

/* 4. Usunięcie efektu skali obrazka (opcjonalnie, jeśli chcesz by kafelek był statyczny) */
.woocommerce ul.products li.product:hover img {
    transform: none !important;
}

/* Kontener główny */
.qib-container {
    display: flex !important;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 15px 0;
}

/* Kontener przycisków i pola input */
.quantity-controls {
    display: flex;
    align-items: center;
    height: 54px; /* wysokość zgodna z Twoim przyciskiem */
    background: #fff;
}

/* Przyciski plus/minus */
.quantity-controls button {
    width: 35px;
    height: 100%;
    border: none;
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    background: transparent;
    padding: 0;
    margin: 0;
}

/* Pole input w środku */
.quantity-controls .quantity {
    margin: 0 !important;
    border: 0!important;
}

.quantity-controls input.qty {
    width: 45px !important;
    height: 100% !important;
    border: none !important; /* usuwamy ramkę, bo jest na kontenerze */
    text-align: center;
    padding: 0 !important;
    font-weight: bold;
    background: #fff;
}

/* Przycisk Kup - dostosowanie */
.qib-container .add_to_cart_button {
    margin: 0 !important;
    flex-grow: 1;
}

/* Ukrycie domyślnych strzałek przeglądarki */
.quantity-controls input::-webkit-outer-spin-button,
.quantity-controls input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ------------------------------
   Responsywność dla Mobile - Poprawka
------------------------------ */
@media (max-width: 768px) {
    /* 1. Reset starych ustawień, które mogły chować przycisk */
    .woocommerce ul.products li.product .qib-container a.button {
        position: relative !important;
        bottom: 0 !important;
        left: 0 !important;
        transform: none !important;
        opacity: 1 !important;
        visibility: visible !important;
        width: auto !important; /* Pozwalamy mu rosnąć w flexboxie */
        flex: 1; /* Zajmuje resztę miejsca obok +/- */
        display: flex !important;
        height: 40px !important;
        font-size: 10px !important;
        padding: 0 5px !important;
        margin: 0 !important;
    }

    /* 2. Zmniejszamy wysokość całego zestawu */
    .qib-container {
        height: 40px !important;
        gap: 5px !important;
        margin: 10px 0 !important;
        display: flex !important; /* Upewniamy się, że kontener żyje */
    }

    .quantity-controls {
        height: 40px !important;
        display: flex !important;
    }

    /* 3. Zmniejszenie przycisków plus/minus i inputa */
    .quantity-controls button {
        width: 28px !important;
        height: 40px !important;
        font-size: 14px !important;
    }

    .quantity-controls input.qty {
        width: 30px !important;
        height: 40px !important;
        font-size: 13px !important;
    }

    /* 4. Ukrywamy ikonkę na bardzo małych ekranach, żeby zmieścił się napis KUP */
    .woocommerce ul.products li.product a.button::before {
        font-size: 10px !important;
        margin-right: 3px !important;
    }
}

@media (max-width: 768px) {
    /* 1. Reset wysokości kontenera nadrzędnego */
    .quantity-controls .quantity {
        height: 40px !important;    /* Twoja docelowa wysokość na mobile */
        min-height: 40px !important;
        max-height: 40px !important;
        line-height: 40px !important;
        margin: 0 !important;
    }

    /* 2. Reset samego pola input */
    .quantity-controls .quantity input.qty {
        height: 40px !important;      /* Wymuszamy wysokość */
        min-height: 40px !important;  /* Zabijamy systemowe min-height */
        max-height: 40px !important;
        line-height: 1 !important;    /* Resetujemy wysokość linii tekstu */
        padding: 0 !important;
        margin: 0 !important;
        border: none !important;
        
        /* Wyłączenie systemowych stylów mobilnych */
        -webkit-appearance: none !important; 
        -moz-appearance: textfield !important;
        appearance: none !important;
        border-radius: 0 !important;
    }

    /* 3. Upewnij się, że kontener zewnętrzny też nie jest wyższy */
    .quantity-controls {
        height: 40px !important;
        overflow: hidden !important; /* Wszystko co wystaje poza 40px zostanie ucięte */
    }
}

/* ------------------------------
   Przycisk "Dodaj do koszyka"
------------------------------ */
/* -- Podstawowy styl wszystkich przycisków WooCommerce -- */
.woocommerce ul.products li.product .button,
.woocommerce div.product form.cart .button,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input[type="button"],
.woocommerce input[type="submit"],
.woocommerce #respond input#submit,
.woocommerce .cart .button,
.woocommerce .checkout-button,
.woocommerce-message .button,
.woocommerce-error .button,
.woocommerce-info .button,
.woocommerce #payment #place_order,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) #respond input#submit.alt,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) a.button.alt,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) button.button.alt,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) input.button.alt,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce #respond input#submit.alt,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce a.button.alt,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce button.button.alt,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce input.button.alt {
    color: var(--kolorek2) !important;
    background: var(--kolorek) !important;
    border-color: var(--kolorek) !important;
    transition: all 0.5s !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 54px !important;
    padding: 0 25px !important;
    box-sizing: border-box !important;
    border: none !important;
    outline: none !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    text-transform: uppercase !important;
    margin-bottom: 10px !important;
    text-decoration: none !important;
}

/* -- Efekt hover dla wszystkich przycisków -- */
.woocommerce ul.products li.product .button:hover,
.woocommerce div.product form.cart .button:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input[type="button"]:hover,
.woocommerce input[type="submit"]:hover,
.woocommerce #respond input#submit:hover,
.woocommerce .cart .button:hover,
.woocommerce .checkout-button:hover,
.woocommerce-message .button:hover,
.woocommerce-error .button:hover,
.woocommerce-info .button:hover,
.woocommerce #payment #place_order:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) #respond input#submit.alt:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) a.button.alt:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) button.button.alt:hover,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles)) input.button.alt:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce #respond input#submit.alt:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce a.button.alt:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce button.button.alt:hover,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(:not(.edit-post-visual-editor)) .woocommerce input.button.alt:hover {
    box-shadow: inset 10em 0 0 0 var(--kolorek3), inset -10em 0 0 0 var(--kolorek3);
    border-color: var(--kolorek3);
    color: #fff;
}


.pswp {z-index: 999999999!important}
.woocommerce-tabs ul.tabs, #wpadminbar #adminbarsearch .adminbar-button {
    display: none!important;
}

/* Ukrycie standardowego napisu Zobacz Koszyk obok przycisku */
.added_to_cart.wc-forward {
    display: none !important;
}

.col-1, .col-2 {
padding-right: 0!important;
padding-left: 0!important;
margin-bottom: 20px;
}
