.khm-panel {
  position: fixed;
  z-index: 100001;
  inset: auto 1rem 4.5rem auto;
  box-sizing: border-box;
  width: min(30rem, calc(100vw - 2rem));
  max-height: calc(100dvh - 6rem);
  overflow-y: auto;
  padding: 1.1rem;
  border: 1px solid #777;
  border-radius: .5rem;
  background: #fff;
  color: #222;
  box-shadow: 0 .2rem 1rem #0002;
  font-size: 1rem;
  line-height: 1.7;
  text-align: left;
}
.khm-panel[hidden] { display: none !important; }
.khm-panel h2 { margin: 0 0 .5rem; padding: 0; border: 0; background: none; color: inherit; font-size: 1.1rem; }
.khm-panel p { margin: .5rem 0; }
.khm-panel a { color: #24486b; text-decoration: underline; }
.khm-actions { display: flex; gap: .75rem; }
.khm-panel .khm-actions button {
  flex: 1;
  min-height: 44px;
  padding: .55rem;
  border: 1px solid #444;
  border-radius: .25rem;
  background: #fff;
  color: #222;
  font: inherit;
  cursor: pointer;
}
.khm-panel .khm-actions button:hover { background: #f1f1f1; }
.khm-panel .khm-actions button:disabled { opacity: .55; cursor: not-allowed; }
.khm-panel .khm-later { margin-top: .65rem; min-height: 44px; border: 0; padding: .3rem; background: none; color: #333; font: inherit; text-decoration: underline; cursor: pointer; }
.khm-settings-button { position: fixed; z-index: 100000; right: 1rem; bottom: 1rem; min-height: 44px; border: 1px solid #666; border-radius: .3rem; padding: .45rem .7rem; background: #fff; color: #222; font-size: .85rem; cursor: pointer; }
.khm-panel button:focus-visible, .khm-panel a:focus-visible, .khm-settings-button:focus-visible { outline: 3px solid #24486b; outline-offset: 3px; }
@media (max-width: 360px) { .khm-actions { flex-direction: column; } }
