.analytics-consent {
  position: fixed;
  z-index: 95;
  right: 1rem;
  bottom: 1rem;
  width: min(23rem, calc(100vw - 2rem));
  max-height: calc(100svh - 2rem);
  overflow: auto;
  padding: 1.15rem 1.25rem 1.2rem;
  border: 1px solid #d8cec0;
  border-radius: .8rem;
  background: #fffdf8;
  box-shadow: 0 5px 22px #393c301c;
  color: #393c30;
  font: 400 .84rem/1.55 'DM Sans', sans-serif;
}

.analytics-consent[hidden],
#analytics-save-error[hidden] {
  display: none;
}

.analytics-consent h2 {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin: 0 0 .35rem;
  color: #393c30;
  font: 700 1.15rem/1.25 Fraunces, Georgia, serif;
  letter-spacing: -.02em;
}

.analytics-consent h2::before {
  content: '✳︎';
  color: #b8503e;
  font: 400 1.1rem/1 'DM Sans', sans-serif;
}

.analytics-consent p {
  margin: 0;
  color: #5e6054;
}

.analytics-consent-privacy {
  display: inline-block;
  margin-top: .4rem;
  color: #7e493e;
  font-weight: 600;
  text-underline-offset: 3px;
}

#analytics-save-error {
  margin-top: .55rem;
  color: #9d392d;
}

.analytics-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .55rem;
  margin-top: .9rem;
}

.analytics-actions form {
  min-width: 0;
  margin: 0;
}

.analytics-actions button {
  width: 100%;
  min-height: 44px;
  padding: .5rem .55rem;
  border: 1px solid #bcb6a8;
  border-radius: .45rem;
  background: #fbf7ee;
  color: #393c30;
  font: 600 .78rem/1.25 'DM Sans', sans-serif;
  cursor: pointer;
}

.analytics-actions button:hover {
  border-color: #a45d4d;
  background: #f8eee4;
}

.analytics-actions button:focus-visible,
.analytics-consent-privacy:focus-visible,
.analytics-preference-link:focus-visible {
  outline: 3px solid #547447;
  outline-offset: 3px;
}

@media (max-width: 420px) {
  .analytics-consent {
    right: .65rem;
    bottom: .65rem;
    width: calc(100vw - 1.3rem);
    max-height: calc(100svh - 1.3rem);
    padding: 1rem;
  }
}
