/* Cookie consent — niezależny system (oddzielony od domyślnego cookie bota szablonu) */
#cookie-consent-bar {
  position: fixed;
  bottom: 20px;
  right: 20px;
  left: 20px;
  max-width: 420px;
  margin-left: auto;
  z-index: 999999;
  display: none;
}

#cookie-consent-bar h6.alt-font {
  font-size: 1.25rem;
  line-height: 1.6rem;
}

#cookie-consent-bar .cc-link {
  text-decoration-line: underline;
  color: var(--dark-gray);
}

#cookie-consent-bar .cc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

#cookie-consent-bar .cc-actions .btn {
  flex: 1 1 auto;
  text-align: center;
}

#cookie-consent-bar .cc-settings-panel {
  display: none;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid rgba(35, 35, 35, 0.1);
}

#cookie-consent-bar .cc-settings-panel.active {
  display: block;
}

#cookie-consent-bar .cc-category {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 15px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(35, 35, 35, 0.08);
}

#cookie-consent-bar .cc-category:last-child {
  border-bottom: none;
}

#cookie-consent-bar .cc-category-text h6 {
  margin-bottom: 4px;
}

/* Toggle switch */
#cookie-consent-bar .cc-switch {
  position: relative;
  display: inline-block;
  width: 42px;
  height: 24px;
  flex: 0 0 auto;
}

#cookie-consent-bar .cc-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

#cookie-consent-bar .cc-switch .cc-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: rgba(35, 35, 35, 0.25);
  transition: 0.3s;
  border-radius: 24px;
}

#cookie-consent-bar .cc-switch .cc-slider::before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: #fff;
  transition: 0.3s;
  border-radius: 50%;
}

#cookie-consent-bar .cc-switch input:checked + .cc-slider {
  background-color: var(--dark-gray);
}

#cookie-consent-bar .cc-switch input:checked + .cc-slider::before {
  transform: translateX(18px);
}

#cookie-consent-bar .cc-switch input:disabled + .cc-slider {
  opacity: 0.5;
  cursor: not-allowed;
}

@media (max-width: 480px) {
  #cookie-consent-bar {
    left: 15px;
    right: 15px;
    bottom: 15px;
    max-width: none;
    padding: 20px !important;
  }

  #cookie-consent-toggle {
    width: 42px;
    height: 42px;
    bottom: 15px;
    right: 15px;
  }
}

/* Stała, zawsze widoczna ikonka do zmiany zgody (odpowiednik "reopen") */
#cookie-consent-toggle {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background-color: var(--dark-gray);
  color: #fff;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999998;
  cursor: pointer;
  border: none;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}

#cookie-consent-toggle.visible {
  display: flex;
}

#cookie-consent-toggle i {
  font-size: 20px;
  line-height: 1;
}
