/*
I wanted to go with a mobile first approach, but it actually lead to more verbose CSS in this case, so I've gone web first. Can't always force things...

Side note: I know that this style of nesting in SASS doesn't result in the most performance efficient CSS code... but on the OCD/organizational side, I like it. So for CodePen purposes, CSS selector performance be damned.
*/
/* Global settings */
/* Global "table" column settings */
.row {
    margin: 0 !important;
}

.product_s {
    padding-top: 10px;
    background-color: #f9f9f9;
}

.product-image {
    float: left;
    width: 20%;
}

.product-details {
    float: left;
    width: 40%;
}

.product-empty {
    float: left;
    width: 4%;
}

.product-price {
    float: left;
    width: 9%;
    /*margin-left: 20px;*/ /*This move the price to the left but show a cut on the line*/
}

.product-quantity {
    float: left;
    width: 18%;
    min-width: fit-content;
}

.product-removal {
    float: left;
    width: 9%;
}

.product-line-price {
    float: left;
    width: 9%;
    text-align: right;
}

/* This is used as the traditional .clearfix class */
.group:before, .shopping-cart:before, .column-labels:before, .product:before, .totals-item:before,
.group:after,
.shopping-cart:after,
.column-labels:after,
.product:after,
.totals-item:after {
    content: '';
    display: table;
}

.group:after, .shopping-cart:after, .column-labels:after, .product:after, .totals-item:after {
    clear: both;
}

.group, .shopping-cart, .column-labels, .product, .totals-item {
    zoom: 1;
}

    /* Apply clearfix in a few places */
    /* Apply dollar signs */
    .product .product-price:before, .product .product-line-price:before, .totals-value:before {
        content: '$';
    }

/* Body/Header stuff */
body {
    /*padding: 0px 30px 30px 20px;*/
    font-weight: 100;
    font-family: "Open Sans";
    color: #46485b;
}

h1 {
    font-weight: 100;
}

label {
    color: #aaa;
}

.shopping-cart {
    margin: 45px 0;
}

/* Column headers */
.column-labels label {
    padding-bottom: 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.column-labels .product-image, .column-labels .product-details, .column-labels .product-removal {
    text-indent: -9999px;
}

/* Product entries */
.product {
    margin: 15px 0;
    padding: 10px;
    border-bottom: 1px solid #eee;
}

    .product .product-image {
        text-align: center;
    }

        .product .product-image img {
            width: 100%;
        }

    .product .product-details .product-title {
        /*margin-right: 20px;*/
        /*font-family: "HelveticaNeue-Medium", "Helvetica Neue Medium";*/
        font-weight: bold;
        /*font-size:medium;*/
        font-size: 24px;
    }

    .product .product-details .product-description {
        /*    margin: 5px 20px 5px 0;*/
        line-height: 1.4em;
        font-size: 14px;
    }

    .product .product-quantity {
        display: flex;
        align-items: center;
        gap: 8px;
        /*margin: 0 10px;*/
    }

        .product .product-quantity .step-btn {
            cursor: pointer;
        }

        .product .product-quantity input {
            width: 40px;
        }

            .product .product-quantity input[type=number]::-webkit-inner-spin-button,
            .product .product-quantity input[type=number]::-webkit-outer-spin-button {
                display: none;
            }

    .product .remove-product {
        border: 0;
        padding: 4px 8px;
        background-color: #6046db;
        color: #fff;
        font-family: "Open Sans";
        font-size: 12px;
        border-radius: 3px;
        font-weight: bold;
    }

        .product .remove-product:hover {
            background-color: #1f63f6;
        }

/* Totals section */
.totals {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
}

    .totals .totals-item {
        float: right;
        clear: both;
        width: 100%;
        min-width: 350px;
        max-width: 400px;
        margin-bottom: 10px;
    }

        .totals .totals-item label {
            float: left;
            clear: both;
            text-align: right;
        }

        .totals .totals-item .totals-value {
            float: right;
            text-align: right;
        }

        .totals .totals-item .totals-coupon {
            float: right;
            text-align: right;
        }

    .totals .totals-item-total {
        font-family: "HelveticaNeue-Medium", "Helvetica Neue Medium";
    }

.checkout {
    float: right;
    border: 0;
    margin-top: 20px;
    padding: 6px 25px;
    background-color: #69e2b4;
    color: #0a1751;
    font-size: 18px;
    border-radius: 3px;
    font-weight: bold;
}

    .checkout:hover {
        background-color: #ececec;
    }

/* Make adjustments for tablet */
@media screen and (max-width: 1030px) {
    .shopping-cart {
        border-top: 1px solid #eee;
    }

    .column-labels {
        display: none;
    }

    .product-image {
        float: right;
        width: auto;
    }

        .product-image img {
            /*margin: 0 0 10px 10px;*/
        }

    .product-details {
        float: none;
        /*margin-bottom: 10px;*/
        width: auto;
    }

    .product-price {
        clear: both;
        width: 70px;
        font-size: 16px;
    }

    .product-removal {
        width: auto;
    }

    .product-line-price {
        float: right;
        width: 70px;
        font-size: 16px;
    }
}
/* Make more adjustments for phone */
@media screen and (max-width: 350px) {
    .product-removal {
        float: right;
    }

    .product-line-price {
        float: right;
        clear: left;
        width: auto;
        margin-top: 10px;
    }

    .product .product-line-price:before {
        content: 'Item Total: $';
    }

    .totals .totals-item label {
        width: 60%;
    }

    .totals .totals-item .totals-value {
        width: 40%;
    }
}



/*select dropdown styles*/
/*select {
  margin-top:40px;
  font-size: 32px;
  font-family: Cursive;
}*/

.redeem-coupon {
    border: 0;
    padding: 4px 8px;
    background-color: #1f63f6;
    color: #fff;
    font-family: "Open Sans";
    font-size: 14px;
    border-radius: 3px;
    font-weight: bold;
}

.select {
    font-size: 32px;
    font-family: Cursive;
    position: relative;
    display: inline-block;
    margin-left: 300px;
}

    .select select {
        outline: none;
        -webkit-appearance: none;
        display: block;
        padding: 1.2em 3em 1.3em 1.5em;
        margin: 0;
        transition: border-color 0.2s;
        border: 5px solid #EB5168;
        border-radius: 5px;
        background: #fff;
        color: #555;
        line-height: normal;
        font-family: inherit;
        font-size: inherit;
        line-height: inherit;
    }

    .select .arr {
        background: #fff;
        bottom: 5px;
        position: absolute;
        right: 5px;
        top: 5px;
        width: 50px;
        pointer-events: none;
    }

        .select .arr:before {
            content: '';
            position: absolute;
            top: 50%;
            right: 24px;
            margin-top: -5px;
            pointer-events: none;
            border-top: 10px solid #EB5168;
            border-left: 10px solid transparent;
            border-right: 10px solid transparent;
        }

        .select .arr:after {
            content: '';
            position: absolute;
            top: 50%;
            right: 28px;
            margin-top: -5px;
            pointer-events: none;
            border-top: 6px solid #fff;
            border-left: 6px solid transparent;
            border-right: 6px solid transparent;
        }

.inventory-count {
    font-size: 10px;
    color: red;
}

/*-------------------- payment page --------------------*/

#dialogPayment {
    width: 100%;
    max-width: 1200px;
    margin: auto;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

    #dialogPayment h3 {
        padding: 40px;
        margin: 0;
    }

.form-section {
    width: 100%;
    text-align: left;
}

.form-element {
    margin: 0;
    display: flex;
    width: 100%;
    padding: 15px 75px;
}

    .form-element label {
        margin-bottom: 5px;
        font-weight: bold;
        width: 175px;
    }

    .form-element input,
    .form-element textarea {
        padding: 8px;
        font-size: 14px;
        width: 100%;
    }

.onsite-contact .form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    padding: 0 75px;
}

    .onsite-contact .form-row .form-element {
        flex: 1 1 30%;
        padding: 15px 0;
    }

.onsite-contact .form-element label {
    width: 75px;
}

.onsite-contact .form-element {
    background-color: #ffffff00;
}

.onsite-contact {
    background-color: #f2f2f2;
}

.form-element:nth-child(even) {
    background-color: #f2f2f2;
}

#divReceipt {
    display: flex;
    justify-content: center;
    margin-bottom: 50px;
    width: 100%;
}

.receipt-container {
    max-width: 600px;
    width: 100%;
}

.form-actions {
    padding: 40px 0;
    text-align: center;
}

    .form-actions button {
        background-color: #008CBA;
        border: none;
        color: white;
        padding: 15px 32px;
        font-size: 16px;
        cursor: pointer;
    }

    .form-actions button {
        background-color: #008CBA;
        border: none;
        color: white;
        padding: 15px 32px;
        font-size: 16px;
        cursor: pointer;
    }

.hidden {
    visibility: hidden;
}

.splitter {
    background: #f2f2f2;
    height: 60px;
    margin: 0;
}

@media(max-width: 768px) {
    .form-element {
        flex-direction: column;
        padding: 10px 20px;
    }


    .onsite-contact .form-row {
        padding: 0 20px;
        gap: 10px;
    }

        .onsite-contact .form-row .form-element {
            flex: 1 1 100%;
            padding: 0;
        }
}
