/* ELLIE DESKTOP HEADER ICONS CLEAN/SPACING FIX V38
   Autor: Modyfikator stworzony przez gumis
   Zakres: tylko desktopowy prawy header. V38 zastępuje problematyczny V37. */

@media (min-width: 768px) {
  /* Stabilny układ widgetów w prawym headerze bez wymuszania widoczności wszystkich SVG w pksearch. */
  body:not(#checkout) header#header .elementor-widget-wrap:has(> .elementor-widget-pksearch):has(> .elementor-widget-pksignin):has(> .elementor-widget-pkcart) {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    flex-wrap: nowrap !important;
    gap: 22px !important;
  }

  body:not(#checkout) header#header .elementor-widget-wrap:has(> .elementor-widget-pksearch):has(> .elementor-widget-pksignin):has(> .elementor-widget-pkcart) > .elementor-widget,
  body:not(#checkout) header#header .elementor-widget-wrap:has(> .elementor-widget-pksearch):has(> .elementor-widget-pksignin):has(> .elementor-widget-pkcart) > .ellie-desktop-header-favorite-v36 {
    margin: 0 !important;
  }

  body:not(#checkout) header#header .elementor-widget-wrap:has(> .elementor-widget-pksearch):has(> .elementor-widget-pksignin):has(> .elementor-widget-pkcart) > .elementor-widget-pksearch,
  body:not(#checkout) header#header .elementor-widget-wrap:has(> .elementor-widget-pksearch):has(> .elementor-widget-pksignin):has(> .elementor-widget-pkcart) > .ellie-desktop-header-favorite-v36,
  body:not(#checkout) header#header .elementor-widget-wrap:has(> .elementor-widget-pksearch):has(> .elementor-widget-pksignin):has(> .elementor-widget-pkcart) > .elementor-widget-pksignin,
  body:not(#checkout) header#header .elementor-widget-wrap:has(> .elementor-widget-pksearch):has(> .elementor-widget-pksignin):has(> .elementor-widget-pkcart) > .elementor-widget-pkcart {
    flex: 0 0 auto !important;
    min-width: 24px !important;
    width: auto !important;
    height: 28px !important;
    min-height: 28px !important;
    max-height: 28px !important;
    padding: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #545454 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    line-height: 1 !important;
    text-align: center !important;
    vertical-align: middle !important;
  }

  /* Czarna kropka przy lupie po V37: ukrycie pseudo-elementow/duplikatow, bez ruszania natywnego SVG lupy. */
  body:not(#checkout) header#header .elementor-widget-pksearch::before,
  body:not(#checkout) header#header .elementor-widget-pksearch::after,
  body:not(#checkout) header#header .elementor-widget-pksearch form::before,
  body:not(#checkout) header#header .elementor-widget-pksearch form::after,
  body:not(#checkout) header#header .elementor-widget-pksearch fieldset::before,
  body:not(#checkout) header#header .elementor-widget-pksearch fieldset::after,
  body:not(#checkout) header#header .elementor-widget-pksearch button::before,
  body:not(#checkout) header#header .elementor-widget-pksearch button::after,
  body:not(#checkout) header#header .elementor-widget-pksearch .search-popup,
  body:not(#checkout) header#header .elementor-widget-pksearch input.search-popup,
  body:not(#checkout) header#header .elementor-widget-pksearch .hidden.search-popup {
    display: none !important;
    content: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    width: 0 !important;
    height: 0 !important;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: 0 !important;
    max-height: 0 !important;
    overflow: hidden !important;
    background: transparent !important;
    box-shadow: none !important;
    border: 0 !important;
    pointer-events: none !important;
  }

  /* Nie wymuszamy display na wszystkich SVG, tylko kolor dla tego, co motyw natywnie pokazuje. */
  body:not(#checkout) header#header .elementor-widget-pksearch,
  body:not(#checkout) header#header .elementor-widget-pksearch a,
  body:not(#checkout) header#header .elementor-widget-pksearch button,
  body:not(#checkout) header#header .elementor-widget-pksearch svg,
  body:not(#checkout) header#header .elementor-widget-pksearch svg *,
  body:not(#checkout) header#header .ellie-desktop-header-favorite-v36,
  body:not(#checkout) header#header .ellie-desktop-header-favorite-v36 *,
  body:not(#checkout) header#header .elementor-widget-pksignin,
  body:not(#checkout) header#header .elementor-widget-pksignin *,
  body:not(#checkout) header#header .elementor-widget-pkcart,
  body:not(#checkout) header#header .elementor-widget-pkcart * {
    color: #545454 !important;
    /* Ikony lib.svg (search/account/cart) sa fill-based — wymuszony stroke je pogrubial.
       Stroke zdejmujemy; serce .favorite-v36 ma wlasna regule stroke nizej i pozostaje cienkie. */
    stroke: none !important;
  }

  body:not(#checkout) header#header .elementor-widget-pksearch svg,
  body:not(#checkout) header#header .ellie-desktop-header-favorite-v36 svg,
  body:not(#checkout) header#header .elementor-widget-pksignin svg,
  body:not(#checkout) header#header .elementor-widget-pkcart svg {
    width: 22px !important;
    height: 22px !important;
    min-width: 22px !important;
    min-height: 22px !important;
    max-width: 22px !important;
    max-height: 22px !important;
    opacity: 1 !important;
  }

  body:not(#checkout) header#header .ellie-desktop-header-favorite-v36 svg,
  body:not(#checkout) header#header .ellie-desktop-header-favorite-v36 svg path {
    fill: none !important;
    stroke: #545454 !important;
    stroke-width: 1.85 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
  }

  body:not(#checkout) header#header .elementor-widget-pkcart .header-item-counter,
  body:not(#checkout) header#header .elementor-widget-pkcart [class*="counter"],
  body:not(#checkout) header#header .ellie-desktop-header-favorite-v36 .ellie-fav-count-v36 {
    position: absolute !important;
    top: -5px !important;
    right: -7px !important;
    margin: 0 !important;
    color: #545454 !important;
    background: transparent !important;
    font-size: 10px !important;
    line-height: 1 !important;
    min-width: auto !important;
    width: auto !important;
    height: auto !important;
    padding: 0 !important;
    border: 0 !important;
  }

  body:not(#checkout) header#header .elementor-widget-pksearch:hover,
  body:not(#checkout) header#header .elementor-widget-pksearch:hover *,
  body:not(#checkout) header#header .ellie-desktop-header-favorite-v36:hover,
  body:not(#checkout) header#header .ellie-desktop-header-favorite-v36:hover *,
  body:not(#checkout) header#header .elementor-widget-pksignin:hover,
  body:not(#checkout) header#header .elementor-widget-pksignin:hover *,
  body:not(#checkout) header#header .elementor-widget-pkcart:hover,
  body:not(#checkout) header#header .elementor-widget-pkcart:hover * {
    color: #342117 !important;
    /* jw. — bez wymuszonego stroke na fill-based ikonach; serce ma wlasna regule hover nizej */
    stroke: none !important;
  }

  body:not(#checkout) header#header .ellie-desktop-header-favorite-v36:hover svg path {
    stroke: #342117 !important;
  }
}

@media (max-width: 767px) {
  body header#header .ellie-desktop-header-favorite-v36 {
    display: none !important;
  }
}