/* CSS File with improvements and fixes of Materialize theme */

.material-icons {
    width: 2rem;
    font-size: 1.1rem;
    display: inline-block;
    text-align: center;
    margin-right: 1rem;
}

.sidenav {
    width: 200px;
}

.sidenav li {
    line-height: 30px;
}

.sidenav li>a {
    height: 30px;
    line-height: 31px;
    padding: 0 16px;
}

.sidenav li>a>i.material-icons {
    height: 30px;
    line-height: 30px;
    margin: 0 16px 0 0;
}

.sidenav.sidenav-fixed .collapsible-body>ul:not(.collapsible)>li.active i {
    color: #fff;
}

.sidenav-fixed li {
    min-height: 30px;
}

.sidenav-fixed .collapsible-body li a {
    padding-left: 16px;
}

@media only screen and (min-width:993px) {
    nav .nav-wrapper a.sidenav-trigger {
        display: none
    }
}

@media only screen and (min-width: 993px) {
    main, footer {
        margin-left: 200px;
    }
}

/* Remove headers from nested forms */

@media only screen and (min-width:993px) {
    .formset-field table {
        margin-bottom: 1rem;
    }
    .formset-field table tr th {
        padding: 5px;
    }
    /* Hide label for each table cell on large screens */
    .formset-field table tr label {
        display: none;
    }
    .formset-field table tr td .errors {
        padding-top: 0.5rem;
    }
    .formset-field table tr input:not(.browser-default) {
        margin-bottom: 0;
    }
    /* Fixing height of select element in nested forms */
    .formset-field .select-field .select-wrapper input.select-dropdown {
        height: 2.7rem;
        min-height: 2.7rem;
        margin-top: 0;
        /*
        Hack to get the same height select and other types of fields.
        Select field wrapped with additional 
        */
        padding-bottom: 1px;
    }
}

/* Set min size for all inputs in forms */
.input-field input {
    min-width: 50px;
}

/* Remove headers from nested forms */
@media only screen and (min-width:993px) {
    .formset-field table {
        margin-bottom: 1rem;
    }
    .formset-field table tr th {
        padding: 5px;
    }
    /* Hide label for each table cell on large screens */
    .formset-field table tr label {
        display: none;
    }
    .formset-field table tr td .errors {
        padding-top: 0.5rem;
    }
    .formset-field table tr input:not(.browser-default) {
        margin-bottom: 0;
    }
    /* Fixing height of select element in nested forms */
    .formset-field .select-field .select-wrapper input.select-dropdown {
        height: 2.7rem;
        min-height: 2.7rem;
        margin-top: 0;
        /*
        Hack to get the same height select and other types of fields.
        Select field wrapped with additional 
        */
        padding-bottom: 1px;
    }
}

/* Hide common header on mobile view */
@media only screen and (max-width:992px) {
    .formset-field table .table-header {
        display: none;
    }
}

/* Autocomplete */
.autocomplete-suggestions .autocomplete-no-suggestion {
    cursor: text;
    color: #bbbbbb;
}

.autocomplete-suggestions .autocomplete-create-new {
    clear: both;
    color: #26a69a;
    color: rgba(0, 0, 0, .87);
    cursor: pointer;
    display: block;
    font-size: 16px;
    line-height: 1.5rem;
    line-height: 16px;
    min-height: 50px;
    padding: 14px 16px;
    text-align: left;
    text-transform: none;
    width: 100%;
    border-top: 1px solid rgba(0, 0, 0, .14);
}

.autocomplete-suggestions .autocomplete-create-new:hover {
    background-color: #eee;
}

/* Hide header in empty tables */
.table-header:only-child {
    display: none;
}

/* Modal close button */
.modal-close {
    position: absolute;
    top: 24px;
    right: 24px;
    width: auto;
    height: auto;
}

/* Buttons */
.btn-outline {
    border: 1px solid #37474f;
    background-color: transparent;
    color: #37474f;
}

.btn-outline:hover {
    color: #ffffff;
}

/* Workorderlines total field */
#id_amount_container {
    display: flex;
    flex-direction: row-reverse;
    justify-content: end;
    align-items: center;
}

#id_amount_container input {
    width: 1px;    
    display: inline-block;
    font-size: 1.25rem;
    color: black;
    padding: 0 5px;
}

#id_amount_container label {
    position: relative;
    transform: none;
    font-size: 1.25rem;    
    margin-bottom: 15px;
    padding-right: 1.5rem;
    color: black;
}

/* Fix header height and logo position after removing breadcrumbs */
nav .nav-wrapper {
    display: flex;
}

nav.topbar .brand-logo {
    position: relative;
    transform: none;
    top: 0;
    left: 0;
    /* Hide long titles */
    overflow-x: hidden;
}

#nav-mobile.right {
    margin-left: auto;
}

nav.topbar {
    height: 58px;
}

/* Fix mobile version of fullwidth form */
.content {
    width: 100%;
}

.left-panel {
    margin-left: .375rem;
    max-width: calc(100% - 0.75rem);
}

/* Hide control elements for disabled forms */
.form-disabled .input-field-action,
.form-disabled button[data-formset-add=""] {
    display: none;
}

/* Formset total info */
.formset-total {
    display: flex;
    justify-content: end;
    justify-content: flex-end;
    align-items: center;
    font-size: 1.25rem;
}

.formset-total input[class$="-total"] {
    width: 50px;
    font-size: 1.25rem;
    color: #000000 !important;
    padding: 0 5px;
    margin-bottom: 0;
}

/* Margins and paggings (bootstrap-4 like) */
.mr-2 {
    margin-right: 2rem;
}

/* Buttons */
.btn-outline {
    border: 1px solid #37474f;
    background-color: transparent;
    color: #37474f;
}

.btn-outline:hover {
    color: #ffffff;
}

/* Errors */
.errorlist {
    color: red;
}

.formset-field .errorlist {
    margin-top: 0;
}

/* table.table-with-small-padding td,
table.table-with-small-padding th {
    padding: 0;
} */

.width-100 {
    width: 100%;
}

/* Login form styles*/
/* Make sidebar background to be white */
.registration .sidebar {
    opacity: 1;
}

.registration {
    background: linear-gradient( rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5) ),
url(/static/material/imgs/background.jpg);
    background-size: contain;
    background-repeat: no-repeat;
    position: fixed;
    background-attachment: scroll;
    background-position: 50% 43%;
}

/* Styles for inline WOL tables */
@media only screen and (min-width: 992px) and (max-width: 1440px) {
    .formset-field[data-formset-prefix="formset-quotation"] table input:not([type]), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="date"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="datetime-local"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="datetime"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="email"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="number"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="password"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="search"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="tel"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="text"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="time"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-quotation"] table input[type="url"]:not(.browser-default),
    .formset-field[data-formset-prefix="formset-realization"] table input:not([type]), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="date"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="datetime-local"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="datetime"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="email"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="number"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="password"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="search"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="tel"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="text"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="time"]:not(.browser-default), 
    .formset-field[data-formset-prefix="formset-realization"] table input[type="url"]:not(.browser-default),
    .formset-field[data-formset-prefix="formset-quotation"] table textarea.materialize-textarea,
    .formset-field[data-formset-prefix="formset-realization"] table textarea.materialize-textarea {
        font-size: 10px;
        height: 2rem;
        min-height: 2rem;
    }

    .formset-field[data-formset-prefix="formset-quotation"] table textarea.materialize-textarea,
    .formset-field[data-formset-prefix="formset-realization"] table textarea.materialize-textarea {
        /* padding: 0; */
        margin: 0;
    }
}


@media only screen and (min-width: 1441px) {
    input:not([type]),
    input[type="date"]:not(.browser-default), 
    input[type="datetime-local"]:not(.browser-default), 
    input[type="datetime"]:not(.browser-default), 
    input[type="email"]:not(.browser-default), 
    input[type="number"]:not(.browser-default), 
    input[type="password"]:not(.browser-default), 
    input[type="search"]:not(.browser-default), 
    input[type="tel"]:not(.browser-default), 
    input[type="text"]:not(.browser-default), 
    input[type="time"]:not(.browser-default), 
    input[type="url"]:not(.browser-default),
    textarea.materialize-textarea {
        font-size: 1rem;
        height: 2.7rem;
        min-height: 2.7rem;
        padding-top: 0.5rem;
    }

    .select-wrapper input.select-dropdown, .dropdown-content li > a, .dropdown-content li > span {
        font-size: 0.9rem;
    }

    textarea.materialize-textarea {
        margin-top: 8px;
    }

    .input-field > label, label {
        font-size: 0.9rem;
        line-height: 0.9rem;
    }

}

table.table .help-block {
    top: 5px;
}