#analytics-privacy {
  color: var(--fg, #1d2330);
  font: 15px/1.5 'Lato', -apple-system, 'Segoe UI', Helvetica, Arial, sans-serif;
}

#analytics-privacy [hidden] { display: none !important; }

#analytics-settings,
#analytics-consent {
  position: fixed;
  z-index: 100;
  background: var(--bg, #fff);
  border: 1px solid var(--border, #c7cdd6);
  border-radius: 10px;
  box-shadow: 0 4px 24px #0002;
}

#analytics-settings { right: 16px; bottom: 16px; }

#analytics-consent {
  box-sizing: border-box;
  right: 16px;
  bottom: 76px;
  width: min(600px, calc(100% - 32px));
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  padding: 20px;
  scroll-margin: 0;
}

#analytics-consent h2 {
  font-size: 20px;
  margin: 0 0 10px;
  padding: 0;
  border: 0;
}

#analytics-consent p { font: inherit; margin: 10px 0; }
#analytics-consent a { color: var(--accent, #1f5fbf); font: inherit; text-decoration: underline; }
#analytics-consent summary { cursor: pointer; font-weight: 700; }

#analytics-consent-status { font-size: 14px; }
.analytics-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }

#analytics-privacy button {
  min-height: 44px;
  padding: 10px 14px;
  border: 1px solid var(--accent, #1f5fbf);
  border-radius: 6px;
  color: var(--fg, #1d2330);
  background: var(--bg, #fff);
  font: inherit;
  cursor: pointer;
}

#analytics-privacy button:hover { background: var(--card, #f6f8fb); }
#analytics-privacy :focus-visible { outline: 3px solid var(--accent, #1f5fbf); outline-offset: 3px; }
#analytics-consent-title:focus { outline-offset: 3px; }
#analytics-consent #analytics-close { flex-basis: 100%; }

@media (max-width: 480px) {
  #analytics-consent { padding: 16px; }
  .analytics-actions button { flex: 1 1 0; }
}

@media print {
  #analytics-privacy { display: none; }
}
