/**
 * PIT Solutions
 *
 * NOTICE OF LICENSE
 *
 * This source file is licensed under Webshop Extensions software license.
 * Once you have purchased the software with PIT Solutions AG or one of its
 * authorised resellers and provided that you comply with the conditions of this contract,
 * PIT Solutions AG grants you a non-exclusive license, unlimited in time for the usage of
 * the software in the manner of and for the purposes specified in the documentation according
 * to the subsequent regulations.
 *
 *
 * DISCLAIMER
 *
 * Do not edit or add to this file if you wish to upgrade this extension to newer versions in the future.
 *
 * @category Pits
 * @package Pits_GiftWrap
 * @author PIT Solutions Pvt. Ltd.
 * @copyright Copyright (c) 2024 PIT Solutions AG. (www.pitsolutions.ch)
 * @license https://www.webshopextension.com/en/licence-agreement/
 */

.gift-wrap {
    width: 100%;
    float: left;
    margin: 5px 0 0 0;
}

.field-giftwrap {
    margin: 0 0 4px 0;
    width: 100%;
    display: inline-block;
}

.field-giftwrap input[type="checkbox"] {
    margin: 0 3px 0 0;
    position: relative;
    top: 1px;
}

.field-giftwrap label {
    display: inline-block;
    padding: 0;
    margin: 0;
    line-height: 17px;
    font-size: 14px;
    color: #f93362;
    font-weight: 600;
}

.field-giftmsg {
    margin: 0 0 4px 0;
}

.field-giftmsg input[type="checkbox"] {
    margin: 0 3px 0 0;
    position: relative;
    top: 1px;
}

.field-giftmsg label {
    display: inline-block;
    padding: 0;
    margin: 0;
    line-height: 17px;
    font-size: 14px;
    color: #f93362;
    font-weight: 600;
}

.field-gifttxt {
    margin: 5px 0 0 0;
}

.field-gifttxt textarea {
    margin: 0;
    padding: 5px 5px;
    line-height: 16px;
    border: 1px solid #e0e0e0;
    min-height: 53px;
    font-size: 13px;
    background: #fff;
    display: block;
}

.giftwrap-applied {
    padding: 10px 10px;
    font-size: 12px;
    position: relative;
    border-radius: 4px;
    line-height: 16px;
    box-sizing: border-box;
    background: #eef5f5;
    display: inline-block;
    width: 100%;
    margin-top: 10px;
}

.applied-msg-gift {
    margin: 0 0 6px 0;
    width: 100%;
    display: inline-block;
    position: relative;
    padding-left: 30px;
}

.applied-msg-gift:before {
    content: "";
    background-image: url(../images/gift-wrap.png);
    width: 24px;
    height: 24px;
    float: left;
    position: absolute;
    left: 0;
}

.applied-msg-gift label {
    display: inline-block;
    padding: 0;
    margin: 0;
    font-size: 14px;
    color: #f93362;
    font-weight: 600;
    line-height: 27px;
    float: left;
}

.applied-gift-block {
    margin: 0 0 4px 0;
    width: 100%;
    display: inline-block;
    overflow: hidden;
}

.applied-gift-block .giftwrap-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.applied-gift-block div {
    font-size: 12px;
}

.applied-gift-block .giftwrap-remove {
    margin-top: 8px;
    font-weight: 600;
    color: #f93362;
    display: inline-block;
    padding-right: 10px;
    border-right: 1px solid #e0e0e0;
    cursor: pointer;
    margin-right: 10px;
}

.applied-gift-block .giftwrap-edit {
    margin-top: 8px;
    font-weight: 600;
    color: #f93362;
    display: inline-block;
    padding-left: 0px;
    cursor: pointer;
}

.gift-default-wrap {
    width: 100%;
    display: inline-block;
}

.gift-default-wrap.gift-right-block .giftwrap-applied {
    background-color: transparent !important;
    padding: 0 !important;
    margin-bottom: 7px !important;
}

.gift-default-wrap.gift-right-block .gift-wrap {
    margin-top: 10px;
}

.checkout-index-index .gift-wrap {
    float: none;
}

.giftwrap-order-block {
    border-bottom: 1px solid #ccc;
    padding: 20px 0;
}

.checkout-index-index .applied-msg-gift {
    display: block;
    box-sizing: border-box;
}

.checkout-index-index .applied-msg-gift:after {
    content: "";
    display: table;
    clear: both;
}

.checkout-index-index .giftwrap-applied {
    background: inherit;
    padding: 0;
    margin-top: 0;
    width: auto;
}

.giftwrap-applied-title {
    font-size: 14px;
    color: #f93362;
    font-weight: 600;
}

.gift-wrap-block {
    display: none;
}

.opc-summary-wrapper .gift-wrap-block {
    display: block;
}

@media only screen and (max-width: 767px) {
    .gift-wrap-block {
        display: block;
    }

    .gift-wrap-block .title::after {
        font-size: 12px;
        line-height: 12px;
        color: inherit;
        content: '\e622';
        font-family: 'luma-icons';
        margin: 5px 10px 0 0;
        vertical-align: middle;
        display: inline-block;
        font-weight: normal;
        overflow: hidden;
        float: right;
    }

    .gift-wrap-block.active .title::after {
        content: '\e621';
    }

    .block.items-in-cart.gift-wrap-block {
        border-bottom: 1px solid #ccc;
    }

    .opc-summary-wrapper .gift-wrap-block {
        display: none;
    }

    .gift-wrap-block .minicart-items-wrapper {
        border: none;
    }

}

.account.sales-order-view .table-order-items .giftwrap-applied dd {
    margin-left: 3px;
}

/****/
.checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .giftwrap-applied {
    box-sizing: border-box;
}

.checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-msg-gift {
    box-sizing: border-box;
}

.checkout-cart-index .cart.table-wrapper .product-item-details .gift-wrap {
    box-sizing: border-box;
}

.checkout-cart-index .cart.table-wrapper .product-item-details .gift-wrap .field-giftwrap {
    box-sizing: border-box;
}

.checkout-cart-index .cart-summary .gift-default-wrap .giftwrap-applied {
    box-sizing: border-box;
}

.checkout-cart-index .cart-summary .gift-default-wrap .applied-msg-gift {
    box-sizing: border-box;
}

/* gift wrap */
@media only screen and (min-width: 769px) {
    .checkout-cart-index .cart-container .cart.table-wrapper {
        overflow-x: auto;
    }

    .checkout-cart-index .cart-container .cart.table-wrapper tr.item-info .product-item-details {
        min-width: 310px;
    }

    .cart-summary .block > .title {
        padding-right: 20px;
    }
}

@media only screen and (min-width: 768px) and (max-width: 1024px) {
    html:lang(de) .checkout-cart-index .cart-summary .gift-default-wrap .applied-gift-block .giftwrap-remove {
        border-right: 0;
        padding-right: 0;
    }

    html:lang(de) .checkout-cart-index .cart-summary .gift-default-wrap .applied-gift-block .giftwrap-edit {
        padding-left: 0;
        display: block;
    }

    html:lang(fr) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-remove {
        border-right: 0;
        padding-right: 0;
    }

    html:lang(fr) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-edit {
        padding-left: 0;
        display: block;
    }

}

@media only screen and (min-width: 768px) and (max-width: 991px) {
    html:lang(de) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-remove {
        border-right: 0;
        padding-right: 0;
    }

    html:lang(de) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-edit {
        padding-left: 0;
        display: block;
    }

    .applied-msg-gift label {
        line-height: 19px;
    }
}

@media only screen and (min-width: 768px) and (max-width: 900px) {
    html:lang(en) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-remove {
        border-right: 0;
        padding-right: 0;
    }

    html:lang(en) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-edit {
        padding-left: 0;
        display: block;
    }

    html:lang(fr) .checkout-cart-index .cart-summary .gift-default-wrap .applied-gift-block .giftwrap-remove {
        border-right: 0;
        padding-right: 0;
    }

    html:lang(fr) .checkout-cart-index .cart-summary .gift-default-wrap .applied-gift-block .giftwrap-edit {
        padding-left: 0;
        display: block;
    }
}

@media only screen and (min-width: 768px) and (max-width: 800px) {
    html:lang(en) .checkout-cart-index .cart-summary .gift-default-wrap .applied-gift-block .giftwrap-remove {
        border-right: 0;
        padding-right: 0;
    }

    html:lang(en) .checkout-cart-index .cart-summary .gift-default-wrap .applied-gift-block .giftwrap-edit {
        padding-left: 0;
        display: block;
    }
}

@media only screen and (max-width: 420px) {
    html:lang(de) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-remove {
        border-right: 0;
        padding-right: 0;
    }

    html:lang(de) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-edit {
        padding-left: 0;
        display: block;
    }
}

@media only screen and (max-width: 320px) {
    html:lang(en) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-remove {
        border-right: 0;
        padding-right: 0;
    }

    html:lang(en) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-edit {
        padding-left: 0;
        display: block;
    }

    html:lang(fr) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-remove {
        border-right: 0;
        padding-right: 0;
    }

    html:lang(fr) .checkout-cart-index .cart.table-wrapper .product-item-details .gift-default-wrap .applied-gift-block .giftwrap-edit {
        padding-left: 0;
        display: block;
    }
}

/* Multi-shipping order overview */
.giftwrap-applied > dt {
    padding-left: 30px;
    position: relative;
    margin: 0 0 4px 0;
}

.giftwrap-applied > dd {
    margin: 0 0 4px 0;
}

.giftwrap-applied > dt > img {
    position: absolute;
    width: 24px;
    height: 24px;
    left: 0;
}

.giftwrap-applied > dt > .giftwrap-applied-title {
    line-height: 27px;
}

.giftwrap-actions {
    display: flex;
    flex-wrap: wrap;
}

.field-giftwrap, .field-giftmsg {
    display: flex;
    gap: 5px;
    align-items: flex-start;
}

.field-giftwrap input[type="checkbox"],
.field-giftmsg input[type="checkbox"] {
    top: 2px;
}

.field-giftmsg {
    padding-top: 3px;
}

.field-giftwrap input[type="checkbox"], .field-giftmsg input[type="checkbox"] {
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
}

.cart-summary .block .title strong {
    hyphens: auto;
    -webkit-hyphens: auto;
}

.field-gifttxt div.field-error {
    margin-top: 5px;
}

.field-gifttxt button.action.apply {
    margin-bottom: 4px;
    margin-top: 6px;
}
