/* Cookie Notice plugin skin. Keep its visibility classes and consent handlers.
   !important is limited to overriding the plugin's inline colour settings. */
#cookie-notice {
  width: calc(100% - 40px);
  max-width: 1120px;
  min-width: 0;
  left: 0;
  right: 0;
  margin-inline: auto;
  background: transparent !important;
  font-family: var(--cn-font);
  font-size: 14px;
  line-height: 1.65;
  text-align: left;
}

#cookie-notice.cn-position-bottom {
  bottom: calc(20px + env(safe-area-inset-bottom, 0px));
}

#cookie-notice.cn-position-top {
  top: calc(20px + env(safe-area-inset-top, 0px));
}

#cookie-notice .cookie-notice-container,
#cookie-notice .cookie-revoke-container {
  position: relative;
  align-items: center;
  gap: 24px;
  padding: 24px 76px 24px 28px;
  border: 1px solid var(--cn-line);
  border-radius: 20px;
  background: var(--cn-bg-soft);
  color: var(--cn-white) !important;
  text-align: left;
}

/* Do not override display:none when the plugin hides either container. */
#cookie-notice:not(.cookie-notice-hidden) .cookie-notice-container,
#cookie-notice:not(.cookie-revoke-hidden) .cookie-revoke-container {
  display: flex;
}

#cookie-notice .cn-text-container {
  flex: 1;
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
}

#cookie-notice .cn-text-container a {
  color: var(--cn-orange);
  text-decoration: underline;
  text-underline-offset: 3px;
}

#cookie-notice .cn-text-container a:hover {
  color: var(--cn-amber);
}

#cookie-notice .cn-buttons-container {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

#cookie-notice .cn-buttons-container .cn-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 88px;
  min-height: 44px;
  margin: 0;
  padding: 12px 24px;
  border: 1px solid var(--cn-orange);
  border-radius: 999px;
  background: var(--cn-orange) !important;
  color: var(--cn-black) !important;
  font: 600 14px/1.2 var(--cn-font);
  letter-spacing: 0;
  text-decoration: none;
  text-transform: none;
  box-shadow: none;
  cursor: pointer;
  transition: transform 160ms ease;
}

#cookie-notice .cn-buttons-container .cn-button:hover {
  transform: translateY(-2px);
}

#cookie-notice .cn-buttons-container .cn-button:active {
  transform: translateY(0);
}

#cookie-notice #cn-close-notice {
  top: 14px;
  right: 14px;
  width: 44px;
  height: 44px;
  margin: 0;
  padding: 0;
  border: 1px solid var(--cn-line);
  border-radius: 50%;
  background: transparent;
  color: var(--cn-white);
  opacity: 1;
}

#cookie-notice #cn-close-notice::before,
#cookie-notice #cn-close-notice::after {
  top: 13px;
  left: 20px;
  height: 16px;
  background: currentColor;
}

#cookie-notice #cn-close-notice:hover {
  color: var(--cn-orange);
}

#cookie-notice a:focus-visible,
#cookie-notice button:focus-visible {
  outline: 2px solid var(--cn-amber);
  outline-offset: 4px;
}

@media (max-width: 767px) {
  #cookie-notice {
    width: calc(100% - 24px);
  }

  #cookie-notice.cn-position-bottom {
    bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  }

  #cookie-notice.cn-position-top {
    top: calc(12px + env(safe-area-inset-top, 0px));
  }

  #cookie-notice .cookie-notice-container,
  #cookie-notice .cookie-revoke-container {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
    padding: 22px;
    border-radius: 16px;
    max-height: calc(100dvh - 48px - env(safe-area-inset-bottom, 0px) - env(safe-area-inset-top, 0px));
    overflow-y: auto;
  }

  #cookie-notice .cookie-notice-container .cn-text-container {
    padding-right: 40px;
  }

  #cookie-notice #cn-close-notice {
    top: 10px;
    right: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #cookie-notice.cn-animated {
    /* The plugin needs animationend to finish hiding the notice. */
    animation-duration: 0.001s !important;
  }

  #cookie-notice .cn-buttons-container .cn-button {
    transition: none;
    transform: none;
  }
}
