/* TELEFON (zawsze na wierzchu) */
.phone-link.cosmic-phone {
  position: fixed;
  right: 20px;
  /* Telefon jest wyzej, zeby koperta mogla byc POD spodem */
  bottom: 110px;
  width: 90px;
  z-index: 100000;
  animation: floatFast 6s ease-in-out infinite;
  will-change: transform;
  transform: translate3d(0,0,0);
  display: block;
  text-decoration: none;
}

.phone-link.cosmic-phone img {
  width: 100%;
  height: auto;
  display: block;
  -webkit-user-drag: none;
  user-drag: none;
  -webkit-user-select: none;
  user-select: none;
  pointer-events: none;
}

/* KOPERTA (pływa POD telefonem) */
.envelope-link.cosmic-envelope {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 70px;
  z-index: 99999;
  animation: floatSlow 7s ease-in-out infinite;
  will-change: transform;
  transform: translate3d(0,0,0);
  display: block;
  text-decoration: none;
}

/* NAPISY PO NAJECHANIU (tooltip) */
.phone-link.cosmic-phone,
.envelope-link.cosmic-envelope {
  position: fixed;
}

.phone-link.cosmic-phone .cosmic-label,
.envelope-link.cosmic-envelope .cosmic-label {
  position: absolute;
  left: 50%;
  bottom: 100%;
  transform: translateX(-50%) translateY(6px);
  margin-bottom: 10px;
  padding: 6px 10px;
  border-radius: 12px;
  background: rgba(11, 15, 50, 0.72);
  border: 1px solid rgba(233, 241, 255, 0.22);
  color: rgba(233, 241, 255, 0.95);
  font-size: 14px;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 10px 28px rgba(0,0,0,0.35);
  /* Domyslnie ukryte – pokazuj DOPIERO na :hover (i :focus-visible) */
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease, visibility 160ms ease;
}

/* Dla GOŁĘBIA (mail) tooltip ma być POD ikoną, bo nad ikoną zasłania go telefon */
.envelope-link.cosmic-envelope .cosmic-label {
  bottom: auto;
  top: 100%;
  margin-bottom: 0;
  margin-top: 10px;
  transform: translateX(-50%) translateY(-6px);
}

.phone-link.cosmic-phone:hover .cosmic-label,
.phone-link.cosmic-phone:focus-visible .cosmic-label,
.envelope-link.cosmic-envelope:hover .cosmic-label,
.envelope-link.cosmic-envelope:focus-visible .cosmic-label {
  opacity: 1 !important;
  visibility: visible !important;
  transform: translateX(-50%) translateY(0);
}


/* =========================================================
   WIDOCZNOŚĆ IKON
   - Desktop + tablet (pion/poziom): WIDOCZNE na wszystkich stronach
     z wyjątkiem: koszyk, kasa, moje konto, kontakt
   - Telefon (pion/poziom): ZAWSZE ukryte
   ========================================================= */

/* Bezpiecznik: ukryj na stronach wykluczonych (gdyby HTML został z cache) */
body.woocommerce-cart .phone-link.cosmic-phone,
body.woocommerce-cart .envelope-link.cosmic-envelope,
body.woocommerce-checkout .phone-link.cosmic-phone,
body.woocommerce-checkout .envelope-link.cosmic-envelope,
body.woocommerce-account .phone-link.cosmic-phone,
body.woocommerce-account .envelope-link.cosmic-envelope,
body.page-kontakt .phone-link.cosmic-phone,
body.page-kontakt .envelope-link.cosmic-envelope,
body.page-contact .phone-link.cosmic-phone,
body.page-contact .envelope-link.cosmic-envelope {
  display: none !important;
}

/* Telefon pion + poziom (w tym "duże" telefony w poziomie) */
@media (max-width: 767px), (max-height: 600px) and (pointer: coarse) {
  .phone-link.cosmic-phone,
  .envelope-link.cosmic-envelope {
    display: none !important;
  }

  /* Biały pasek na dole (Storefront handheld footer bar) – psuje klimat */
  .storefront-handheld-footer-bar {
    display: none !important;
  }
}
.envelope-link.cosmic-envelope img {
  width: 100%;
  height: auto;
  display: block;
  -webkit-user-drag: none;
  user-drag: none;
  -webkit-user-select: none;
  user-select: none;
  pointer-events: none;
}

/* KLASY PLYWANIA */
@keyframes floatSlow {
  0%   { transform: translateY(0); }
  50%  { transform: translateY(-6px); }
  100% { transform: translateY(0); }
}

@keyframes floatFast {
  0%   { transform: translateY(0); }
  50%  { transform: translateY(-10px); }
  100% { transform: translateY(0); }
}

.float-1 { animation: floatSlow 8s ease-in-out infinite; }
.float-2 { animation: floatFast 9s ease-in-out infinite; }
.float-3 { animation: floatSlow 7s ease-in-out infinite; }
.float-4 { animation: floatFast 10s ease-in-out infinite; }
.float-5 { animation: floatSlow 9s ease-in-out infinite; }
.float-6 { animation: floatFast 8s ease-in-out infinite; }
.float-footer { animation: floatSlow 12s ease-in-out infinite; }

.cosmic-float {
  will-change: transform;
  transform: translate3d(0,0,0);
  backface-visibility: hidden;
}

@media (prefers-reduced-motion: reduce) {
  .float-1, .float-2, .float-3, .float-4, .float-5, .float-6,
  .float-footer,
  .phone-link.cosmic-phone,
  .envelope-link.cosmic-envelope {
    animation: none !important;
  }
}

/* =========================================================
   MOJE KONTO (ludzik) – przeniesione JS-em ZA koszyk
   (Storefront: element <li> dostaje klase .arti-account-in-cart)
   ========================================================= */

.site-header-cart{
  display: flex;
  align-items: center;
  gap: 10px;
}

.site-header-cart .arti-account-in-cart{
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.site-header-cart .arti-account-in-cart > a{
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  padding: 10px 12px !important;
  border-radius: 14px;
  font-size: 0 !important; /* chowamy napis, zostawiamy ikonke */
  line-height: 0 !important;
  text-decoration: none;
}

/* chowamy ewentualne spany/etykiety */
.site-header-cart .arti-account-in-cart > a span{
  display: none !important;
}

/* Ikona z Menu Icons (Font Awesome / SVG) */
.site-header-cart .arti-account-in-cart > a i,
.site-header-cart .arti-account-in-cart > a svg{
  font-size: 18px !important;
  width: 18px;
  height: 18px;
  filter: drop-shadow(0 0 8px rgba(73,156,227,.55));
}

.site-header-cart .arti-account-in-cart > a:hover{
  background: rgba(73,156,227,.18);
}

@media (max-width: 768px){
  .site-header-cart{ gap: 6px; }
  .site-header-cart .arti-account-in-cart > a{ padding: 8px 10px !important; }
}
