/**
 * QuickBuy Frontend Styles
 * Style compatible with devvn-quick-buy
 * @package QuickBuy
 * @version 10.0.0
 */

/* ==========================================================================
   Reset & Box Sizing
   ========================================================================== */
.quickbuy-popup,
.quickbuy-popup * {
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
}

/* ==========================================================================
   Button Styles (devvn_buy_now_style compatible)
   ========================================================================== */
.quickbuy-wrapper {
    margin: 0 0 20px;
}

.quickbuy-btn {
    display: inline-block;
    overflow: hidden;
    clear: both;
    padding: 9px 0;
    border-radius: 4px;
    font-size: 18px;
    line-height: normal;
    text-transform: uppercase;
    color: #fff !important;
    text-align: center;
    background: #fd6e1d;
    background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#fd6e1d), to(#f59000));
    background: -webkit-linear-gradient(top, #f59000, #fd6e1d);
    background: -moz-linear-gradient(top, #f59000, #fd6e1d);
    background: -ms-linear-gradient(top, #f59000, #fd6e1d);
    background: -o-linear-gradient(top, #f59000, #fd6e1d);
    background: linear-gradient(to bottom, #f59000, #fd6e1d);
    text-decoration: none !important;
    border-bottom: 0 !important;
    max-width: 350px;
    width: 100%;
    cursor: pointer;
    border: none;
}

.quickbuy-btn:hover,
.quickbuy-btn:focus {
    text-decoration: none !important;
    background: #f59000;
    background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#f59000), to(#fd6e1d));
    background: -webkit-linear-gradient(top, #fd6e1d, #f59000);
    background: -moz-linear-gradient(top, #fd6e1d, #f59000);
    background: -ms-linear-gradient(top, #fd6e1d, #f59000);
    background: -o-linear-gradient(top, #fd6e1d, #f59000);
    background: linear-gradient(to bottom, #fd6e1d, #f59000);
    color: #fff !important;
}

.quickbuy-btn strong {
    display: block;
    font-size: 22px;
    font-weight: normal;
}

.quickbuy-btn span {
    display: block;
    font-size: 12px;
    color: #fff;
    text-transform: none;
    margin: 2px 0 0;
}

.quickbuy-btn-small {
    padding: 8px 15px;
    font-size: 14px;
    max-width: 200px;
}

.quickbuy-btn-small strong {
    font-size: 14px;
}

/* ==========================================================================
   Popup Styles (devvn-popup compatible)
   ========================================================================== */
.quickbuy-popup {
    width: 100%;
    height: 100%;
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.75);
    z-index: 9999999999;
    line-height: 20px;
    color: #333;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 14px;
    font-weight: 400;
}

.quickbuy-popup.active {
    display: block;
}

.quickbuy-popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.quickbuy-popup-inner {
    min-height: 200px;
    min-width: 300px;
    width: 750px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 1);
    border-radius: 4px 4px 0 0;
    -moz-border-radius: 4px 4px 0 0;
    -webkit-border-radius: 4px 4px 0 0;
    background: #fff;
    overflow: hidden;
    max-height: 90vh;
    overflow-y: auto;
}

.quickbuy-popup-header {
    background: #1e73be;
    background: -moz-linear-gradient(top, #1e73be 0%, #004e92 100%);
    background: -webkit-linear-gradient(top, #1e73be 0%, #004e92 100%);
    background: linear-gradient(to bottom, #1e73be 0%, #004e92 100%);
    color: #fff;
    height: 42px;
    line-height: 42px;
    padding-left: 20px;
    padding-right: 40px;
    font-size: 16px;
    text-transform: uppercase;
    position: relative;
}

.quickbuy-popup-title {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0;
    font-size: 16px;
    font-weight: normal;
    color: #fff;
}

.quickbuy-popup-close {
    width: 20px;
    height: 20px;
    display: inline-block;
    position: absolute;
    top: 10px;
    right: 10px;
    transition: ease .25s all;
    -moz-transition: ease .25s all;
    -webkit-transition: ease .25s all;
    text-align: center;
    line-height: 100%;
    color: #fff;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/></svg>') no-repeat center center;
    background-size: 100% auto;
    overflow: hidden;
    text-indent: -9999px;
    border: 0 solid transparent;
    outline: none;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    margin: auto;
    padding: 0;
    min-height: inherit;
    cursor: pointer;
}

.quickbuy-popup-close:hover {
    -webkit-transform: rotate(90deg);
    -moz-transform: rotate(90deg);
    transform: rotate(90deg);
    background-color: transparent;
}

.quickbuy-popup-close:focus {
    text-decoration: none;
    background-color: transparent;
}

.quickbuy-popup-content {
    padding: 10px;
}

/* ==========================================================================
   Form Wrapper
   ========================================================================== */
.quickbuy-form-wrapper {
    line-height: 1.3125;
}

.quickbuy-form-wrapper:after {
    content: "";
    display: table;
    clear: both;
}

/* Product Info */
.quickbuy-product-info {
    display: table;
    width: 100%;
    margin-bottom: 15px;
}

.quickbuy-product-info:after {
    content: "";
    display: table;
    clear: both;
}

.quickbuy-product-image {
    display: table-cell;
    width: 100px;
    height: auto;
    vertical-align: middle;
    margin: 0;
}

.quickbuy-product-image img {
    width: 100px;
    height: auto;
    border-radius: 4px;
}

.quickbuy-product-details {
    display: table-cell;
    vertical-align: middle;
    padding-left: 10px;
    overflow: hidden;
}

.quickbuy-product-title {
    font-size: 18px;
    color: #333;
    font-weight: 700;
    padding-bottom: 10px;
    margin: 0;
}

.quickbuy-product-price {
    font-size: 16px;
    color: red;
    font-weight: 700;
    padding-bottom: 5px;
    display: block;
}

.quickbuy-product-price del {
    font-size: 12px;
    color: #ccc;
    font-weight: 400;
}

.quickbuy-product-price ins {
    text-decoration: none;
}

/* Columns Layout */
.quickbuy-left-col {
    width: 50%;
    float: left;
    padding-right: 10px;
}

.quickbuy-right-col {
    width: 50%;
    float: right;
    padding-left: 10px;
}

/* Variations */
.quickbuy-variations {
    margin: 0 0 20px;
}

.quickbuy-variations .variations {
    margin: 0;
    border: 0;
}

.quickbuy-variations .variations td {
    padding: 0 0 10px;
    vertical-align: text-bottom;
    border: 0;
}

.quickbuy-variations .label {
    color: #333;
    font-size: 14px;
    padding-right: 10px !important;
}

.quickbuy-variations a.reset_variations {
    margin: 0 0 0 10px;
}

/* Quantity */
.quickbuy-quantity {
    padding-left: 84px;
    position: relative;
    margin: 0 0 15px;
}

.quickbuy-quantity .screen-reader-text {
    clip: inherit;
    height: inherit;
    position: absolute !important;
    width: inherit;
    white-space: nowrap;
    top: 6px;
    left: 0;
    font-size: 14px;
}

.quickbuy-qty-wrapper {
    display: flex;
    align-items: center;
}

.quickbuy-qty-btn {
    width: 32px;
    height: 32px;
    background: #f5f5f5;
    border: 1px solid #ccc;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s;
}

.quickbuy-qty-btn:hover {
    background: #e0e0e0;
}

.quickbuy-qty-minus {
    border-radius: 4px 0 0 4px;
}

.quickbuy-qty-plus {
    border-radius: 0 4px 4px 0;
}

.quickbuy-qty-input {
    width: 50px;
    height: 32px;
    text-align: center;
    border: 1px solid #ccc;
    border-left: none;
    border-right: none;
    font-size: 14px;
    -moz-appearance: textfield;
}

.quickbuy-qty-input::-webkit-outer-spin-button,
.quickbuy-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ==========================================================================
   Customer Form
   ========================================================================== */
.quickbuy-customer-form {
    margin-bottom: 0;
}

.quickbuy-form-title {
    font-size: 16px;
    color: #333;
    margin-bottom: 15px;
    font-weight: 700;
}

.quickbuy-form-row {
    width: 100%;
    margin-bottom: 6px;
}

.quickbuy-form-row:after {
    display: block;
    content: " ";
    clear: both;
}

.quickbuy-two-cols {
    display: flex;
    gap: 6px;
}

.quickbuy-two-cols .quickbuy-form-col {
    flex: 1;
}

.quickbuy-location-row {
    display: flex;
    gap: 6px;
}

.quickbuy-location-row .quickbuy-form-col {
    flex: 1;
}

/* Gender Row */
.quickbuy-gender-row {
    margin-bottom: 10px;
}

.quickbuy-radio {
    display: inline-block;
    font-weight: 400;
    position: relative;
    cursor: pointer;
    margin: 0;
}

.quickbuy-radio + .quickbuy-radio {
    margin-left: 20px;
}

.quickbuy-radio input {
    border: 0;
    clip: rect(0 0 0 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
}

.quickbuy-radio span {
    padding-left: 23px;
    position: relative;
}

.quickbuy-radio span:before,
.quickbuy-radio span:after {
    width: 16px;
    height: 16px;
    content: "";
    position: absolute;
    border: 1px solid #a6a6a6;
    border-radius: 50%;
    top: 1px;
    left: 0;
}

.quickbuy-radio input:checked ~ span:before {
    border: 1px solid #fd7518;
}

.quickbuy-radio input:checked ~ span:after {
    background: #fd7518;
    border: 1px solid #fd7518;
    width: 8px;
    height: 8px;
    top: 5px;
    left: 4px;
}

/* Input Styles */
body .quickbuy-form-row input,
body .quickbuy-form-row select,
body .quickbuy-form-row textarea,
.quickbuy-input,
.quickbuy-select,
.quickbuy-textarea {
    font-size: 12px;
    padding: 2px 5px;
    border: 1px solid #ccc;
    width: 100%;
    height: 26px;
    box-shadow: none;
    -moz-box-shadow: none;
    -webkit-box-shadow: none;
    margin: 0;
    font-family: Tahoma, Arial, sans-serif;
    background: #fff;
    border-radius: 0;
}

body .quickbuy-form-row input:focus,
body .quickbuy-form-row select:focus,
body .quickbuy-form-row textarea:focus {
    box-shadow: none;
    outline: none;
}

.quickbuy-input.error,
.quickbuy-select.error {
    border-color: red;
}

body .quickbuy-form-row textarea,
.quickbuy-textarea {
    height: 45px;
    min-height: inherit;
    resize: vertical;
}

/* Total Row */
.quickbuy-total-row {
    display: flex;
    margin: 10px 0;
}

.quickbuy-total-label {
    padding-right: 10px;
    font-size: 14px;
}

.quickbuy-total-value {
    font-weight: 700;
    color: red;
    font-size: 16px;
}

/* Submit Button */
.quickbuy-submit-row {
    margin-top: 10px;
}

.quickbuy-submit-btn {
    width: 100%;
    height: 36px;
    background: #1e73be;
    color: #fff;
    font-size: 16px;
    text-transform: uppercase;
    border: none;
    border-radius: 2px;
    cursor: pointer;
    outline: none;
    position: relative;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

.quickbuy-submit-btn:hover {
    background: #004e92;
}

.quickbuy-submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.quickbuy-submit-btn.loading {
    opacity: 1 !important;
    position: relative;
    color: rgba(255, 255, 255, 0.05);
    pointer-events: none !important;
}

.quickbuy-submit-btn.loading:after {
    -webkit-animation: quickbuy_spin 500ms infinite linear;
    animation: quickbuy_spin 500ms infinite linear;
    border: 2px solid #fff;
    border-radius: 32px;
    border-right-color: transparent !important;
    border-top-color: transparent !important;
    content: "";
    display: block;
    height: 16px;
    top: 50%;
    margin-top: -8px;
    left: 50%;
    margin-left: -8px;
    position: absolute;
    width: 16px;
}

.quickbuy-btn-text {
    display: inline;
}

.quickbuy-btn-loading {
    display: none;
}

/* Messages */
#quickbuy-messages {
    margin-top: 10px;
}

.quickbuy-messages .success {
    background-color: #fff;
    padding: 15px;
}

.quickbuy-messages .error {
    color: red;
    font-weight: 400;
    font-size: 12px;
}

/* Message */
.quickbuy-message {
    background: #fff3e0;
    border-left: 4px solid #ff9800;
    padding: 10px 15px;
    font-size: 13px;
    color: #e65100;
    margin-bottom: 15px;
}

/* Loading */
.quickbuy-loading {
    text-align: center;
    padding: 40px;
    color: #666;
    position: relative;
}

.quickbuy-loading:after {
    -webkit-animation: quickbuy_spin 500ms infinite linear;
    animation: quickbuy_spin 500ms infinite linear;
    border: 2px solid #c29a44;
    border-radius: 32px;
    border-right-color: transparent !important;
    border-top-color: transparent !important;
    content: "";
    display: block;
    height: 24px;
    margin: 0 auto 10px;
    width: 24px;
}

/* ==========================================================================
   Animations
   ========================================================================== */
@-webkit-keyframes quickbuy_spin {
    0% {
        -webkit-transform: rotate(0deg);
        transform: rotate(0deg);
    }
    100% {
        -webkit-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

@keyframes quickbuy_spin {
    0% {
        -webkit-transform: rotate(0deg);
        transform: rotate(0deg);
    }
    100% {
        -webkit-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

/* ==========================================================================
   Success Message
   ========================================================================== */
.qb-success {
    text-align: center;
    padding: 20px;
}

.qb-success h3 {
    color: #00c700;
    margin-bottom: 15px;
}

.qb-success p {
    margin: 10px 0;
    color: #333;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 750px) {
    .quickbuy-popup-inner {
        width: 500px;
    }

    .quickbuy-left-col,
    .quickbuy-right-col {
        width: 100%;
        padding-right: 0;
        padding-left: 0;
        float: none;
    }

    .quickbuy-left-col {
        margin-bottom: 20px;
    }
}

@media (max-width: 549px) {
    .quickbuy-btn {
        max-width: 100% !important;
    }
}

@media (max-width: 500px) {
    .quickbuy-popup-inner {
        width: 320px;
    }

    .quickbuy-two-cols,
    .quickbuy-location-row {
        flex-direction: column;
    }
}
