@import url('https://fonts.googleapis.com/css2?family=Lato:wght@300;400&family=Neucha&display=swap');

:root {
    --paper-color: #f7f5ee;
    --paper-hover-color: #f1efe7;
    --paper-text-color: #2a2928;
}

/*
:root {
    --paper-color: whitesmoke;
    --paper-hover-color: #eaeaea;
    --paper-text-color: #333;
}
 */

/* ===========
   Page layout
   =========== */

@media (min-width: 1800px) {
    /* Prevent scrollbar shift */
    html {
        overflow-x: hidden;
        margin-right: calc(-1 * (100vw - 100%));
    }
}

.logo {
    height: 5rem;
}

@media (max-width: 768px) {
    .logo {
        height: 3rem;
    }
}

/* Typography: */

::selection {
    background-color: #bcd7cb !important;
    color: #333;
}

body {
    font-family: 'Lato', 'Segoe UI Light', sans-serif;
    font-weight: lighter;
    font-size: 18px;
    color: #373736;
}

@media (max-width: 1366px) {
    body {
        font-size: 16px;
    }
}

.btn, .qs-datepicker {
    font-family: 'Lato', sans-serif;
    font-weight: bolder;
}

a, .page-link {
    color: #5ab58a;
}

h1, h2 {
    font-family: 'Neucha', sans-serif;
}

h1 {
    font-weight: 600;
}

h2 {
    font-weight: bolder;
}

a:not(.btn):not(.dropdown-item):not(.nav-link):not(.danger):not(.needs-action):hover {
    color: #008546 !important;
}

/* Sticky footer: */

html {
    position: relative;
    min-height: 100%;
}

body {
    /* Margin bottom by footer height */
    margin-bottom: 100px;
}

.footer {
    position: absolute;
    bottom: 0;
    width: 100%;
    padding: 50px 10px 30px 10px;
    font-size: 21px;
}

@media (max-width: 800px) {

    body {
        /* Margin bottom by footer height */
        margin-bottom: 160px;
    }

    .footer {
        font-size: 20px;
    }

    .footer span {
        display: block;
    }

    .footer .separator {
        display: none;
    }
}

/* ===============
   Utility classes
   =============== */

.jumbo {
    width: 100%;
    max-height: 8em;
    margin-top: 0.5em;
    margin-bottom: 1.5em;
}

.transparent {
    opacity: 0;
}

.table-vertically-centered td {
    vertical-align: middle;
}

.link-unstyled {
    color: #212529;
}

.text-pre {
    white-space: pre-wrap !important;
}

.ellipsis {
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
}

.cursor-pointer {
    cursor: pointer;
}

/* ========================
   Bootstrap customizations
   ======================== */

small {
    font-weight: inherit;
}

.container-fluid {
    max-width: 2000px;
}

.alert a, .alert a:hover {
    text-decoration: underline;
    color: inherit;
}

.nav-pills .nav-link.active,
.nav-pills .show > .nav-link {
    color: #fff;
    background-color: #71bd99;
    border-color: #71bd99;
}

.dropdown-item.active,
.dropdown-item:active {
    color: var(--paper-text-color);
    text-decoration: none;
    background-color: var(--paper-color);
}

/* Cards: */

.card {
    border: 1px solid rgba(0, 0, 0, 0.09);
}

/*
.card {
    border: 1px solid var(--paper-hover-color);
}

.card-header,
.card-footer {
    background-color: var(--paper-color);
    color: var(--paper-text-color);
}
 */

/* Alerts: */

.alert-info {
    background-color: #d4eaeb;
    border: none;
}

/* Tooltips: */

*[data-toggle="tooltip"] {
    cursor: default;
}

.tooltip-inner {
    padding: 15px;
    text-align: left;
}

/* Badges: */

.badge {
    font-weight: normal;
    color: #333;
}

.badge-info {
    background-color: #70bebd;
}

.badge-warning {
    background-color: #fbc840;
}

.badge-success {
    background-color: #71bd99;
}

.badge-danger {
    font-weight: bold;
    color: #fff;
}

/* Cards: */

.card-header {
    border-bottom: none;
    font-weight: bold;
}

.card-body-table thead th {
    border: none;
}

/* Custom primary button: */

.btn-primary {
    box-sizing: border-box;
    color: #66ab8b;
    background-color: #edf5f0;
    border-width: 1px;
    border-color: #71bd99;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    color: #66ab8b !important;
    background-color: #e7f1ea !important;
    border-color: #66ab8b !important;
}

.btn-primary.focus,
.btn-primary:focus,
.form-control.focus,
.form-control:focus,
.btn-outline-primary:not(:disabled):not(.disabled):focus,
.btn-outline-primary:not(:disabled):not(.disabled):active:focus {
    box-shadow: 0 0 0 0.2rem rgba(28, 116, 48, 0.27);
}

/* Custom primary outline button: */

.btn-outline-primary {
    color: #66ab8b;
    border-color: #66ab8b;
    background-color: #fff;
}

.btn-outline-primary:not(:disabled):not(.disabled):hover,
.btn-outline-primary:not(:disabled):not(.disabled):focus,
.btn-outline-primary:not(:disabled):not(.disabled):active {
    color: #66ab8b;
    background-color: #e7f1ea;
    border-color: #66ab8b;
}

/* Light alerts: */

.alert-light {
    background-color: #eee;
    color: #333;
}

.alert-white {
    color: #818182;
    background-color: #fefefe;
    border-color: #fdfdfe;
}

/* Small buttons: */

.btn-xs {
    padding: 0 0.5rem;
    font-size: 0.875rem;
    line-height: 1.5;
    border-radius: 0.2rem;
}

/* Breadcrumb overrides: */

.breadcrumb {
    flex-wrap: nowrap;
    background-color: var(--paper-color);
    color: var(--paper-text-color);
    padding: 15px;
    /* Wobbly border effect: */
    border-top-left-radius: 255px 0px;
    border-top-right-radius: 10px 225px;
    border-bottom-right-radius: 225px 0px;
    border-bottom-left-radius: 10px 255px;
}

.breadcrumb a {
    color: var(--paper-text-color);
    text-decoration: underline;
}

.breadcrumb-item {
    max-width: 250px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.breadcrumb-item.active {
    color: var(--paper-text-color);
}

.breadcrumb-item+.breadcrumb-item::before {
    content: ">";
}

/* ==========
   Components
   ========= */

.card-body {
    overflow-x: auto;
}

/* Widgets: elements loaded asynchronously from the backend */

.card[data-widget] {
    display: none;
}

/* ------------------------
   Under development notice
   ------------------------ */

.under-development {
    position: absolute;
    top: 0;
    right: 0;
    background-color: #ffeb00;
    padding: 1px 3px;
    font-size: 0.5em;
    text-transform: uppercase;
    font-weight: bold;
}

/* ------
   Menus:
   ------ */

.home-nav ul {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

@media (max-width: 991px) {
    .home-nav ul {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .home-nav ul {
        grid-template-columns: repeat(2, 1fr);
        gap: 0;
    }
}

.home-nav ul li a {
    display: block;
    background-color: var(--paper-color);
    color: var(--paper-text-color);
    text-align: center;
    padding: 10%;
    position: relative;
    font-size: 1.1em;
    /* Wobbly border effect: */
    border-top-left-radius: 255px 0px;
    border-top-right-radius: 10px 225px;
    border-bottom-right-radius: 225px 0px;
    border-bottom-left-radius: 10px 255px;
    border: solid 7px #fff;
}

.home-nav ul li:nth-child(odd) a {
    /* Wobbly border effect variation: */
    border-top-left-radius: 255px 12px;
    border-top-right-radius: 0px 225px;
    border-bottom-right-radius: 205px 10px;
    border-bottom-left-radius: 0px 255px;
}

.home-nav ul li a:hover {
    background-color: var(--paper-hover-color);
}

.home-nav ul li a:hover img {
    transform: scale(1.05);
    transition: all linear 100ms;
}

.home-nav ul li a img {
    width: 100%;
    max-height: 5em;
    margin-top: 0.5em;
    margin-bottom: 1.5em;
}

.home-nav ul li a img.double {
    width: 30%;
}

/* -------
   Tables:
   ------- */

th {
    white-space: nowrap;
    width: 1%; /* Minimize */
    font-weight: lighter;
}

td .btn-outline-primary {
    margin-top: 2px;
}

/* Sort elements: */

.sort {
    display: inline-block;
    margin-left: 10px;
}

.sort-asc,
.sort-desc {
    font-size: 0.7em;
    padding: 3px;
}

.sort-asc:hover,
.sort-desc:hover {
    text-decoration: none;
}

/* Row option elements: */

.row-options {
    text-align: center;
}

@media (min-width: 1000px) {
    .row-options {
        max-width: 40%;
    }
}

td.row-options button,
td.row-options a {
    display: inline-block;
    margin: 0 0.5em;
    font-family: inherit;
    font-weight: inherit;
    padding: 0 0.3em;
    border: 1px solid #71bd99;
    background-color: #edf5f0;
    color: #71bd99;
    text-decoration: none;
    border-radius: 3px;
    font-size: 0.85em;
}

td.row-options a.needs-action {
    border: 1px solid #fbc840;
    background-color: #ffecba;
    color: #af811a;
}

td.row-options a.needs-action:hover {
    color: #af811a;
    border-color: #fbc840;
}

td.row-options a.danger {
    border: 1px solid #bd7171;
    background-color: #f5eded;
    color: #bd7171;
}

td.row-options a.danger:hover {
    color: #830303;
    border-color: #830303;
}

td.row-options form {
    display: inline;
}

td.row-options a:hover,
td.row-options button:hover {
    color: #008546;
    border-color: #008546;
}

/* Responsive scaling: */

.table-responsive {
    margin-bottom: 15px; /* Nearly always followed by pagination */
}

@media (max-width: 2000px) {
    table {
        font-size: 17px;
    }
}

.table-responsive td,
.table-responsive th {
    white-space: nowrap;
    vertical-align: middle;
}

.table-responsive td.user-notes {
    white-space: normal;
    font-size: 0.95em;
}

@media (min-width: 1800px) {
    .table-responsive td.user-notes {
        min-width: 300px;
    }
}

@media (max-width: 2000px) {

    .table-responsive {
        font-size: 0.9em;
    }

    .table-responsive td.user-notes {
        letter-spacing: -1px;
    }
}

@media (max-width: 1600px) {

    .table-responsive {
        letter-spacing: -1px;
    }

    .table-responsive td:not(.row-options) {
        white-space: normal;
    }
}

/* ------
   Forms:
   ------ */

textarea {
    min-height: 40px;
}

.input-group .btn-primary {
    border-width: 1px;
}

.required:after {
    content: '*';
    color: red;
}

/* Validation: */

.form-control.input-validation-error {
    border-color: darkred;
    z-index: 999;
}

.field-validation-error,
.validation-summary-errors {
    color: darkred;
    background-color: #f3d4d4;
    padding: 3px;
    display: block;
    border-radius: 3px;
    z-index: -999;
}

.validation-summary-errors {
    margin-bottom: 20px;
}

.validation-summary-errors ul {
    margin-bottom: 0;
}

/* ======================
   Third-party components
   ====================== */

/* Bootstrap select: */

.bootstrap-select > .dropdown-toggle.bs-placeholder,
.bootstrap-select > .dropdown-toggle.bs-placeholder:active,
.bootstrap-select > .dropdown-toggle.bs-placeholder:focus,
.bootstrap-select > .dropdown-toggle.bs-placeholder:hover,
.bootstrap-select > .dropdown-toggle,
.bootstrap-select > .dropdown-toggle:active,
.bootstrap-select > .dropdown-toggle:focus,
.bootstrap-select > .dropdown-toggle:hover {
    background-color: #fff;
    color: #495057;
    border: 1px solid #ced4da;
    font-weight: normal;
}

.bs-searchbox {
    margin-bottom: 9px;
}

/* Multiple select: */

.ms-drop {
    position: relative;
}

.ms-choice {
    display: none;
}

.ms-drop.bottom {
    box-shadow: none;
    border: 1px solid #ced4da;
}

/* React calendar: */

.react-calendar {
    width: auto !important;
    font-family: inherit !important;
    border: 1px solid #e0e0e0 !important;
}

.react-calendar__month-view__days__day--weekend {
    color: #757575 !important;
}

.react-calendar__tile--active {
    background-color: #5ab58a !important;
}

.react-calendar abbr {
    text-decoration: none;
}

/* Easepick: */

.easepick-wrapper .month-name {
    text-transform: capitalize;
}