.measurement {
  color-scheme: dark;
  color: #edeff4;
  font-family: var(--font, Montserrat, "Segoe UI", sans-serif);
  font-size: .875rem;
  line-height: 1.6;
  overflow-wrap: anywhere;
}
.measurement[hidden] { display: none !important; }
.no-js .measurement-preferences-button { display: none; }
.measurement h2 { margin: 0 0 .6rem; font-size: 1.2rem; line-height: 1.3; letter-spacing: -.015em; }
.measurement p { margin: 0 0 .7rem; }
.measurement p:last-child { margin-bottom: 0; }
.measurement a { color: #a6cdff; text-decoration: underline; text-underline-offset: .2em; }
.measurement a:hover { color: #edeff4; }
.measurement :focus-visible, .measurement-preferences-button:focus-visible {
  outline: 3px solid #a6cdff;
  outline-offset: 4px;
}
.measurement-banner {
  position: fixed;
  z-index: 50;
  inset-inline: 0;
  bottom: 1rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(20rem, 26rem);
  align-items: center;
  gap: 1.5rem;
  width: min(74rem, calc(100% - 2rem));
  max-height: 70vh;
  margin-inline: auto;
  padding: 1.25rem 1.5rem;
  overflow: auto;
  overscroll-behavior: contain;
  background: #0e1624;
  border: 1px solid #718097;
  border-radius: 3px;
  box-shadow: 0 10px 38px rgb(0 0 0 / 35%);
}
.measurement-banner-copy { min-width: 0; }
.measurement-banner-copy p { color: #c8cfda; }
.measurement-banner-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
.measurement-button, .measurement-settings-button, .measurement-close-button {
  min-height: 44px;
  padding: .7rem .85rem;
  border: 1px solid #a6cdff;
  border-radius: 2px;
  background: #0e1624;
  color: #edeff4;
  font: inherit;
  font-weight: 650;
  line-height: 1.4;
  text-align: center;
  cursor: pointer;
}
.measurement-button:hover, .measurement-close-button:hover { background: #21334d; }
.measurement-settings-button { grid-column: 1 / -1; border-color: transparent; color: #a6cdff; text-decoration: underline; text-underline-offset: .2em; }
.measurement-settings-button:hover { color: #edeff4; }
.measurement-dialog {
  width: min(36rem, calc(100% - 2rem));
  max-height: calc(100vh - 2rem);
  max-height: calc(100dvh - 2rem);
  margin: auto;
  padding: 1.5rem;
  overflow: auto;
  overscroll-behavior: contain;
  background: #0e1624;
  border: 1px solid #718097;
  border-radius: 3px;
}
.measurement-dialog:not([open]) { display: none; }
.measurement-dialog::backdrop { background: rgb(5 8 15 / 80%); }
.measurement-dialog-header { display: flex; justify-content: space-between; align-items: start; gap: 1rem; margin-bottom: .75rem; }
.measurement-dialog-header h2 { margin-block: .5rem 0; }
.measurement-close-form { flex: 0 0 auto; margin: 0; }
.measurement-close-button { padding-inline: .75rem; }
.measurement-choices { min-width: 0; margin: 1.25rem 0; padding: 0; border: 0; }
.measurement-choices legend { margin-bottom: .6rem; padding: 0; color: #c8cfda; font-weight: 650; }
.measurement-choice { display: flex; align-items: start; gap: .8rem; padding: 1rem 0; border-top: 1px solid #53647c; cursor: pointer; }
.measurement-choice input { flex: 0 0 auto; width: 22px; height: 22px; margin: .1rem 0 0; accent-color: #a6cdff; cursor: pointer; }
.measurement-choice input:disabled { cursor: not-allowed; }
.measurement-choice strong { display: block; margin-bottom: .3rem; color: #edeff4; font-size: .95rem; }
.measurement-choice span span { display: block; color: #c8cfda; }
.measurement-note { padding: .9rem; border-left: 2px solid #a6cdff; background: #172438; color: #c8cfda; }
.measurement-dialog-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 1.25rem; }
.measurement-dialog-actions > a { padding-block: .65rem; }
.measurement-preferences-button {
  min-height: 44px;
  padding: .5rem 0;
  border: 0;
  background: transparent;
  color: #c8cfda;
  font-size: inherit;
  text-align: start;
  text-decoration: underline;
  text-underline-offset: .2em;
  cursor: pointer;
}
.measurement-preferences-button:hover { color: #edeff4; }
@media (max-width: 900px) {
  .measurement-banner { grid-template-columns: minmax(0, 1fr); gap: .9rem; }
}
@media (max-width: 480px) {
  .measurement-banner { bottom: .5rem; width: calc(100% - 1rem); padding: 1rem; }
  .measurement-banner-actions { gap: .5rem; }
  .measurement-dialog { width: calc(100% - 1rem); max-height: calc(100vh - 1rem); max-height: calc(100dvh - 1rem); padding: 1rem; }
  .measurement-dialog-actions { align-items: stretch; flex-direction: column; gap: .6rem; }
  .measurement-dialog-actions > a { align-self: start; }
}
@media (forced-colors: active) {
  .measurement-banner, .measurement-dialog, .measurement-button, .measurement-close-button, .measurement-choice { border-color: CanvasText; }
  .measurement :focus-visible, .measurement-preferences-button:focus-visible { outline-color: Highlight; }
}
