.analytics-settings {
  padding: .15rem 0;
  border: 0;
  color: #0744ae;
  background: transparent;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: .2em;
  cursor: pointer;
}
.analytics-preferences {
  position: fixed;
  z-index: 10000;
  right: max(.75rem, env(safe-area-inset-right));
  bottom: max(.75rem, env(safe-area-inset-bottom));
  width: min(24rem, calc(100% - 1.5rem));
  max-height: calc(100vh - 1.5rem);
  overflow: auto;
  padding: 1rem;
  border: 1px solid #a5c5ff;
  border-radius: .85rem;
  background: #f5faff;
  box-shadow: 0 8px 32px rgba(23, 56, 107, .2);
  color: #111c30;
  font: .94rem/1.45 system-ui, sans-serif;
  text-align: left;
}
.analytics-preferences[hidden], .analytics-settings[hidden] { display: none; }
.analytics-preferences h2 { margin: 0 0 .45rem; color: inherit; font: 700 1.1rem/1.25 system-ui, sans-serif; }
.analytics-preferences p { margin: 0 0 .65rem; }
.analytics-preferences a { color: #0744ae; }
.analytics-actions { display: flex; flex-wrap: wrap; gap: .55rem; }
.analytics-actions button {
  flex: 1;
  min-height: 44px;
  padding: .4rem .65rem;
  border: 1px solid #a5c5ff;
  border-radius: .5rem;
  color: #0744ae;
  background: #fff;
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}
.analytics-actions button:hover { background: #e8f2ff; }
.analytics-settings:focus-visible, .analytics-preferences :focus-visible {
  outline: 2px solid #0744ae;
  outline-offset: 2px;
}
@media (max-width: 767px) {
  .analytics-settings { min-height: 44px; }
}
