/**
 * Market Products - Frontend Styles
 */

/* ====================================
   PRODUCT DESCRIPTION
   ==================================== */

.mp-product-description {
    padding: 20px;
    background: #f9f9f9;
    border-left: 4px solid #e14602;
    border-radius: 4px;
    margin: 20px 0;
    line-height: 1.6;
}


/* ====================================
   PRODUCTS WRAPPER
   ==================================== */

.mp-products-wrapper {
    margin: 30px 0;
}

.mp-select-heading {
    text-align: center;
    margin-bottom: 30px;
}

.mp-select-heading h3 {
    font-size: 24px;
    margin: 0 0 10px 0;
    color: #333;
}

.mp-select-heading p {
    color: #666;
    margin: 0;
}

.mp-no-products {
    text-align: center;
    padding: 40px;
    background: #f9f9f9;
    border-radius: 8px;
    color: #666;
}


/* ====================================
   PRODUCTS GRID
   ==================================== */

.mp-products-grid {
    display: grid;
    gap: 10px;
    margin-bottom: 30px;
}

/* Column variants */
.mp-cols-1 .mp-products-grid { grid-template-columns: repeat(1, 1fr) !important; }
.mp-cols-2 .mp-products-grid { grid-template-columns: repeat(2, 1fr) !important; }
.mp-cols-3 .mp-products-grid { grid-template-columns: repeat(3, 1fr) !important; }
.mp-cols-4 .mp-products-grid { grid-template-columns: repeat(4, 1fr) !important; }
.mp-cols-5 .mp-products-grid { grid-template-columns: repeat(5, 1fr) !important; }
.mp-cols-6 .mp-products-grid { grid-template-columns: repeat(6, 1fr) !important; }


@media (max-width:280px){
	.mp-products-grid { grid-template-columns: 1fr !important; }
}
@media (max-width:767px){
	.mp-cols-4 .mp-products-grid,
    .mp-cols-5 .mp-products-grid,
    .mp-cols-6 .mp-products-grid { grid-template-columns: repeat(2, 1fr) !important; }
    .mp-cols-3 .mp-products-grid { grid-template-columns: repeat(2, 1fr) !important; }
	.homelist .mp-products-grid .mp-product-item:nth-child(n+7) {
		display: none;
	}
}
@media (max-width:1024px) and (min-width:768px) {
	.homelist .mp-cols-4 .mp-products-grid,
    .homelist .mp-cols-5 .mp-products-grid,
    .homelist .mp-cols-6 .mp-products-grid { grid-template-columns: repeat(3, 1fr) !important; }
    .homelist .mp-cols-3 .mp-products-grid { grid-template-columns: repeat(3, 1fr) !important; }
	
	.mp-cols-4 .mp-products-grid,
    .mp-cols-5 .mp-products-grid,
    .mp-cols-6 .mp-products-grid { grid-template-columns: repeat(4, 1fr) !important; }
    .mp-cols-3 .mp-products-grid { grid-template-columns: repeat(4, 1fr) !important; }
	
	.homelist .mp-products-grid .mp-product-item:nth-child(n+7) {
		display: none;
	}

}
@media (max-width:1280px) and (min-width:1024px) {
	.homelist .mp-cols-4 .mp-products-grid,
    .homelist .mp-cols-5 .mp-products-grid,
    .homelist .mp-cols-6 .mp-products-grid { grid-template-columns: repeat(3, 1fr) !important; }
    .homelist .mp-cols-3 .mp-products-grid { grid-template-columns: repeat(3, 1fr) !important; }
	
	.mp-cols-4 .mp-products-grid,
    .mp-cols-5 .mp-products-grid,
    .mp-cols-6 .mp-products-grid { grid-template-columns: repeat(4, 1fr) !important; }
    .mp-cols-3 .mp-products-grid { grid-template-columns: repeat(4, 1fr) !important; }
	
}
@media (min-width:1280px) and (max-width:1400px) {
	.mp-cols-6 .mp-products-grid { grid-template-columns: repeat(6, 1fr) !important; }
    .mp-cols-5 .mp-products-grid { grid-template-columns: repeat(5, 1fr) !important; }
}


/* ====================================
   PRODUCT CARD
   ==================================== */

.mp-product-item {
    opacity: 1;
    transform: scale(1);
    transition: all 0.3s ease;
}

.mp-product-item.hidden {
    display: none;
}

.mp-product-card {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.mp-product-card:hover {
    border-color: #e14502;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-4px);
}

.mp-product-image-wrap {
    position: relative;
    overflow: hidden;
    background: #f9f9f9;
    aspect-ratio: 1;
}

.mp-product-img {
    width: 100%;
    height: 100% !important;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.mp-product-card:hover .mp-product-img {
    transform: scale(1.05);
}

.mp-image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #eb47013d;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mp-product-card:hover .mp-image-overlay {
    opacity: 1;
}

.mp-view-details {
    background: white;
    color: #e14502;
    border: none;
    padding: 10px;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
}

.mp-view-details:hover {
    background: #e14602;
    color: white;
    transform: scale(1.05);
}

.mp-view-details .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}


/* ====================================
   PRODUCT INFO
   ==================================== */

.mp-product-info {
    padding: 12px;
    flex-grow: 1;
}

.mp-product-title {
    font-size: 16px;
    margin: 0 0 8px 0;
    color: #e04502;
    font-weight: 600;
    line-height: 1.4;
    /* min-height: 44px; */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 20px;
    margin: 0;
    text-align: center;
}

.mp-product-sku {
    font-size: 13px;
    color: #666;
    margin: 0 !important;
    font-family: monospace;
    text-align: center;
}


/* ====================================
   CHECKBOX
   ==================================== */

.mp-product-checkbox {
    padding: 7px 12px;
    border-top: 1px solid #f0f0f0;
}

.mp-checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    color: #333;
    transition: color 0.2s;
    line-height: 14px;
    justify-content: center;
}

.mp-checkbox-label:hover {
    color: #e04502;
}

.mp-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #e04502;
}

/* ====================================
   LOAD MORE SECTION
   ==================================== */

.mp-load-more-section {
    text-align: center;
    margin-top: 30px;
}

.mp-load-more-btn {
    background: #e04502;
    color: white;
    border: none;
    padding: 14px 40px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mp-load-more-btn:hover {
    background: #e14502;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 113, 177, 0.3);
}

.mp-load-more-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.mp-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: 600;
    color: #e64702;
}

.mp-loading .spinner {
    float: none;
    margin: 0;
}


/* ====================================
   MODAL
   ==================================== */

.mp-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99999;
    display: none;
}

.mp-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    animation: fadeIn 0.3s ease;
}

.mp-modal-content {
    position: relative;
    max-width: 900px;
    margin: 50px auto;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    animation: slideUp 0.3s ease;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mp-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    width: 40px !important;
    height: 40px !important;
    border-radius: 50%;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    z-index: 10;
    transition: all 0.2s;
    line-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.mp-modal-close:hover {
    background: rgba(0,0,0,0.9);
    transform: rotate(90deg);
}

.mp-modal-body {
    padding: 30px;
}

.mp-modal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

@media (max-width: 768px) {
    .mp-modal-content {
        margin: 20px;
        max-height: calc(100vh - 40px);
    }
    
    .mp-modal-grid {
        grid-template-columns: 1fr;
    }
    
    .mp-modal-body {
        padding: 20px;
    }
}

.mp-modal-left img {
    max-height: 250px;
    width: 100%;
    object-fit: contain;
}
.mp-modal-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.mp-modal-right {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.mp-modal-title {
    font-size: 24px;
    margin: 0;
    color: #333;
    line-height: 1.4;
}

.mp-modal-sku {
    font-size: 14px;
    color: #666;
    font-family: monospace;
    margin: 0;
}

.mp-modal-desc {
    padding: 15px;
    background: #f9f9f9;
    border-radius: 8px;
    border-left: 4px solid #ec4801;
}

.mp-modal-desc strong {
    display: block;
    margin-bottom: 8px;
    color: #ec4801;
}

.mp-modal-desc p {
    margin: 0;
    color: #666;
    line-height: 1.6;
}

.mp-modal-actions {
    margin-top: auto;
    padding-top: 20px;
    border-top: 2px solid #f0f0f0;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.mp-modal-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 600;
    color: #333;
}

.mp-modal-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: #ec4801;
}

.mp-modal-close-btn {
    background: #ec4801;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.mp-modal-close-btn:hover {
    background: #ec4801;
}


/* ====================================
   FLOATING BADGE
   ==================================== */

.mp-floating-badge {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #e14502;
    color: white;
    padding: 15px 25px;
    border-radius: 50px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 9999;
    animation: bounceIn 0.5s ease;
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.5);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.mp-badge-count {
    background: white;
    color: #e14602;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
}

.mp-badge-text {
    font-weight: 600;
    font-size: 14px;
}

@media (max-width: 480px) {
    .mp-floating-badge {
        bottom: 20px;
        right: 20px;
        padding: 12px 20px;
    }
}


/* ====================================
   BODY SCROLL LOCK
   ==================================== */

body.mp-modal-open {
    overflow: hidden;
}


/* ====================================
   QUOTE PAGE
   ==================================== */

.mp-quote-page-wrapper {
    width: 100%;
    margin: 0 auto;
}

.mp-selected-products-section {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.mp-selected-products-section h2 {
    font-size: 24px !important;
    margin: 0 0 10px 0;
    color: #333;
    border-bottom: 3px solid #e64702;
    padding-bottom: 10px;
}

.mp-section-desc {
    color: #666;
    font-size: 14px;
    margin: 0 0 20px 0;
    font-style: italic;
}
.mp-selected-product-card button {
    padding: 0;
    font-size: 12px;
    width: 25px;
    height: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.mp-selected-product-card span {
    font-size: 18px !important;
    width: unset !important;
    height: unset !important;
    line-height: 12px;
}
.mp-selected-products-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 20px;
    margin-top: 20px;
}

@media (max-width:767px){
	.mp-selected-products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
}
@media (max-width:1024px) and (min-width:768px) {
	.mp-selected-products-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
    }
}
@media (max-width:1280px) and (min-width:1024px) {
	.mp-selected-products-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 10px;
    }
}
@media (min-width:1280px) and (max-width:1400px) {
    .mp-selected-products-grid {
        grid-template-columns: repeat(6, 1fr);
        gap: 10px;
    }
}

.mp-selected-product-card {
    background: #f9f9f9;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    transition: all 0.3s;
}

.mp-selected-product-card:hover {
    border-color: #e64702;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.mp-selected-img-wrap {
    position: relative;
    aspect-ratio: 1;
    overflow: hidden;
    background: white;
}

.mp-selected-img-wrap img {
    width: 100%;
    height: 100% !important;
    object-fit: cover;
}
.mp-selected-info h6 {
    margin: 0;
}
.mp-selected-info p {
    margin: 0;
}
.mp-view-product-detail {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(34, 113, 177, 0.9);
    color: white;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    opacity: 0;
}

.mp-selected-product-card:hover .mp-view-product-detail {
    opacity: 1;
}

.mp-view-product-detail:hover {
    background: #e64702;
    transform: scale(1.1);
}

.mp-view-product-detail .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

.mp-selected-info {
    padding: 15px;
}

.mp-selected-info h4 {
    margin: 0 0 8px 0;
    font-size: 15px;
    color: #333;
    line-height: 1.4;
}

.mp-selected-sku {
    font-size: 12px;
    color: #666;
    margin: 0 0 10px 0;
    font-family: monospace;
}

/* Quantity Input Wrapper */
.mp-quantity-wrapper {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.mp-quantity-wrapper label {
    font-size: 12px;
    font-weight: 600;
    color: #555;
    margin: 0;
}

.mp-quantity-input {
    width: 100%;
    padding: 8px 10px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    transition: all 0.2s;
    background: white;
}

.mp-quantity-input:focus {
    outline: none;
    border-color: #e64702;
    box-shadow: 0 0 0 2px rgba(34, 113, 177, 0.1);
}

.mp-quantity-input:hover {
    border-color: #e64702;
}

/* Chrome, Safari, Edge - Remove spinner arrows */
.mp-quantity-input::-webkit-outer-spin-button,
.mp-quantity-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Firefox - Remove spinner arrows */
.mp-quantity-input[type=number] {
    -moz-appearance: textfield;
}

.mp-remove-selected {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(214, 54, 56, 0.9);
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    opacity: 0;
}

.mp-selected-product-card:hover .mp-remove-selected {
    opacity: 1;
}

.mp-remove-selected:hover {
    background: #d63638;
    transform: scale(1.1);
}

.mp-no-selection {
    text-align: center;
    padding: 60px 20px;
}

.mp-empty-icon {
    font-size: 64px;
    color: #ccc;
    margin-bottom: 20px;
}

.mp-empty-icon .dashicons {
    width: 64px;
    height: 64px;
    font-size: 64px;
}

.mp-no-selection h3 {
    font-size: 24px !important;
    margin: 0 0 10px 0;
    color: #666;
}

.mp-no-selection p {
    color: #999;
    margin: 0 0 20px 0;
}


/* ====================================
   QUOTE FORM
   ==================================== */

.mp-quote-form-section {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.mp-quote-form-section h2 {
    font-size: 24px !important;
    margin: 0 0 10px 0;
    color: #333;
}

.mp-quote-form-section .description {
    color: #666;
    margin: 0 0 25px 0;
}

.mp-quote-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.mp-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 768px) {
    .mp-form-row {
        grid-template-columns: 1fr;
    }
}

.mp-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mp-form-group label {
    font-weight: 600;
    font-size: 14px;
    color: #333;
}

.mp-form-group input,
.mp-form-group textarea {
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.2s;
}

.mp-form-group input:focus,
.mp-form-group textarea:focus {
    border-color: #e64702;
    outline: none;
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

.mp-form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.required {
    color: #d63638;
}

.mp-form-actions {
    margin-top: 10px;
}

.button-hero {
    padding: 15px 40px;
    font-size: 18px;
    border-radius: 6px;
    background: #e64702;
    color: white;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.button-hero:hover {
    background: #e64702;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 113, 177, 0.3);
}

.button-hero:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.mp-btn-loading .spinner {
    float: none;
    margin: 0;
}


/* ====================================
   QUOTE RESPONSE
   ==================================== */
.mp-quot-message.mp-quot-error {
    display: flex;
    flex-direction: column;
    align-items: center;
}
.mp-quote-response {
    margin-top: 30px;
}

.mp-success-message,
.mp-error-message {
    padding: 25px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.mp-success-message {
    background: #d4edda;
    border: 2px solid #28a745;
    color: #155724;
}

.mp-error-message {
    background: #f8d7da;
    border: 2px solid #d63638;
    color: #721c24;
}

.mp-success-message .dashicons,
.mp-error-message .dashicons {
    font-size: 48px;
    width: 48px;
    height: 48px;
    margin-bottom: 15px;
}

.mp-success-message h3 {
    margin: 0 0 10px 0;
    font-size: 22px;
}

.mp-success-message p,
.mp-error-message p {
    margin: 5px 0;
    font-size: 16px;
}

/* ====================================
   VIDEO SLIDER STYLES
   ==================================== */

.mp-video-slider-wrapper {
    margin: 30px 0;
    position: relative;
}

.mp-video-slider {
    width: 100%;
    padding: 20px 0;
}

.mp-video-slider .swiper-wrapper {
    display: flex;
    align-items: stretch;
}

.mp-video-slider .swiper-slide {
    display: flex;
    justify-content: center;
    align-items: stretch;
    height: auto;
}

.mp-video-item {
    width: 100%;
    height: 240px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mp-video-item video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

/* Navigation Buttons */
.mp-video-slider .swiper-button-next,
.mp-video-slider .swiper-button-next, 
.mp-video-slider .swiper-button-prev {
    background: rgba(255, 255, 255, 0.9);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.mp-video-slider .swiper-button-next:after,
.mp-video-slider .swiper-button-prev:after {
    font-size: 16px;
    font-weight: bold;
    color: #333;
}

.mp-video-slider .swiper-button-next:hover,
.mp-video-slider .swiper-button-prev:hover {
    background: #fff;
}

/* No Videos State */
.mp-no-videos {
    text-align: center;
    padding: 40px;
    background: #f9f9f9;
    border-radius: 8px;
    color: #666;
}

/* Responsive */
@media (max-width: 768px) {
    .mp-video-slider .swiper-button-next, 
	.mp-video-slider .swiper-button-prev {
        width: 20px;
        height: 20px;
        font-size: 10px;
    }
    
    .mp-video-slider .swiper-button-next:after, 
	.mp-video-slider .swiper-button-prev:after {
        font-size: 11px;
    }
    
    .mp-video-item {
        height: 240px;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .mp-video-item {
        height: 200px;
    }
}

@media (min-width: 1025px) {
    .mp-video-item {
        height: 240px;
    }
}