/* R697: keep the complete workspace persistence group discoverable in the active command-center header. */
body.r120-rice-ui .app-header .header-tools {
  min-width: 0 !important;
  flex-wrap: wrap !important;
  align-items: center !important;
  gap: 8px !important;
}

body.r120-rice-ui .app-header .header-actions {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  flex: 0 1 auto !important;
  min-width: 0 !important;
  max-width: 100% !important;
  flex-wrap: wrap !important;
  gap: 7px !important;
  order: 3 !important;
}

body.r120-rice-ui .app-header .header-actions #autosaveStatus,
body.r120-rice-ui .app-header .header-actions #saveButton,
body.r120-rice-ui .app-header .header-actions #loadButton,
body.r120-rice-ui .app-header .header-actions #clearAutosaveButton {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  visibility: visible !important;
  opacity: 1 !important;
  min-height: 42px !important;
  white-space: nowrap !important;
}

body.r120-rice-ui .app-header .header-actions #saveButton,
body.r120-rice-ui .app-header .header-actions #loadButton,
body.r120-rice-ui .app-header .header-actions #clearAutosaveButton {
  padding: 0 14px !important;
  border-radius: 12px !important;
  font-size: 12px !important;
  font-weight: 700 !important;
}

body.r120-rice-ui .app-header .header-actions #loadButton {
  color: var(--r121-text, #f8f7fb) !important;
  background: var(--r121-control, rgba(255,255,255,.08)) !important;
  border: 1px solid var(--r121-line, rgba(255,255,255,.14)) !important;
}

body.r120-rice-ui .app-header .header-actions #clearAutosaveButton {
  color: #b43737 !important;
  background: color-mix(in srgb, #d65757 7%, var(--r121-control, #fff)) !important;
  border: 1px solid color-mix(in srgb, #d65757 30%, var(--r121-line, #ddd)) !important;
}

body.r120-rice-ui .app-header .header-actions #loadButton:hover:not(:disabled),
body.r120-rice-ui .app-header .header-actions #clearAutosaveButton:hover:not(:disabled) {
  transform: translateY(-1px) !important;
  background: var(--r121-control-hover, rgba(255,255,255,.14)) !important;
}

@media (max-width: 1100px) {
  body.r120-rice-ui .app-header {
    flex-wrap: wrap !important;
  }

  body.r120-rice-ui .app-header .header-leading,
  body.r120-rice-ui .app-header .header-tools {
    flex: 1 1 100% !important;
    width: 100% !important;
  }

  body.r120-rice-ui .app-header .header-tools {
    justify-content: flex-start !important;
  }

  body.r120-rice-ui .app-header .header-actions {
    justify-content: flex-start !important;
  }
}

@media (max-width: 620px) {
  body.r120-rice-ui .app-header .header-actions {
    display: flex !important;
    width: 100% !important;
    justify-content: flex-start !important;
    flex-basis: 100% !important;
  }

  body.r120-rice-ui .app-header .header-actions #autosaveStatus {
    min-width: 104px !important;
    min-height: 38px !important;
    padding: 0 10px !important;
  }

  body.r120-rice-ui .app-header .header-actions #saveButton,
  body.r120-rice-ui .app-header .header-actions #loadButton,
  body.r120-rice-ui .app-header .header-actions #clearAutosaveButton {
    min-height: 38px !important;
    padding: 0 11px !important;
  }

  body.r120-rice-ui .app-header .header-actions #clearAutosaveButton {
    flex: 1 1 100% !important;
  }
}
