/* ABS Wavesight cookie consent banner
   Self-hosted, first-party. Loaded on every page. */

.ws-consent,
.ws-consent * {
  box-sizing: border-box;
}

.ws-consent {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 2147483000;
  max-width: 40rem;
  margin: 0 auto;
  padding: 1.25rem 1.375rem;
  background: #0b1f3b;
  color: #f4f7fb;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  box-shadow: 0 18px 48px rgba(4, 12, 27, 0.45);
  font-family: "Roboto", "Helvetica Neue", Arial, sans-serif;
  font-size: 0.9375rem;
  line-height: 1.5;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.28s ease, transform 0.28s ease;
}

.ws-consent.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ws-consent [hidden] {
  display: none !important;
}

.ws-consent__title {
  margin: 0 0 0.35rem;
  font-size: 1.0625rem;
  font-weight: 700;
  color: #ffffff;
}

.ws-consent__text {
  margin: 0 0 1rem;
  color: #d6deea;
}

.ws-consent__text a {
  color: #7fb2ff;
  text-decoration: underline;
}

.ws-consent__text a:hover,
.ws-consent__text a:focus {
  color: #a9ccff;
}

.ws-consent__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
}

.ws-consent__btn {
  appearance: none;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 0.625rem 1.25rem;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.ws-consent__btn--accept {
  background: #da1f33;
  color: #ffffff;
}

.ws-consent__btn--accept:hover,
.ws-consent__btn--accept:focus {
  background: #b81a2b;
}

.ws-consent__btn--decline {
  background: transparent;
  color: #f4f7fb;
  border-color: rgba(255, 255, 255, 0.45);
}

.ws-consent__btn--decline:hover,
.ws-consent__btn--decline:focus {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.75);
}

.ws-consent__btn--ghost {
  background: transparent;
  color: #cdd8e8;
  border-color: transparent;
  text-decoration: underline;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}

.ws-consent__btn--ghost:hover,
.ws-consent__btn--ghost:focus {
  color: #ffffff;
}

.ws-consent__btn:focus-visible {
  outline: 2px solid #7fb2ff;
  outline-offset: 2px;
}

/* Preferences panel */
.ws-consent__cats {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
}

.ws-consent__cat {
  padding: 0.75rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.ws-consent__cat:first-child {
  border-top: 0;
}

.ws-consent__cat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.ws-consent__cat-name {
  font-weight: 600;
  color: #ffffff;
}

.ws-consent__cat-always {
  font-size: 0.8125rem;
  color: #9fb4d0;
}

.ws-consent__cat-desc {
  margin: 0.35rem 0 0;
  font-size: 0.8437rem;
  color: #c2cee0;
}

/* Toggle switch */
.ws-consent__switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex: 0 0 auto;
}

.ws-consent__switch input {
  position: absolute;
  opacity: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  cursor: pointer;
}

.ws-consent__slider {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  transition: background 0.18s ease;
  pointer-events: none;
}

.ws-consent__slider::before {
  content: "";
  position: absolute;
  height: 18px;
  width: 18px;
  left: 3px;
  top: 3px;
  background: #ffffff;
  border-radius: 50%;
  transition: transform 0.18s ease;
}

.ws-consent__switch input:checked + .ws-consent__slider {
  background: #da1f33;
}

.ws-consent__switch input:checked + .ws-consent__slider::before {
  transform: translateX(20px);
}

.ws-consent__switch input:focus-visible + .ws-consent__slider {
  outline: 2px solid #7fb2ff;
  outline-offset: 2px;
}

/* Footer "Cookie preferences" reopen trigger (injected into .footer-legal) */
.ws-consent-reopen {
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  text-decoration: none;
}

.ws-consent-reopen:hover,
.ws-consent-reopen:focus {
  text-decoration: underline;
}

@media (max-width: 480px) {
  .ws-consent {
    left: 0.5rem;
    right: 0.5rem;
    bottom: 0.5rem;
    padding: 1.1rem 1.1rem;
  }

  .ws-consent__actions {
    flex-direction: column-reverse;
  }

  .ws-consent__btn {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ws-consent {
    transition: none;
  }
}
