.page-top-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-width: 44px;
  min-height: 44px;
  padding: 10px 15px;
  border: 1px solid #d1d7e0;
  border-radius: 4px;
  background: #173d62;
  color: #fff8e8;
  font: 600 14px/1.4 var(--body, 'Segoe UI', Arial, sans-serif);
  cursor: pointer;
}
.page-top-button svg { width: 20px; height: 20px; flex-shrink: 0; }
.page-top-button:hover { background: #2d3f56; }
.page-top-button:active { background: #0b1729; }
.page-top-button:focus-visible { outline: 3px solid #ffb088; outline-offset: 4px; }
.page-top-floating {
  position: fixed;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  z-index: 25;
  box-shadow: 0 6px 18px #070c1345;
}
.page-top-floating[hidden] { display: none; }
.modal-open .page-top-floating { visibility: hidden; }
.site-footer .page-top-button { justify-self: start; margin: 0; }
.site-footer.page-top-clearance { padding-bottom: max(84px, calc(64px + env(safe-area-inset-bottom))); }
.draft-bottom { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.draft-bottom p { margin: 0; }
.draft-bottom .page-top-button { flex-shrink: 0; }
@media (max-width: 640px) {
  .page-top-floating { right: max(12px, env(safe-area-inset-right)); bottom: max(12px, env(safe-area-inset-bottom)); }
  .draft-bottom { flex-wrap: wrap; }
}
@media print { .page-top-button { display: none !important; } }
