/* Hide the repository module across the UI.

   Loaded by the redmine_custom view hook ONLY when the plugin setting
   `enable_repository_module` is off (the default). The repository feature is
   also inert at the data level (provisioning sets `enabled_scm` to empty), so
   this just removes the confusing UI surfaces; toggling the setting on drops
   this stylesheet and everything reappears. */

/* Admin > Settings > Repositories tab (and its menu item). */
body.controller-settings #tab-repositories,
body.controller-settings li:has(> #tab-repositories),
/* Admin > Settings > Projects: the "repository" default-module checkbox. */
#tab-content-projects label:has(> input[value="repository"]),
/* Project settings / new project: the repository module enable checkbox. */
#project_enabled_module_names_repository,
label:has(> #project_enabled_module_names_repository),
#module_repository,
/* Per-project navigation: the Repository tab. */
div.tabs #tab-repositories,
/* Roles and permissions: the SCM group header row + repository permissions. */
tr:has(+ tr.permission-view_changesets),
tr.permission-view_changesets,
tr.permission-browse_repository,
tr.permission-commit_access,
tr.permission-manage_repository {
  display: none !important;
}
