/* Header in the colors of KTC Lizenz, like in the previous admin console. */
.pf-v5-c-masthead {
    --pf-v5-c-masthead--BackgroundColor: #3c8dbc;
}

/* In the dark mode the toolbar of the header has its own background. */
.pf-v5-c-masthead .pf-v5-c-toolbar {
    --pf-v5-c-toolbar--BackgroundColor: transparent;
}

/* The menus and buttons in the header are white on its blue, without frame, and highlighted when used. */
.pf-v5-c-masthead .pf-v5-c-menu-toggle {
    --pf-v5-c-menu-toggle--Color: #fff;
    --pf-v5-c-menu-toggle--BackgroundColor: transparent;
    --pf-v5-c-menu-toggle--before--BorderTopColor: transparent;
    --pf-v5-c-menu-toggle--before--BorderRightColor: transparent;
    --pf-v5-c-menu-toggle--before--BorderBottomColor: transparent;
    --pf-v5-c-menu-toggle--before--BorderLeftColor: transparent;
    --pf-v5-c-menu-toggle--after--BorderBottomColor: transparent;
    --pf-v5-c-menu-toggle--hover--BackgroundColor: rgba(255, 255, 255, 0.15);
    --pf-v5-c-menu-toggle--hover--after--BorderBottomColor: #fff;
    --pf-v5-c-menu-toggle--focus--BackgroundColor: rgba(255, 255, 255, 0.15);
    --pf-v5-c-menu-toggle--focus--after--BorderBottomColor: #fff;
    --pf-v5-c-menu-toggle--active--BackgroundColor: rgba(255, 255, 255, 0.15);
    --pf-v5-c-menu-toggle--active--after--BorderBottomColor: #fff;
    --pf-v5-c-menu-toggle--m-expanded--Color: #fff;
    --pf-v5-c-menu-toggle--m-expanded--BackgroundColor: rgba(255, 255, 255, 0.15);
    --pf-v5-c-menu-toggle--m-expanded--after--BorderBottomColor: #fff;
    --pf-v5-c-menu-toggle--m-plain--Color: #fff;
    --pf-v5-c-menu-toggle--m-plain--hover--Color: #fff;
    --pf-v5-c-menu-toggle--m-plain--expanded--Color: #fff;
    border-radius: 3px;
}

.pf-v5-c-masthead .pf-v5-c-button.pf-m-plain {
    --pf-v5-c-button--m-plain--Color: #fff;
    --pf-v5-c-button--m-plain--hover--Color: #fff;
    --pf-v5-c-button--m-plain--focus--Color: #fff;
    --pf-v5-c-button--m-plain--active--Color: #fff;
}

.keycloak__pageheader_brand {
    height: 32px;
}

/* The checkboxes inserted into tables are aligned with the texts of the rows. */
td[data-ktc-license] input[type="checkbox"] {
    margin: 0;
    vertical-align: middle;
}

/* KTC Lizenz uses only the realm "master", so neither the current realm nor the management of realms is shown. */
.pf-v5-c-nav__section-title:has([data-testid="currentRealm"]),
.pf-v5-c-nav__section:has([data-testid="nav-item-realms"]) {
    display: none;
}

/* The applications are shown without the tabs for their registration by other applications. */
.pf-v5-c-tabs__item:has(> [id*="/clients/initial-access-token"]),
.pf-v5-c-tabs__item:has(> [id*="/clients/client-registration"]) {
    display: none;
}

/* The applications are listed without their type and home URL. */
table:has(tbody a[href*="/clients/"][href$="/settings"]) :is(th, td):is(:nth-child(3), :nth-child(5)) {
    display: none;
}

/* The customers are listed only with their name and email address, without first and last name. */
table[data-ktc-license-customers="users"] :is(th, td):is(:nth-child(4), :nth-child(5)),
table[data-ktc-license-customers="users-in-role"] :is(th, td):is(:nth-child(3), :nth-child(4)) {
    display: none;
}

/* PatternFly takes the hidden tabs as scrolled out of view and would show scroll buttons. */
.pf-v5-c-tabs:has([id*="/clients/client-registration"]) .pf-v5-c-tabs__scroll-button {
    display: none;
}

/* Menu reduced to the entries of the previous admin console. */
[data-testid="nav-item-client-scopes"],
[data-testid="nav-item-roles"],
[data-testid="nav-item-groups"],
[data-testid="nav-item-authentication"],
[data-testid="nav-item-identity-providers"],
[data-testid="nav-item-user-federation"],
[data-testid="nav-item-workflows"] {
    display: none;
}
