/* Liovela B2B V52 - checkout full width + osobne dane faktury/wysyłki
   Autor: Modyfikator stworzony przez gumis */

/* ====== zdjęcia produktów w sekcjach kategorii ====== */
.lv-b2b-product-card-fixed .image,
.lv-b2b-product-card-fixed [class*="image"] {
  min-height: 295px !important;
  height: 295px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 18px !important;
}

.lv-b2b-product-card-fixed img.lv-b2b-fixed-product-img,
[class*="product"] img[src*="/image/cache/catalog/presta_p/"],
[class*="product"] img[src*="/image/catalog/presta_p/"] {
  width: 245px !important;
  min-width: 245px !important;
  max-width: 245px !important;
  height: 245px !important;
  min-height: 245px !important;
  max-height: 245px !important;
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
  object-fit: contain !important;
  object-position: center center !important;
}

/* Nie ruszamy flag */
#form-language img,
.language img,
.language-selector img,
.dropdown-language img,
img[src*="liovela_flags"],
img[src*="/language/"],
img[src*="catalog/language"] {
  width: 22px !important;
  max-width: 22px !important;
  min-width: 22px !important;
  height: 14px !important;
  max-height: 14px !important;
  min-height: 14px !important;
  object-fit: cover !important;
}

/* ====== Checkout full width ====== */
body.lv-b2b-checkout-page {
  overflow-x: hidden;
}

body.lv-b2b-checkout-page #content,
body.lv-b2b-checkout-page main,
body.lv-b2b-checkout-page .container,
body.lv-b2b-checkout-page .container-fluid {
  max-width: none !important;
}

.lv-checkout-shell-v52 {
  width: calc(100vw - 44px);
  max-width: 1880px;
  margin: 22px 0 34px 50%;
  transform: translateX(-50%);
  font-family: inherit;
  box-sizing: border-box;
}

.lv-checkout-shell-v52 * {
  box-sizing: border-box;
}

.lv-checkout-title {
  margin: 0 0 18px;
  font-size: 35px;
  line-height: 1.15;
  font-weight: 900;
  color: #1f1b16;
}

.lv-checkout-section {
  margin: 0 0 22px;
  padding: 24px;
  border: 1px solid rgba(195, 180, 144, .58);
  border-radius: 18px;
  background: #fffdf8;
  box-shadow: 0 8px 24px rgba(90, 62, 30, .06);
}

.lv-checkout-section h2,
.lv-checkout-section h3 {
  margin: 0 0 16px;
  font-size: 25px;
  line-height: 1.2;
  font-weight: 900;
  color: #282018;
}

.lv-checkout-grid-2,
.lv-document-options,
.lv-address-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.lv-summary-wrap {
  display: grid;
  grid-template-columns: 1.38fr .82fr;
  gap: 22px;
}

.lv-checkout-option,
.lv-doc-radio {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 74px;
  padding: 18px 20px;
  border: 2px solid #f47b38;
  border-radius: 14px;
  background: #fff;
  color: #2a2119;
  font-weight: 800;
}

.lv-checkout-option .lv-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: #fff3e9;
  color: #f47b38;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex: 0 0 36px;
}

.lv-checkout-option small {
  display: block;
  margin-top: 4px;
  color: #7b6b5c;
  font-size: 12px;
  font-weight: 600;
}

.lv-doc-radio {
  min-height: 68px;
  border: 1px solid rgba(195, 180, 144, .75);
  cursor: pointer;
}

.lv-doc-radio input {
  width: 18px;
  height: 18px;
  accent-color: #f47b38;
}

.lv-doc-radio.lv-active {
  border: 2px solid #f47b38;
  box-shadow: 0 0 0 3px rgba(244, 123, 56, .10);
}

.lv-address-card {
  min-height: 150px;
  padding: 20px;
  border: 1px solid rgba(195, 180, 144, .78);
  border-radius: 16px;
  background: #fff;
}

.lv-address-card h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  font-size: 18px;
}

.lv-step-badge {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #f47b38;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 900;
  flex: 0 0 30px;
}

.lv-address-content {
  min-height: 48px;
  color: #3d3128;
  line-height: 1.5;
  word-break: break-word;
}

.lv-address-actions {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.lv-btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 10px 16px;
  border: 1px solid #f47b38;
  border-radius: 10px;
  color: #f47b38 !important;
  background: #fff;
  font-weight: 800;
  text-decoration: none !important;
  cursor: pointer;
}

.lv-btn-outline:hover {
  background: #fff4ec;
}

.lv-panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.lv-panel-title h3 {
  margin: 0;
}

.lv-checkout-edit-panel {
  margin-top: 18px;
  padding: 22px;
  border: 1px dashed rgba(244, 123, 56, .65);
  border-radius: 16px;
  background: #fffaf5;
}

.lv-checkout-edit-panel.lv-open {
  display: block !important;
}

.lv-generated-form-grid,
.lv-original-form-wrapper form,
.lv-original-form-wrapper .row {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 16px 24px !important;
}

.lv-generated-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.lv-generated-field label,
.lv-original-form-wrapper label,
.lv-original-form-wrapper .control-label,
.lv-original-form-wrapper .form-label {
  font-weight: 700 !important;
  color: #2f271f !important;
}

.lv-generated-field input,
.lv-generated-field select,
.lv-original-form-wrapper input,
.lv-original-form-wrapper select,
.lv-original-form-wrapper textarea {
  min-height: 42px !important;
  border: 1px solid #d9dfe7 !important;
  border-radius: 6px !important;
  padding: 8px 12px !important;
  background: #fff !important;
}

.lv-checkout-hidden-original {
  display: none !important;
}

.lv-original-form-wrapper {
  width: 100%;
}

.lv-order-summary-box table,
.lv-order-summary-box .table {
  width: 100%;
}

.lv-comment-box h3 {
  font-size: 22px;
}

.lv-comment-box textarea {
  width: 100% !important;
  min-height: 145px !important;
  border: 1px solid rgba(195, 180, 144, .75) !important;
  border-radius: 14px !important;
  padding: 14px 16px !important;
  background: #fff !important;
}

.lv-submit-area {
  display: flex;
  justify-content: flex-end;
  margin-top: 16px;
}

.lv-submit-area .btn,
.lv-submit-area button,
.lv-submit-area input[type="submit"] {
  min-height: 52px;
  padding: 14px 28px;
  border-radius: 12px;
  background: #f47b38 !important;
  border-color: #f47b38 !important;
  color: #fff !important;
  font-weight: 900;
}

.lv-note {
  margin-top: 10px;
  color: #7d6c5e;
  font-size: 13px;
}

/* Stare bloki checkout po przeniesieniu nie mogą zostawać obok */
body.lv-b2b-checkout-page .lv-old-checkout-hidden {
  display: none !important;
}

@media (max-width: 991px) {
  .lv-checkout-shell-v52 {
    width: calc(100vw - 24px);
  }

  .lv-checkout-grid-2,
  .lv-document-options,
  .lv-address-grid,
  .lv-summary-wrap,
  .lv-generated-form-grid,
  .lv-original-form-wrapper form,
  .lv-original-form-wrapper .row {
    grid-template-columns: 1fr !important;
  }

  .lv-checkout-title {
    font-size: 28px;
  }
}

@media (max-width: 575px) {
  .lv-checkout-section {
    padding: 16px;
  }

  .lv-checkout-shell-v52 {
    width: calc(100vw - 14px);
  }

  .lv-b2b-product-card-fixed .image,
  .lv-b2b-product-card-fixed [class*="image"] {
    min-height: 205px !important;
    height: 205px !important;
  }

  .lv-b2b-product-card-fixed img.lv-b2b-fixed-product-img,
  [class*="product"] img[src*="/image/cache/catalog/presta_p/"],
  [class*="product"] img[src*="/image/catalog/presta_p/"] {
    width: 170px !important;
    min-width: 170px !important;
    max-width: 170px !important;
    height: 170px !important;
    min-height: 170px !important;
    max-height: 170px !important;
  }
}


/* LIOVELA_B2B_V53_FOOTER_MAP_SAFE_START
   Naprawa rozjazdu stopki/mapy po V52.
   Autor: Modyfikator stworzony przez gumis
*/

/* Checkout ma być szeroki, ale bez wyciągania całej strony/stopki poza ekran */
body.lv-b2b-checkout-page .lv-checkout-shell-v52 {
  width: calc(100vw - 48px) !important;
  max-width: 1840px !important;
  margin: 22px auto 34px !important;
  transform: none !important;
  left: auto !important;
  right: auto !important;
  position: relative !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* Cofnięcie efektu zbyt szerokiego .container dla stopki i mapy */
body.lv-b2b-checkout-page footer,
body.lv-b2b-checkout-page #footer,
body.lv-b2b-checkout-page .footer,
body.lv-b2b-checkout-page .liovela-footer,
body.lv-b2b-checkout-page .b2b-footer {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  margin-left: auto !important;
  margin-right: auto !important;
  transform: none !important;
  left: auto !important;
  right: auto !important;
  overflow: hidden !important;
}

body.lv-b2b-checkout-page footer .container,
body.lv-b2b-checkout-page #footer .container,
body.lv-b2b-checkout-page .footer .container,
body.lv-b2b-checkout-page .liovela-footer .container,
body.lv-b2b-checkout-page .b2b-footer .container,
body.lv-b2b-checkout-page footer .container-fluid,
body.lv-b2b-checkout-page #footer .container-fluid,
body.lv-b2b-checkout-page .footer .container-fluid {
  width: 100% !important;
  max-width: 1320px !important;
  min-width: 0 !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: 15px !important;
  padding-right: 15px !important;
  transform: none !important;
  left: auto !important;
  right: auto !important;
  overflow: visible !important;
}

/* Mapa / obrazki w stopce nie mogą wychodzić poza kartę/kolumnę */
body.lv-b2b-checkout-page footer img,
body.lv-b2b-checkout-page #footer img,
body.lv-b2b-checkout-page .footer img,
body.lv-b2b-checkout-page .liovela-footer img,
body.lv-b2b-checkout-page .b2b-footer img,
body.lv-b2b-checkout-page footer iframe,
body.lv-b2b-checkout-page #footer iframe,
body.lv-b2b-checkout-page .footer iframe,
body.lv-b2b-checkout-page .liovela-footer iframe,
body.lv-b2b-checkout-page .b2b-footer iframe {
  max-width: 100% !important;
  height: auto !important;
}

/* Gdy konkretny box mapy ma szerokość z poprzedniego CSS */
body.lv-b2b-checkout-page [class*="map"],
body.lv-b2b-checkout-page [id*="map"] {
  max-width: 100% !important;
}

/* Na małych ekranach bez bocznego wypychania */
@media (max-width: 991px) {
  body.lv-b2b-checkout-page .lv-checkout-shell-v52 {
    width: calc(100vw - 24px) !important;
  }
}

@media (max-width: 575px) {
  body.lv-b2b-checkout-page .lv-checkout-shell-v52 {
    width: calc(100vw - 14px) !important;
  }
}
/* LIOVELA_B2B_V53_FOOTER_MAP_SAFE_END */



/* LIOVELA_B2B_V54_HIDE_ORDER_DATA_BLOCK_START
   Ukrycie zbędnego bloku "Dane zamówienia" w checkout.
   Autor: Modyfikator stworzony przez gumis
*/

/* W V52 kolejność sekcji:
   1. Sposób dostawy i metoda płatności
   2. Rodzaj dokumentu
   3. Dane zamówienia
   4. Podsumowanie zamówienia
   Ukrywamy tylko sekcję nr 3. */
body.lv-b2b-checkout-page .lv-checkout-shell-v52 > section.lv-checkout-section:nth-of-type(3) {
  display: none !important;
}

/* Jeżeli przeglądarka nie policzy nth-of-type przez inne elementy, fallback po strukturze */
body.lv-b2b-checkout-page .lv-checkout-shell-v52 .lv-address-grid {
  display: none !important;
}

body.lv-b2b-checkout-page .lv-checkout-shell-v52 .lv-address-grid,
body.lv-b2b-checkout-page .lv-checkout-shell-v52 .lv-invoice-panel,
body.lv-b2b-checkout-page .lv-checkout-shell-v52 .lv-shipping-panel {
  visibility: hidden !important;
  height: 0 !important;
  min-height: 0 !important;
  max-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
}

/* LIOVELA_B2B_V54_HIDE_ORDER_DATA_BLOCK_END */

