/* =========================================================
   EMALIA RYBNIK - PSR PANEL FRONT CSS FINAL
   Moduł: emaliapsrpanel
   Plik: modules/emaliapsrpanel/views/css/front.css
   PrestaShop 8.2.5 / ThemeVolty
   Panel: "Producent i osoba odpowiedzialna za produkt"
   ========================================================= */

.epp-product-box {
  margin: 24px 0 10px;
  font-size: 15px;
  line-height: 1.6;
  color: #4b4b4b;
}

.epp-product-box__intro {
  margin-right: 6px;
}

.epp-open-btn {
  padding: 0;
  border: 0;
  background: transparent;
  color: #0f766e;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.epp-open-btn:hover,
.epp-open-btn:focus {
  color: #0b5d57;
  outline: none;
  opacity: 0.9;
}

/* Tło pod panelem */
.epp-overlay {
  position: fixed;
  inset: 0;
  z-index: 150000;
  background: rgba(20, 24, 31, 0.42);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

/* Główny panel */
.epp-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 150010;

  width: 100%;
  max-width: 470px;
  height: 100vh;
  height: 100dvh;

  background: #ffffff;
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.12);

  transform: translateX(100%);
  transition: transform 0.28s ease, opacity 0.22s ease;

  display: flex;
  flex-direction: column;

  overflow: hidden;
  outline: none;
}

.epp-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.epp-drawer.is-open {
  transform: translateX(0);
}

/* Nagłówek panelu */
.epp-drawer__header {
  position: sticky;
  top: 0;
  z-index: 2;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;

  padding: 24px 22px 20px;

  background: #ffffff;
  border-bottom: 1px solid #ece7df;
}

.epp-drawer__title {
  margin: 0;
  padding-right: 10px;

  font-size: 20px;
  line-height: 1.2;
  font-weight: 700;
  color: #1f2937;
}

.epp-drawer__close {
  width: 40px;
  height: 40px;
  min-width: 40px;

  border: 1px solid #eeeeee;
  border-radius: 50%;
  background: #ffffff;

  color: #0f766e;
  font-size: 32px;
  line-height: 1;
  cursor: pointer;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.10);
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.epp-drawer__close span {
  display: block;
  width: 100%;
  height: 100%;
  line-height: 36px;
  text-align: center;
}

.epp-drawer__close:hover,
.epp-drawer__close:focus {
  color: #000000;
  background: #f7efe6;
  transform: scale(1.03);
  outline: none;
}

/* Treść */
.epp-drawer__content {
  flex: 1 1 auto;
  overflow-y: auto;
  overflow-x: hidden;

  padding: 22px;

  -webkit-overflow-scrolling: touch;
}

.epp-section + .epp-section {
  margin-top: 22px;
}

.epp-section__title {
  margin: 0 0 10px;

  font-size: 15px;
  line-height: 1.35;
  font-weight: 700;
  color: #1f2937;
}

.epp-text {
  margin: 0 0 6px;

  font-size: 15px;
  line-height: 1.6;
  color: #424242;
}

.epp-text--strong {
  font-weight: 700;
  color: #232323;
}

.epp-text a,
.epp-pdf-list__link {
  color: #0f766e;
  text-decoration: none;
  word-break: break-word;
}

.epp-text a:hover,
.epp-pdf-list__link:hover,
.epp-text a:focus,
.epp-pdf-list__link:focus {
  color: #0b5d57;
  text-decoration: underline;
  outline: none;
}

.epp-pdf-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.epp-pdf-list__item + .epp-pdf-list__item {
  margin-top: 7px;
}

/* Blokada scrolla strony podczas otwartego panelu */
body.epp-no-scroll {
  overflow: hidden !important;
}

/* Ukrycie sticky produktu i strzałki, żeby nie nachodziły na panel */
body.epp-drawer-open .emalia-mobile-product-sticky,
body.epp-drawer-open .tvfooter-product-sticky-bottom,
body.epp-drawer-open #emaliaBackToTop,
body.epp-drawer-open .emalia-back-to-top {
  display: none !important;
}

/* =========================================================
   DESKTOP >= 1200px
   Elegancki panel boczny po prawej stronie
   ========================================================= */

@media (min-width: 1200px) {
  .epp-overlay {
    background: rgba(20, 24, 31, 0.40);
  }

  .epp-drawer {
    top: 0;
    right: 0;
    bottom: 0;

    width: min(460px, 34vw);
    max-width: 460px;
    height: 100dvh;

    border-radius: 0;
    box-shadow: -14px 0 38px rgba(0, 0, 0, 0.16);
  }

  .epp-drawer__header {
    padding: 28px 28px 22px;
  }

  .epp-drawer__content {
    padding: 26px 28px 32px;
  }

  .epp-drawer__title {
    font-size: 21px;
  }
}

/* =========================================================
   TABLET 768-1199px
   Panel jako elegancka karta nad pływającym headerem
   ========================================================= */

@media (min-width: 768px) and (max-width: 1199px) {
  .epp-overlay {
    background: rgba(20, 24, 31, 0.42);
  }

  .epp-drawer {
    top: 12px;
    right: 12px;
    bottom: 12px;

    width: min(460px, calc(100vw - 24px));
    max-width: min(460px, calc(100vw - 24px));

    height: auto;
    max-height: calc(100dvh - 24px);

    border-radius: 10px;
    box-shadow: -8px 0 34px rgba(0, 0, 0, 0.20);
  }

  .epp-drawer__header {
    padding: 18px 18px 16px;
    border-radius: 10px 10px 0 0;
  }

  .epp-drawer__title {
    font-size: 18px;
    line-height: 1.22;
  }

  .epp-drawer__close {
    width: 38px;
    height: 38px;
    min-width: 38px;
    font-size: 30px;
  }

  .epp-drawer__close span {
    line-height: 34px;
  }

  .epp-drawer__content {
    padding: 18px;
  }

  .epp-section + .epp-section {
    margin-top: 18px;
  }

  .epp-section__title {
    font-size: 15px;
  }

  .epp-text {
    font-size: 14px;
    line-height: 1.55;
  }
}

/* =========================================================
   MOBILE <= 767px
   Nie zasłania całego ekranu - karta z marginesem
   ========================================================= */

@media (max-width: 767px) {
  .epp-overlay {
    background: rgba(20, 24, 31, 0.42);
  }

  .epp-drawer {
    top: 12px;
    left: 12px;
    right: 12px;
    bottom: auto;

    width: auto;
    max-width: none;
    height: auto;
    max-height: calc(100dvh - 24px);

    border-radius: 10px;
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.22);

    transform: translateY(18px) scale(0.98);
    opacity: 0;
  }

  .epp-drawer.is-open {
    transform: translateY(0) scale(1);
    opacity: 1;
  }

  .epp-drawer__header {
    padding: 16px 16px 14px;
    border-radius: 10px 10px 0 0;
  }

  .epp-drawer__title {
    max-width: calc(100% - 50px);
    font-size: 18px;
    line-height: 1.18;
  }

  .epp-drawer__close {
    width: 38px;
    height: 38px;
    min-width: 38px;
    font-size: 30px;
  }

  .epp-drawer__close span {
    line-height: 34px;
  }

  .epp-drawer__content {
    max-height: calc(100dvh - 98px);
    padding: 16px;
  }

  .epp-section + .epp-section {
    margin-top: 18px;
  }

  .epp-section__title {
    margin-bottom: 8px;
    font-size: 15px;
    line-height: 1.3;
  }

  .epp-text {
    font-size: 14px;
    line-height: 1.55;
  }

  .epp-product-box {
    margin: 20px 0 8px;
    font-size: 14px;
    line-height: 1.5;
  }
}

/* Bardzo niskie ekrany mobile */
@media (max-width: 767px) and (max-height: 650px) {
  .epp-drawer {
    top: 8px;
    left: 8px;
    right: 8px;
    max-height: calc(100dvh - 16px);
  }

  .epp-drawer__header {
    padding: 13px 14px 12px;
  }

  .epp-drawer__content {
    max-height: calc(100dvh - 82px);
    padding: 14px;
  }
}