html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
    position: relative;
    min-height: 100%;
}

body {
    margin-bottom: 60px;
    font-family: 'Montserrat', sans-serif;
    font-family: 'ITC Mendoza Roman Std', 'Montserrat', serif; /* Use a fallback font like 'serif' */
    font-size: 18px; /* Text size */
    line-height: 28px; /* Line spacing */
    color: #1A3877; /* Font color */
    margin: 0; /* Remove default body margin */
    padding: 0; /* Remove default body padding */
}

h1 {
    font-family: 'Montserrat', sans-serif; /* Font family */
    font-weight: bolder; /* Bold text */
    font-size: larger; /* Text size */
    line-height: 55px; /* Line spacing */
    color: #1A3877; /* Font color */
    margin: 0 0 20px 0; /* Optional: Space below H1 */
}

h2 {
    font-family: 'Montserrat', sans-serif; /* Font family */
    font-weight: bold; /* Bold text */
    font-size: 35px; /* Text size */
    line-height: 45px; /* Line spacing */
    color: #1A3877; /* Font color */
    margin: 0 0 15px 0; /* Optional: Space below H2 */
}

h3 {
    font-family: 'Montserrat', sans-serif; /* Font family */
    font-weight: 500; /* Medium weight */
    font-size: 30px; /* Font size */
    line-height: 40px; /* Line height */
    color: #1A3877; /* Font color */
    margin: 0 0 10px 0; /* Optional: Spacing below H3 */
}

h4 {
    font-family: 'Montserrat', sans-serif; /* Font family */
    font-weight: 500; /* Medium weight */
    font-size: 25px; /* Font size */
    line-height: 35px; /* Line height */
    color: #1A3877; /* Font color */
    margin: 0 0 8px 0; /* Optional: Spacing below H4 */
}

.btn {
    font-family: 'Montserrat', sans-serif; /* Font family */
    font-weight: 700; /* Bold */
    font-size: 14px; /* Font size */
    letter-spacing: 1.07px; /* Tracking/spacing */
    text-transform: uppercase; /* All caps */
    text-align: center; /* Centered text */
    color: #1A3877; /* Font color */
    margin: 0;
}

.label {
    font-family: 'Montserrat', sans-serif; /* Font family */
    font-weight: 500; /* Medium weight */
    font-size: 16px; /* Font size */
    color: #BA6D06; /* Font color */
    margin: 0;
}

.margin-main {
    margin-left: 5%;
    margin-right: 5%;
    width: 90%;
}

/* Berenschot specif implementation */
.custom-navbar-bg {
    background-color: #1E2C60; /* Berenschot blue color */
}

/* Custom navbar text color */
.navbar .navbar-nav .nav-link {
    color: white !important;
}

.navbar .navbar-brand {
    color: white !important;
}

.navbar .navbar-text {
    color: white !important;
}

.navbar-brand {
    width: 200px; /* Set a fixed width */
    height: auto; /* Maintain aspect ratio */
}

.navbar-collapse {
    margin-left: 50px; /* Adjust the value as needed */
}

/* The username changes color when hovered */

/* Initial styling */
#logoutButton {
    background: none;
    border: none;
    padding: 0;
    font-size: 16px;
    color: white;
    text-align: left;
    display: inline-flex;
    align-items: center;
}

/* Initially, hide the "Log out" text */
.logout-text {
    visibility: hidden;
    margin-right: 5px;
    transition: visibility 0s, color 0.3s ease;
}

#logoutButton:hover {
    color: orange; /* Change entire button text color to orange */
}

/* On hover: Show "Log out" and change text color to orange */
#logoutButton:hover .logout-text {
    visibility: visible;
    color: orange;
}

.custom-bs-bgcolor {
    background-color: #1E2C60; /* Berenschot blue color */
    color: whitesmoke;
}

.custom-bs-bgcolor:hover {
    background-color: #1E2C90;
    color: white; /* Grey color on hover */
}

.custom-bs-bgcolor-light {
    background-color: #f0f4fa8b;
    color: #1E2C60;
}

.brand-rotated {
    color: white;
    background: #1E2C60;
    transition: all .2s ease;
    opacity: 1;
    position: absolute;
    align-content: center;
    top: 100px;
    transition: all .2s ease; /* Smooth color transition */
    padding: 10px; /* Add space inside the SVG's container */
    max-width: 100%; /* Make sure the SVG doesn't overflow */
    left: -69px;
    transform: rotate(-90deg) translate(0, calc(-100% + 1.1rem));
    transform-origin: top;
}

/* Custom styles for pagination */
.custom-pagination {
    background-color: #ffffff;
    padding: 10px;
    border-radius: 5px;
}

.custom-pagination .page-link {
    background-color: white;
    color: #1E2C60;
    border: none;
    margin: 0 2px;
    cursor: pointer;
}

.custom-pagination .page-item.active .page-link {
    background-color: #1E2C60;
    color: #ffffff;
    font-weight: bold;
}

.custom-pagination .page-item.disabled .page-link {
    background-color: #ffffff;
    color: darkgrey;
    pointer-events: none;
    cursor: not-allowed;
}

/* Unified matrix-table styling to match jobs-table look */
.matrix-table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    font-family: Arial, sans-serif;
    font-size: 1rem;
    text-align: center;
    border: 1px solid #1E2C60 !important;
}

/* First header row � Group headings */
.matrix-table thead tr:first-child th {
    background-color: #1E2C60; /* Brand navy */
    color: white;
    font-weight: bold;
    border: 1px solid #1E2C60 !important;
    border-right: 3px solid #1E2C60 !important;
    font-size: 1rem;
}

/* Second header row � Scale levels */
.matrix-table thead tr:nth-child(2) th {
    background-color: #1e2c6049; /* Soft blue from Berenschot palette */
    color: #1E2C60;
    font-weight: bold;
    font-size: 0.95rem;
    border: 1px solid #1E2C60;
}

/* Override group-start for second header row group headers to prevent gaps */
.matrix-table thead tr:nth-child(2) th.group-start {
    border-left: 3px solid #1E2C60 !important;
    border-right: 1px solid #1E2C60;
    border-top: 1px solid #1E2C60;
    border-bottom: 1px solid #1E2C60;
}

/* Third header row � Scale levels */
.matrix-table thead tr:nth-child(3) th {
    background-color: #1e2c6023;
    color: #1E2C60;
    font-weight: bold;
    font-size: 0.95rem;
    border: 1px solid #1E2C60;
}

/* Table cell styling */
.matrix-table td,
.matrix-table th {
    padding: 0.25rem 0.5rem;
    border: 1px solid #1E2C60;
    text-align: center;
    vertical-align: middle;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Hover effect (same as jobs-table suggestion) */
.matrix-table tbody tr:hover {
    background-color: #A6E8FF;
    transition: 0.3s;
}

/* Link styling */
.matrix-table a {
    color: #002D62;
    text-decoration: none;
    font-weight: bold;
}

.matrix-table a:hover {
    text-decoration: underline;
}

/* Info icon */
.matrix-table .info-icon {
    margin-left: 5px;
    color: #ffffff;
    cursor: pointer;
}

/* Add icon styling */
.matrix-table .add-icon {
    color: #002D62;
    font-size: 1.2em;
    text-decoration: none;
}

.matrix-table tbody td.selected {
    background: #a9c3eaff;
}

/* Border between subcriterions (rows) */
.matrix-table tbody tr {
    border-top: 1px solid #1E2C60;
}

/* Thicker border between row groups */
.matrix-table tbody tr.row-group-start {
    border-top: 3px solid #1E2C60 !important;
}

/* Thicker border between column groups */
.matrix-table th.group-start,
.matrix-table td.group-start {
    border-left: 3px solid #1E2C60 !important;
}

/* Thicker border for the first column of each group in header rows */
.matrix-table thead tr th.group-start {
    border-left: 3px solid #1E2C60 !important;
}

td {
    padding: 5px;
}

.dt-layout-table {
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* General table styling */
.jobs-table {
    border-collapse: collapse;
    text-align: center;
    font-family: Arial, sans-serif;
    font-size: 1rem;
    cursor: default;
    width: 100%;
    white-space: nowrap; /* Prevents wrapping */
}

/* General table header styling */
.jobs-table thead th {
    border: 1px solid #000; /* Strong borders like a matrix */
    padding: 0.25rem 0.5rem; /* Compact padding like p-1 */
    text-align: center !important;
    vertical-align: middle;
    width: auto; /* Flexible width */
    color: white;
    background-color: #1E2C60 !important; /* Berenschot blue */
}

.jobs-table thead th.sortable span.dt-column-title {
    cursor: pointer; /* Pointer cursor for clickable headers (for sorting) */
}

.jobs-table thead th.sorted {
    background-color: #1e2c9c !important; /* Berenschot blue */
}

/* Generic column styling */
.jobs-table tbody td {
    border: 1px solid #000; /* Consistent borders */
    padding: 0.25rem 0.5rem; /* Compact padding */
    text-align: left;
    vertical-align: middle;
    width: auto; /* Flexible width */
    overflow: hidden;
    min-width: 40px !important;
}

.jobs-table tbody td.criterion {
    background-color: whitesmoke !important; /* Matches custom-bs-bgcolor, adjust if different */
}

.jobs-table tbody td.static {
    text-align: left !important;
}

.jobs-table tbody td.criterion {
    text-align: right !important;
}

.jobs-table tbody td.clickable span {
    color: #1A3877 !important;
    font-weight: bold;
    cursor: pointer;
}

/* General table styling */
.job-version-table {
    border-collapse: collapse;
    text-align: center;
    font-family: Arial, sans-serif;
    font-size: 1rem;
    cursor: default;
    width: 100%;
    white-space: nowrap; /* Prevents wrapping */
}

/* Generic column styling */
.job-version-table {
    table-layout: auto;
    width: auto;
}

/* General table header styling */
.job-version-table thead th {
    border: 1px solid #000; /* Strong borders like a matrix */
    padding: 0.25rem 0.5rem; /* Compact padding like p-1 */
    text-align: left !important;
    vertical-align: middle;
    width: auto; /* Flexible width */
    color: white;
    background-color: #1E2C60 !important; /* Berenschot blue */
    white-space: nowrap;
}

.job-version-table tbody td {
    border: 1px solid #000; /* Consistent borders */
    padding: 0.25rem 0.5rem; /* Compact padding */
    text-align: left;
    vertical-align: middle;
    width: auto; /* Flexible width */
    white-space: nowrap; /* Prevents wrapping */
    overflow: hidden;
    min-width: 40px !important;
}

.job-version-table .totals-row {
    font-weight: bold;
}

.job-version-table tbody tr td.sub-total-text {
    background-color: #A6E8FF !important;
}

.job-version-table tbody tr td.sub-total-score {
    background-color: #A6E8FF !important;
    text-align: right;
}

.job-version-table tbody tr td.total-text {
    color: white;
    background-color: #1E2C60 !important; /* Berenschot blue */
}

.job-version-table tbody tr td.total-score {
    color: white;
    background-color: #1E2C60 !important; /* Berenschot blue */;
    text-align: right !important;
}

.clickable-row {
    cursor: pointer;
}

.clickable-cell {
    cursor: pointer;
}

.clickable-row .score-input {
    cursor: default;
}

/* General table styling */
.question-table {
    border-collapse: collapse;
    text-align: center;
    font-family: Arial, sans-serif;
    font-size: 1rem;
    cursor: default;
    width: 100%;
    white-space: nowrap; /* Prevents wrapping */
}

/* General table header styling */
.question-table thead th {
    border: 1px solid #000; /* Strong borders like a matrix */
    padding: 0.25rem 0.5rem; /* Compact padding like p-1 */
    text-align: center !important;
    vertical-align: middle;
    width: auto; /* Flexible width */
    color: white;
    background-color: #1E2C60 !important; /* Berenschot blue */
}

/* Generic column styling */
.question-table tbody td {
    border: 1px solid #000; /* Consistent borders */
    padding: 0.25rem 0.5rem; /* Compact padding */
    text-align: left;
    vertical-align: middle;
    width: auto; /* Flexible width */
    overflow: hidden;
    min-width: 40px !important;
}

.question-table .header-row {
    font-weight: bold;
}

.question-table tbody tr td.header-row {
    background-color: #A6E8FF !important;
}

/* Language selector dropdown styling */
.dropdown-item-form {
    margin: 0;
    padding: 0;
}

.dropdown-item-form button {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 0.25rem 1rem;
    cursor: pointer;
}

.dropdown-item-form button:hover {
    background-color: #f8f9fa;
}

.dropdown-item-form button.active {
    background-color: #1E2C60;
    color: white;
}