/* Implement tabbed code blocks for mdBook. */
/* SPDX-License-Identifier: MIT OR CC-BY-SA-4.0 */
/* SPDX-FileCopyrightText: 2022 Rob Moss <robm.dev@gmail.com> */

/* added inline-flex capabilities for the tab bar*/
.tabbed-blocks ul.tab-bar {
    display: inline-flex; /* addition */
    flex-wrap: wrap; /* addition */
    justify-content: space-between; /* addition */
    padding: 0;
    margin: 0;
}
/* added ability for tab widths to flex uniformly in admonition boxes*/
.tabbed-blocks ul.tab-bar li {
    display: inline-flex; /* changed from inline-block*/
    flex-grow: 1; /* addition */
    min-width: 4em;
    padding: 0.5em 1em;
    text-align: center;
    justify-content: center; /* addition */
    user-select: none;
}

/* Use the background and border colours from mdbook-admonish info blocks. */
/* Note: altered to match Aggie theme */
.tabbed-blocks ul.tab-bar li.active {
    background-color:  rgb(75 0 0 / 20%);
    border-top: 4px solid var(--sidebar-bg);
}

/* added left and right borders to the boxes */
.tabbed-blocks ul.tab-bar li {
    border-top: 4px solid rgba(127, 127, 127, 0.5);
    border-left: 1px solid rgba(127, 127, 127, 0.5);
    border-right: 1px solid rgba(127, 127, 127, 0.5);
}

/* Remove vertical space between tabs and code blocks. */
.tabbed-blocks pre {
    margin-top: 0;
}