/* Harvestime presentation layer for customer-facing plugin interfaces. */

:root {
    --ht-plugin-forest: #0c4437;
    --ht-plugin-deep: #07372d;
    --ht-plugin-green: #35b979;
    --ht-plugin-lime: #b7dc64;
    --ht-plugin-ink: #15372e;
    --ht-plugin-muted: #61756f;
    --ht-plugin-line: #dce7e1;
    --ht-plugin-wash: #f3f7f3;
}

/* Mini Ajax Cart: presentation only; all fragment and quantity controls stay intact. */
.majc-main-wrapper,
.majc-cart-popup {
    font-family: "Poppins", "Helvetica Neue", Arial, sans-serif !important;
}

.majc-layout-slidein .majc-cart-popup {
    width: min(430px, calc(100vw - 12px)) !important;
    max-width: 100% !important;
    color: var(--ht-plugin-ink) !important;
    background: #fff !important;
    box-shadow: -24px 0 70px rgba(7, 55, 45, 0.18) !important;
}

.majc-cart-popup .majc-header {
    padding: 24px !important;
    color: #fff !important;
    background: var(--ht-plugin-forest) !important;
}

.majc-cart-popup .majc-header h2,
.majc-cart-popup .majc-header .majc-sub-header,
.majc-cart-popup .majc-header .majc-sub-header span {
    color: #fff !important;
}

.majc-cart-popup .majc-header h2 {
    font-size: 23px !important;
    font-weight: 600 !important;
    letter-spacing: -0.03em;
}

.majc-cart-popup .majc-cart-close {
    width: 42px !important;
    height: 42px !important;
    border-radius: 50% !important;
    color: #fff !important;
    background: rgba(255, 255, 255, 0.13) !important;
    display: grid !important;
    place-items: center;
}

.majc-cart-popup .majc-cart-items-inner {
    padding: 17px 0 !important;
    border-color: var(--ht-plugin-line) !important;
}

.majc-cart-popup .majc-item-img img {
    border: 1px solid var(--ht-plugin-line);
    border-radius: 12px;
    background: var(--ht-plugin-wash);
}

.majc-cart-popup .majc-item-name {
    color: var(--ht-plugin-ink) !important;
    font-weight: 600 !important;
}

.majc-cart-popup .majc-cart-action-btn-wrap .majc-button {
    min-height: 46px !important;
    border: 1px solid var(--ht-plugin-forest) !important;
    border-radius: 12px !important;
    color: #fff !important;
    background: var(--ht-plugin-forest) !important;
    font-size: 12px !important;
    font-weight: 600 !important;
}

.majc-cart-popup .majc-cart-action-btn-wrap .majc-button:hover {
    border-color: var(--ht-plugin-deep) !important;
    background: var(--ht-plugin-deep) !important;
}

.majc-toggle-button .majc-cartbasket-toggle-btn {
    box-shadow: 0 14px 34px rgba(7, 55, 45, 0.2) !important;
}

/* B2BKing registration, quotes and bulk-order surfaces. */
#b2bking_request_custom_quote_button,
.b2bking_send_custom_quote_button,
.b2bking_bulkorder_form_container_newline_button,
.b2bking_bulkorder_form_container_bottom_add_button,
.b2bking_bulkorder_form_container_bottom_save_button {
    min-height: 46px !important;
    padding: 0 18px !important;
    border: 1px solid var(--ht-plugin-forest) !important;
    border-radius: 12px !important;
    color: #fff !important;
    background: var(--ht-plugin-forest) !important;
    box-shadow: none !important;
    font-family: "Poppins", "Helvetica Neue", Arial, sans-serif !important;
    font-size: 12px !important;
    font-weight: 600 !important;
}

.b2bking_bulkorder_form_container,
.b2bking_conversation_messages_container,
.b2bking_conversation_messaging_metabox {
    overflow: hidden;
    border: 1px solid var(--ht-plugin-line) !important;
    border-radius: 18px !important;
    background: #fff !important;
    box-shadow: 0 18px 44px rgba(20, 65, 53, 0.07) !important;
}

#b2bking_registration_roles_dropdown,
.b2bking_custom_registration_field,
#b2bking_request_custom_quote_name,
#b2bking_request_custom_quote_email,
#b2bking_request_custom_quote_textarea {
    width: 100% !important;
    min-height: 50px !important;
    padding: 0 15px !important;
    border: 1px solid var(--ht-plugin-line) !important;
    border-radius: 11px !important;
    color: var(--ht-plugin-ink) !important;
    background: #f9fbf9 !important;
    font-family: "Poppins", "Helvetica Neue", Arial, sans-serif !important;
}

#b2bking_request_custom_quote_textarea,
.b2bking_custom_registration_field_textarea {
    min-height: 126px !important;
    padding-top: 13px !important;
}

/* WPForms and Contact Form 7 keep their validation and submission behaviour. */
.wpforms-container,
.wpcf7 {
    color: var(--ht-plugin-ink);
    font-family: "Poppins", "Helvetica Neue", Arial, sans-serif !important;
}

.wpforms-container .wpforms-field-label,
.wpcf7 label {
    margin-bottom: 7px !important;
    color: var(--ht-plugin-ink) !important;
    font-size: 12px !important;
    font-weight: 600 !important;
}

.wpforms-container input:not([type="checkbox"]):not([type="radio"]),
.wpforms-container select,
.wpforms-container textarea,
.wpcf7 input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]),
.wpcf7 select,
.wpcf7 textarea {
    width: 100% !important;
    min-height: 50px !important;
    padding: 0 15px !important;
    border: 1px solid var(--ht-plugin-line) !important;
    border-radius: 11px !important;
    color: var(--ht-plugin-ink) !important;
    background: #f9fbf9 !important;
    box-shadow: none !important;
    font-family: inherit !important;
}

.wpforms-container textarea,
.wpcf7 textarea {
    min-height: 132px !important;
    padding-top: 13px !important;
}

.wpforms-container input:focus,
.wpforms-container select:focus,
.wpforms-container textarea:focus,
.wpcf7 input:focus,
.wpcf7 select:focus,
.wpcf7 textarea:focus {
    border-color: #69a889 !important;
    background: #fff !important;
    box-shadow: 0 0 0 4px rgba(53, 185, 121, 0.1) !important;
    outline: 0 !important;
}

.wpforms-container button[type="submit"],
.wpcf7 input[type="submit"] {
    min-height: 48px !important;
    padding: 0 22px !important;
    border: 1px solid var(--ht-plugin-forest) !important;
    border-radius: 12px !important;
    color: #fff !important;
    background: var(--ht-plugin-forest) !important;
    font-size: 12px !important;
    font-weight: 600 !important;
}

/* Ultimate Responsive Image Slider: stronger mobile controls and brand polish. */
.slider-pro {
    max-width: 100% !important;
    overflow: hidden;
    border-radius: 22px;
    background: var(--ht-plugin-wash);
}

.slider-pro .sp-slide img {
    border-radius: 18px;
}

.slider-pro .sp-arrow {
    width: 44px !important;
    height: 44px !important;
    margin-top: -22px !important;
    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 50%;
    background: rgba(12, 68, 55, 0.9) !important;
    box-shadow: 0 8px 24px rgba(7, 55, 45, 0.18);
}

.slider-pro .sp-arrow::before,
.slider-pro .sp-arrow::after {
    background-color: #fff !important;
}

.slider-pro .sp-button {
    width: 9px !important;
    height: 9px !important;
    border-color: var(--ht-plugin-forest) !important;
}

.slider-pro .sp-selected-button {
    background-color: var(--ht-plugin-forest) !important;
}

/* Nest Addons live search: prevent wide result content and nested scrollbars. */
.box-header-search {
    position: relative;
}

.box-header-search .searchresultsget {
    width: 100% !important;
    max-width: 100% !important;
    max-height: min(460px, calc(100vh - 150px));
    padding: 10px 14px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    border: 1px solid var(--ht-plugin-line) !important;
    border-radius: 0 0 16px 16px;
    background: #fff !important;
    box-shadow: 0 18px 42px rgba(7, 55, 45, 0.14);
}

.box-header-search .searchresultsget ul {
    width: 100% !important;
    height: auto !important;
    min-width: 0 !important;
}

.box-header-search .searchresultsget li {
    min-width: 0 !important;
    padding: 10px 0 !important;
    border-color: var(--ht-plugin-line) !important;
}

.box-header-search .searchresultsget li a {
    width: 100% !important;
    min-width: 0 !important;
    display: grid !important;
    grid-template-columns: 54px minmax(0, 1fr);
    gap: 12px;
}

.box-header-search .searchresultsget li a > * {
    min-width: 0 !important;
    display: block !important;
}

.box-header-search .searchresultsget .product-image {
    width: 54px !important;
    max-width: 54px !important;
}

.box-header-search .searchresultsget .product-image img {
    width: 54px !important;
    height: 54px !important;
    border-radius: 10px;
    object-fit: contain;
    background: var(--ht-plugin-wash);
}

.box-header-search .searchresultsget .product-data {
    padding: 0 !important;
    overflow-wrap: anywhere;
}

.box-header-search .searchresultsget .product-data h3 {
    margin: 0 0 3px !important;
    color: var(--ht-plugin-ink) !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 1.4 !important;
}

.box-header-search .searchresultsget .product-data .product-price,
.box-header-search .searchresultsget .product-data .product-stock {
    position: static !important;
    display: inline-flex !important;
    margin: 5px 5px 0 0;
}

.box-header-search .searchresultsget .product-data .product-sku,
.box-header-search .searchresultsget .product-categories,
.box-header-search .searchresultsget .product-categories span {
    color: var(--ht-plugin-muted) !important;
    font-size: 10px !important;
    line-height: 1.5 !important;
}

/* The Nest single-product template prints an empty wrapper when no tabs or upsells exist. */
.single-product .product-info:not(:has(.woocommerce-tabs, .up-sells, .upsells)) {
    display: none !important;
}

@media (max-width: 767px) {
    .majc-layout-slidein .majc-cart-popup {
        width: calc(100vw - 8px) !important;
    }

    .majc-cart-popup .majc-header {
        padding: 19px !important;
    }

    .b2bking_bulkorder_form_container {
        max-width: 100%;
        overflow-x: auto;
    }

    .slider-pro {
        border-radius: 16px;
    }

    .slider-pro .sp-arrow {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        width: 40px !important;
        height: 40px !important;
        margin-top: -20px !important;
    }

    .box-header-search .searchresultsget {
        max-height: min(390px, calc(100vh - 130px));
        padding: 8px 12px !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .majc-cart-popup *,
    .slider-pro * {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}
