:root {
    --color-primary: #4CAF50;
    --color-primary-dark: #2E7D32;
    --color-primary-light: #E8F5E9;
    --color-accent-yellow: #FFB300;
    --color-accent-blue: #03A9F4;
    --color-secondary-info: #607D8B;
    --color-text-body: #212121;
    --color-text-muted: #757575;
    --color-border: #E0E0E0;
    --color-error: #D32F2F;
    --color-white: #FFFFFF;
    --color-primary-background: #E8F5E9;
    --color-secondary-background: #3E713E;
    --kc-link-color: #238023;
    --kc-link-hover-color: #0A1D0A;
    --bs-highlight-bg: #adeeb2;
}

html {
  font-size: 16px;
}

body {
    background-color: var(--color-primary-background);
    color: var(--color-text-body);
}

header, nav {
    background-color: var(--color-primary-dark);
    color: var(--color-white);
}

a.navbar-brand {
    color: var(--color-white);
    font-size: 24px;
}

footer {
    background-color: var(--color-primary);
}

.shadow-danger {
    box-shadow: 0 0 2rem rgba(200, 0, 0, 0.5) !important;
}

.autocomplete-container {
    position: relative;
}

.autocomplete-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1050;
    max-height: 250px;
    overflow-y: auto;
    background: var(--color-primary-background);
    border: 1px solid #dee2e6;
    border-top: none;
    border-radius: 0 0 0.375rem 0.375rem;
}

.autocomplete-item {
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    border-bottom: 1px solid #f8f9fa;
}

    .autocomplete-item:hover,
    .autocomplete-item.active {
        background-color: var(--color-primary);
    }

    .autocomplete-item:last-child {
        border-bottom: none;
    }

.autocomplete-loading {
    padding: 0.5rem 0.75rem;
    text-align: center;
    color: #6c757d;
}

.autocomplete-no-results {
    padding: 0.5rem 0.75rem;
    text-align: center;
    color: #6c757d;
    font-style: italic;
}

input[type="number"] {
    text-align: start;
}

th:first-child {
    border-top-left-radius: var(--bs-border-radius);
}

th:last-child {
    border-top-right-radius: var(--bs-border-radius);
}

tbody > tr:last-child > td:first-child {
    border-bottom-left-radius: var(--bs-border-radius);
}

tbody > tr:last-child > td:last-child {
    border-bottom-right-radius: var(--bs-border-radius);
}

.fade-in { opacity: 0; transition: opacity 0.5s; }
.fade-in.show { opacity: 1; }

tr td.button-cell button {
    opacity: 0;
    transition: opacity 0.15s;
}

tr:hover td.button-cell button {
    opacity: 1;
}

button.btn-transparent, a.btn-transparent {
    color: var(--color-white);
    background-color: transparent !important;
    border: none;
    box-shadow: none;
}

button.btn-transparent:active, a.btn-transparentactive {
    border: none;
}

a {
    text-decoration: none;
    font-weight: 400;
    color: var(--kc-link-color);
    transition: color ease-in-out 0.15s;
}

a:hover {
    text-decoration: underline;
    color: var(--kc-link-hover-color);
}

a.btn {
    text-decoration: none;
}

.btn-nav-subtle {
    background-color: transparent;
    border: none;
    color: #6c757d; /* Light grey */
    border-radius: 0.375rem;
    transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    min-height: 2.5rem;
    opacity: 0.7;
    padding: 0;
}

.btn-nav-subtle:hover {
    color: #495057; /* Darker grey on hover */
    opacity: 1;
}

.btn-nav-subtle:focus {
    color: #495057;
    outline: 0;
    opacity: 1;
}

.btn-nav-subtle:active {
    color: #343a40;
}

.btn-nav-subtle:disabled {
    color: #adb5bd;
    cursor: not-allowed;
}

/* Alternative sizing options */
.btn-nav-subtle.btn-sm {
    min-width: 2rem;
    min-height: 2rem;
}

.btn-nav-subtle.btn-lg {
    min-width: 3rem;
    min-height: 3rem;
}

/* Alternative styling options */
.btn-nav-subtle.btn-danger {
    color: #D32F2F;
}

.btn-nav-subtle.btn-danger:hover {
    color: #f33030;
    background-color: transparent;
    border: none;
}

.btn-nav-subtle.btn-danger:focus {
    color: #f33030;
    background-color: transparent;
    border: none;
}

cite {
    text-decoration: underline dotted;
    font-style: normal;
    cursor: default;
}

dfn {
    text-decoration: none;
    font-style: normal;
    cursor: help;
    color: var(--bs-emphasis-color);
    background-color: var(--bs-highlight-bg);
}

.dfn-popover {
    --bs-popover-border-color: var(--color-primary);
    --bs-popover-header-bg: var(--color-primary-dark);
    --bs-popover-header-color: var(--color-primary-light);
}