﻿
/*ERP Sales person Customers List pages Responsive*/

.salescustomers-list-page .page-title {
    border-bottom: none;
}

    .salescustomers-list-page .page-title h1 {
        margin: 0 0 30px;
        border-bottom: 1px solid #ddd;
        padding: 0 0 10px;
    }

    .salescustomers-list-page .page-title a {
        display: inline-block;
        min-width: 180px;
        margin: 5px 0;
        border: none;
        background-color: #aaa;
        background-image: none;
        padding: 10px 20px;
        font-size: 15px;
        color: #fff;
    }

        .salescustomers-list-page .page-title a:hover {
            background-color: #999;
        }

/* Vendor PO & PQ Negotiations */
.po-accepted, .pq-accepted {
    background-color: #90ee9085 !important;
}

.po-rejected, .pq-rejected {
    background-color: #ff000061 !important;
}

.po-v-accepted, .pq-v-accepted {
    background-color: #8fe8f1e0 !important;
}

.po-n-review, .pq-n-review {
    background-color: #f1f18fe0 !important;
}

.po-blank, .pq-blank {
    border: 1px solid #c9c9c9 !important;
    background: #fff !important;
}


.accept_block span.green {
    width: 20px;
    height: 20px;
    background: green;
    display: inline-block;
    float: left;
    border-radius: 4px;
}

.po_accept_block span.green, .pq_accept_block span.green {
    width: 20px;
    height: 20px;
    background: green;
    display: inline-block;
    float: left;
    border-radius: 4px;
}

.rejected_block span.green {
    width: 20px;
    height: 20px;
    background: #ff9e9e;
    display: inline-block;
    float: left;
    border-radius: 4px;
}

.underreview_block span.green {
    width: 20px;
    height: 20px;
    background: #f3f39d;
    display: inline-block;
    float: left;
    border-radius: 4px;
}


span.accept_text {
    color: #000;
    display: inline-block;
    float: left;
    font-size: 14px;
    padding: 3px 10px;
    font-weight: 400;
}

label.po-invoiceno, label.pq-invoiceno {
    color: #000;
    font-size: 14px;
    padding: 3px 10px;
    font-weight: 400;
}

.table_box_colors {
    min-width: 100%;
    display: inline-block;
    margin: 10px 0px;
}

.view_btn:hover {
    background-color: #6da8b5;
    color: #fff !important;
}

a.view_btn {
    background-color: #f0f0f0;
    padding: 10px 20px;
    color: #333;
}


/*ERP Sales Purchase orders Qutes Invoices List pages Responsive*/

.erptablelist th {
    border-width: 1px 1px 0;
    border-style: solid;
    border-color: #ddd;
    background-color: #f6f6f6;
    padding: 10px;
    white-space: nowrap;
    font-weight: normal;
}

.erptablelist td {
    min-width: 50px;
    border-width: 1px;
    border-style: solid;
    border-color: transparent #ddd #ddd;
    background-color: #fff;
    padding: 20px;
    color: #444;
}

.erptablelist a:hover {
    text-decoration: underline;
}


.erptablelist .ordernumber {
    text-align: center;
}

.erptablelist .leftstringfield {
    text-align: left;
}

.erptablelist .leftstringfield {
    text-align: left;
}



    .erptablelist .leftstringfield a {
        font-weight: normal;
        color: #4ab2f1;
    }


.erptablelist label {
    display: none;
}



.erpcomment-info {
    display: block;
    text-align: left;
    font-size: 14px;
    font-weight: bold;
    color: #444;
    padding: 5px 0px;
}

    .erpcomment-info textarea {
        display: block;
        min-width: 100%;
    }

.order-details-page .erpcomment-info h4 {
    float: left;
    margin-top: inherit;
}

.attachents-title {
    margin: 10px;
    text-align: right;
}

    .attachents-title label {
        float: left;
        margin-top: inherit;
    }

.supplier-upload-file {
    min-height: 150px;
}

.comments-list, .attachment-list {
    overflow-y: auto;
    min-height: 150px;
    max-height: 200px;
}

.order-details-button {
    background-color: #e6e6e6;
    padding: 10px;
    font-size: 14px;
    border-radius: 4px;
}

    .order-details-button:hover {
        /*background: #6da8b5;*/
        color: #fff;
    }

.browseWrap .custom-file-input:before {
    content: 'Select some files';
    display: inline-block;
    background: #32a8b5;
    border: 0px solid #999;
    border-radius: 6px;
    outline: none;
    white-space: nowrap;
    -webkit-user-select: none;
    cursor: pointer;
    /* text-shadow: 1px 1px #fff; */
    color: #fff;
    padding: 15px 35px;
    font: normal 15px 'Fjalla One', sans-serif !important;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
    margin-right: -96px;
}

.browseWrap .custom-file-input {
    background: #ebe7e7;
    border-radius: 6px;
    padding: 4px;
    color: #7c7c7c;
    width: 100%;
    font-size: 15px;
    font-family: 'Lato', sans-serif;
    height: 58px;
}



@media all and (max-width: 1000px) {

    .erptablelist label {
        display: inline;
    }

    .erptablelist {
        display: block;
    }

        .erptablelist thead {
            display: none;
        }

        .erptablelist tbody {
            display: block;
            overflow: hidden;
        }

        .erptablelist td.ordernumber {
            margin: 0 0 15px;
            border-bottom: 1px solid #ddd;
            background-color: #eee;
            padding: 10px;
        }

        .erptablelist td.leftstringfield {
            margin: 0 0 15px;
            border-bottom: 1px solid #ddd;
            background-color: #eee;
            padding: 10px;
        }



        .erptablelist tbody {
            display: block;
            overflow: hidden;
        }

        .erptablelist tr {
            display: block;
            float: left;
            width: 100%;
            margin: 40px 0 0;
            border: 1px solid #ddd;
        }

        .erptablelist td {
            display: block;
            border: none;
            padding: 10px;
        }

            .erptablelist td.ordernumber {
                margin: 0 0 15px;
                border-bottom: 1px solid #ddd;
                background-color: #eee;
                padding: 10px;
            }


            .erptablelist td.leftstringfield {
                margin: 0 0 15px;
                border-bottom: 1px solid #ddd;
                background-color: #fff;
                padding: 10px;
            }


            .erptablelist td.createdon {
                border-top: 1px solid #ddd;
                padding: 15px 10px 5px;
            }

            .erptablelist td.ordertotal {
                border-top: 1px solid #ddd;
                padding: 15px 10px 5px;
            }
}

.erptablelist tr {
    width: 46%;
    margin: 40px 2% 0;
}

    .erptablelist tr:nth-child(2n+1) {
        clear: both;
    }

.erptablelist tr {
    width: 31.33333%;
    margin: 40px 1% 0;
}

    .erptablelist tr:nth-child(2n+1) {
        clear: none;
    }

.erptablelist tr {
    width: auto;
    margin: 0;
}

.erptablelist .ordernumber {
    text-align: center;
}

.erptablelist .leftstringfield {
    text-align: center;
}

.erptablelist td.ordernumber {
    margin: 0 0 15px;
    border-bottom: 1px solid #ddd;
    padding: 10px;
}

.erptablelist td.leftstringfield {
    margin: 0 0 15px;
    border-bottom: 1px solid #ddd;
    padding: 10px;
}



.erptablelist .unit-price,
.erptablelist .sku,
.erptablelist .quantity {
    white-space: nowrap;
    color: #909090;
}

.erptablelist .qty-input {
    width: 50px;
    text-align: center;
}



.buttonsdisplay {
    margin: 0 0 30px;
}

.subbutton {
    cursor: pointer;
    border: none;
    padding: 0 0 0 18px;
}

.buttonimage {
    background: url(/Themes/DefaultClean/Content/images/details.png) left center no-repeat;
}

.erptablelistq .td-title {
    display: none;
}

@media (max-width: 1000px) {
    .erptablelist tr {
        float: left;
        width: 100%;
        margin: 40px 0 0;
        border: 1px solid #ddd;
    }
}

@media (min-width: 481px) {
    .erptablelist tr:nth-child(2n+1) {
        clear: both;
    }
}

@media (min-width: 481px) {
    .erptablelist tr {
        width: 46%;
        margin: 40px 2% 0;
    }
}


/*Orders list search criteria*/

#dateerror, #dateerrors, #error {
    color: red;
}


@media screen and (min-width: 47.5em ) {
    .leftColumn {
        margin-right: 19.5em;
    }

    .rightColumn {
        position: absolute;
        top: 0;
        right: 0;
        width: 18.75em;
    }
}

.columnsContainer {
    position: relative;
    margin: 1em;
}



/*input[type="button"], input[type="submit"], button, .button-1, .button-2 {
    border: none;
    color: #323232;
    background: #f0f0f0;
    padding: 10px 20px 10px 20px;
}*/

@media screen and (min-width: 47.5em ) {
    .leftColumn {
        margin-right: 19.5em;
    }

    .rightColumn {
        position: absolute;
        top: 0;
        right: 0;
        width: 18.75em;
    }
}

.columnsContainer {
    position: relative;
    margin: 1em;
}



@media (max-width: 1000px) {
    .marginleft {
        /*margin-left: 15%;
        margin-right: 15%;*/
    }
}


@media (max-width: 330px) {
    input[type="text"], select {
        width: 100%;
    }
}

/*Search container*/

.searchcontainer {
    margin-top: 20px;
    position: relative;
    background-color: #fff;
    padding: 0px 20px 20px 20px;
}

.rightColumnsearch {
    margin-right: 20%;
    display: inline;
    padding-top: 20px;
}

.leftColumnsearch {
    padding-top: 20px;
}

@media screen and (min-width: 47.5em ) {
    .leftColumnsearch {
        margin-left: 20%;
    }

    .rightColumnsearch {
        position: absolute;
        top: 0;
        right: 0;
        /*width: 18.75em; 760 19.5 312*/
    }
}

@media (max-width: 430px) {
    .leftColumnsearch {
        margin-left: 0px;
    }
}

@media (min-width: 769px) {
    .erptablelistq tr {
        width: 96% !important;
        margin: 40px 2% 0;
    }
}

@media (min-width: 481px) {
    .erptablelistq tr {
        width: 96% !important;
        margin: 40px 2% 0;
    }
}

/* ===========================================================================
   Account tab filter bar (Open Orders, Transactions, Reports, ...)
   ---------------------------------------------------------------------------
   Markup is:  .account_tabs_block > .account_fills > ul > li.form-group
               .account_tabs_block > div  (holds the Search button)
   The button lives in a SIBLING div of the filter list, so it always dropped
   onto its own line. Lay the block out as one flex row and sit the button on
   the baseline of the inputs.

   Sizing mirrors the .erp-filter-bar component in the EshopPay plugin's
   paymentstyles.css (~line 539), which already produces the Bill Pay layout -
   same gap, same flex basis, same min-width, so the two look identical.

   This file is pulled in by a raw <link> in the view body, so it bypasses the
   WebOptimizer bundle: modern selectors here cannot break the site-wide CSS.
   =========================================================================== */
.account_tabs_block {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
}

.account_tabs_block .account_fills {
    flex: 0 1 auto;
    max-width: 100%;
}

.account_tabs_block .account_fills ul {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 10px;
}

    /* the base theme gives each li min-width:18% + a left margin; let them size to
       content instead so the row can end early and leave room for the button */
    .account_tabs_block .account_fills ul li {
        flex: 1 1 19%;
        min-width: 180px;
        margin: 0;
    }

/* the Search button's wrapper. It carries an inline padding-bottom:20px which
   would lift the button off the inputs' baseline, hence the !important. */
.account_tabs_block > div:not(.account_fills) {
    flex: 0 0 auto;
    margin: 0 0 10px 10px;
    padding-bottom: 0 !important;
}

/* 5 or more filters: the row is full, so give the button its own line, centred.
   (text-align:center is already inline on the wrapper.) */
.account_tabs_block:has(.account_fills ul li:nth-child(5)) > div:not(.account_fills) {
    flex: 1 0 100%;
    margin-left: 0;
}

/* ---------------------------------------------------------------------------
   VARIANT B - the button lives INSIDE .account_fills, in a .search_block div,
   instead of in a sibling div. Only one view does this (EshopPay
   ERPOrder/CustomerTransactions.cshtml), and the sibling selector above never
   matched it, which is why its Search button stayed below the inputs.
   .search_block has no CSS anywhere else in the repo.
   Making .account_fills a flex row puts the <ul> and .search_block side by side.
   --------------------------------------------------------------------------- */
.account_tabs_block .account_fills {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
}

.account_tabs_block .account_fills > .search_block {
    flex: 0 0 auto;
    margin: 0 0 10px 10px;
}

/* .searchcontainer (SalesDistrict / SalesPerson / AccessibleAccount customers):
   filters in a 6-column grid with centred labels, Search button centred underneath,
   matching the Ideal store. */
/* keep the customer number (e.g. USMF-EC@000000237) on one line - it otherwise breaks at the hyphen */
.salescustomers-list-page #myTable_sdc th:first-child,
.salescustomers-list-page #myTable_sdc td:first-child {
    white-space: nowrap;
}

.searchcontainer .leftColumnsearch {
    width: 90%;
    margin: 0 auto;
}

.searchlist ul {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 15px;
}

    .searchlist ul li {
        margin: 20px 0;
    }

        .searchlist ul li label {
            display: block;
            padding: 2px 0;
            text-align: center;
        }

@media (min-width: 1024px) and (max-width: 1320px) {
    .searchlist ul {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 1024px) {
    .searchlist ul {
        grid-template-columns: repeat(3, 1fr);
    }

        .searchlist ul li {
            margin: 0;
        }

            .searchlist ul li input[type="text"] {
                min-width: 90%;
            }
}

@media (max-width: 768px) {
    .searchlist ul {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 567px) {
    .searchlist ul {
        grid-template-columns: 1fr;
    }
}

/* narrow screens: filters stack, so the button always goes underneath */
@media (max-width: 1024px) {
    .account_tabs_block > div:not(.account_fills),
    .account_tabs_block .account_fills > .search_block {
        flex: 1 0 100%;
        margin-left: 0;
        text-align: center;
    }
}
