/* The website's analytics controls (analytics-controls.js; canvas "Mediaseer App", SiteAnalytics.dc.html): the box at
   the bottom right, on the site and in the docs. Its own colours, as it sits over either. */
.sa-box {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 1000;
  box-sizing: border-box;
  width: 760px;
  max-width: calc(100vw - 48px);
  max-height: calc(100vh - 48px);
  padding: 14px 14px 14px 20px;
  overflow: auto;
  border-radius: 16px;
  color: #ffffff;
  background: #141214;
  box-shadow:
    0 0 0 1px #2a2730,
    0 12px 32px -16px rgb(0 0 0 / 70%);
  font: inherit;
  line-height: normal;
  text-align: left;
  animation: sa-up 0.24s cubic-bezier(0.2, 0, 0, 1) both;
}
.sa-box[hidden],
.sa-box [hidden] {
  display: none !important;
}
.sa-main {
  display: flex;
  align-items: center;
  gap: 20px;
}
.sa-text {
  flex: 1;
  min-width: 0;
}
.sa-p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: #8b8790;
}
.sa-p strong {
  font-weight: 500;
  color: #ffffff;
}
.sa-line {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 6px 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: #d9d4dc;
}
.sa-line i {
  flex: none;
  width: 8px;
  height: 8px;
  margin-top: 5px;
  border-radius: 2px;
  background: #8b8790;
}
.sa-line i.is-red {
  background: #ff7a8a;
}
.sa-line i.is-pink {
  background: #f2b3e6;
}
.sa-line svg {
  flex: none;
  margin-top: 1px;
  color: #f2b3e6;
}
.sa-spin {
  display: inline-block;
  flex: none;
  width: 12px;
  height: 12px;
  margin-top: 3px;
  box-sizing: border-box;
  border: 1.75px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: sa-spin 0.8s linear infinite;
}
.sa-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 4px;
  margin: 2px 0 -6px -8px;
}
.sa-links .sa-line {
  margin: 0;
  padding: 0 8px;
}
.sa-link {
  display: inline-flex;
  height: 32px;
  align-items: center;
  gap: 6px;
  padding: 0 8px;
  border: 0;
  border-radius: 8px;
  color: #8b8790;
  background: none;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  transition: color 0.15s;
}
.sa-link:hover {
  color: #ffffff;
}
.sa-link:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}
.sa-link svg {
  transition: transform 0.18s cubic-bezier(0.2, 0, 0, 1);
}
.sa-link svg.is-open {
  transform: rotate(180deg);
}
.sa-acts {
  display: flex;
  flex: none;
  flex-wrap: wrap;
  gap: 8px;
}
.sa-btn,
.sa-open {
  position: relative;
  display: inline-flex;
  box-sizing: border-box;
  height: 40px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  color: #ffffff;
  background: transparent;
  box-shadow: inset 0 0 0 1px #4a4650;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition:
    box-shadow 0.15s,
    background-color 0.15s,
    opacity 0.15s;
}
.sa-btn:hover,
.sa-open:hover {
  box-shadow: inset 0 0 0 1px #8b8790;
}
.sa-btn:disabled,
.sa-btn:has(input:disabled) {
  cursor: not-allowed;
  opacity: 0.5;
}
.sa-btn input {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  cursor: inherit;
}
.sa-btn.is-pink {
  color: #020102;
  background: #f2b3e6;
  box-shadow: none;
}
.sa-btn.is-on {
  box-shadow: inset 0 0 0 1.5px #f2b3e6;
}
.sa-btn.is-pink.is-on {
  box-shadow:
    0 0 0 2px #141214,
    0 0 0 3.5px #f2b3e6;
}
.sa-btn.is-danger {
  color: #020102;
  background: #ff7a8a;
  box-shadow: none;
}
.sa-btn.is-danger:hover {
  background: #ff94a1;
}
.sa-x {
  display: grid;
  flex: none;
  width: 36px;
  height: 36px;
  margin-left: -8px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 999px;
  color: #8b8790;
  background: transparent;
  cursor: pointer;
}
.sa-x:hover {
  color: #ffffff;
  background: #020102;
}
.sa-confirm {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  margin-top: 14px;
  padding: 14px;
  border-radius: 14px;
  background: #020102;
  animation: sa-in 0.18s cubic-bezier(0.2, 0, 0, 1) both;
}
.sa-confirm p {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: #d9d4dc;
}
.sa-confirm .sa-btn {
  height: 36px;
}
.sa-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
  margin: 14px 0 4px;
  padding-top: 14px;
  border-top: 1px solid #2a2730;
  font-size: 13px;
  line-height: 1.5;
  animation: sa-in 0.18s cubic-bezier(0.2, 0, 0, 1) both;
}
.sa-list dl,
.sa-list dd {
  margin: 0;
}
.sa-list dt {
  font-weight: 500;
  color: #ffffff;
}
.sa-list dd {
  margin-top: 2px;
  color: #8b8790;
}
.sa-box :focus-visible,
.sa-btn:has(input:focus-visible),
.sa-open:focus-visible {
  outline: 2px solid #f2b3e6;
  outline-offset: 2px;
}
.sa-btn input:focus-visible {
  outline: none;
}
/* A page without a link of its own to the controls (the docs): a button in the corner opens them. */
.sa-open {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 1000;
  background: #141214;
}
.sa-open[hidden] {
  display: none;
}
@keyframes sa-in {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
}
@keyframes sa-up {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
}
@keyframes sa-spin {
  to {
    transform: rotate(360deg);
  }
}
@media (max-width: 767px) {
  .sa-box {
    right: 12px;
    bottom: 12px;
    left: 12px;
    width: auto;
    max-width: none;
    padding: 16px;
  }
  .sa-main {
    flex-wrap: wrap;
    gap: 12px;
  }
  .sa-text {
    flex: 1 1 calc(100% - 40px);
  }
  .sa-x {
    order: 2;
    align-self: flex-start;
    margin: -8px -8px 0 0;
  }
  .sa-acts {
    order: 3;
    flex: 1 1 100%;
  }
  .sa-acts .sa-btn {
    flex: 1;
  }
  .sa-list {
    grid-template-columns: 1fr;
  }
}
@media (prefers-reduced-motion: reduce) {
  .sa-box,
  .sa-confirm,
  .sa-list {
    animation: none;
  }
  .sa-spin {
    animation-duration: 2.4s;
  }
}
