/* Product Card Link - Ensures proper clickable behavior without affecting styling */
.product-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
    outline: none;
    transition: none;
}

.product-category {
	height: 33px;
}

.product-title {
    height: 45px;
}

.product-card-link:hover,
.product-card-link:focus,
.product-card-link:active,
.product-card-link:visited {
    text-decoration: none;
    color: inherit;
    outline: none;
}

.product-card-link:focus-visible {
    outline: 2px solid #2563EB;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Base Card */
.modern-product-card {
    background: #FFFFFF;
    border-radius: 4px;
    border: 1px solid #c8d5dc;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                border-color 0.3s ease;
    position: relative;
    margin-bottom: 0px;
    cursor: pointer;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.modern-product-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg,
        rgba(37, 99, 235, 0.01) 0%,
        transparent 30%,
        transparent 70%,
        rgba(249, 115, 22, 0.01) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 1;
}

.modern-product-card:hover::before {
    opacity: 1;
}

.modern-product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.08);
    border-color: rgba(37, 99, 235, 0.1);
}

/* Header - Minimal badges */
.product-card-header {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    z-index: 10;
    pointer-events: none;
}

.product-card-header > * {
    pointer-events: auto;
}

/* Badges - Minimal design */
.product-badges {
    display: flex;
    flex-direction: row;
    gap: 6px;
    flex-wrap: wrap;
}

.discount-badge {
    background: #F97316;
    color: #FFFFFF;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Promo Badge - Compact minimal design, left-aligned at image bottom edge */
.promo-badge-edge {
    position: absolute;
    bottom: 0px;
    left: 0px;
    transform: translateY(50%);
    background: #2563EB;
    color: #FFFFFF;
    padding: 4px 8px;
    border-radius: 0 8px 8px 0px;
    font-size: 9px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    z-index: 15;
    box-shadow: 0 1px 4px rgba(37, 99, 235, 0.2);
    transition: all 0.2s ease;
    min-width: 50px;
    text-align: center;
}

.modern-product-card:hover .promo-badge-edge {
    background: #1d4ed8;
    transform: translateY(50%) scale(1.02);
    box-shadow: 0 2px 6px rgba(37, 99, 235, 0.3);
}

/* Promo Badge - When positioned above best seller */
.promo-badge-edge.promo-above-bestseller {
    bottom: 20px;
    left: 0px;
    transform: translateY(0%);
    z-index: 16;
}

.modern-product-card:hover .promo-badge-edge.promo-above-bestseller {
    transform: translateY(0%) scale(1.02);
}

/* Best Seller Badge - Ultra compact and minimal design */
.best-seller-badge {
    background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
    color: #FFFFFF;
    padding: 0px 6px;
    border-radius: 15px;
    font-size: 7px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 3px;
    box-shadow: 0 2px 8px rgba(249, 115, 22, 0.25);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                background 0.3s ease,
                box-shadow 0.3s ease;
    position: relative;
    min-width: 60px;
    justify-content: center;
}

/* Best Seller Badge - When positioned at bottom edge of image */
.best-seller-badge.best-seller-edge {
    position: absolute;
    bottom: 0px;
    left: 0px;
    transform: translateY(50%);
    border-radius: 0 8px 8px 8px;
    font-size: 9px;
    font-weight: 600;
    padding: 4px 8px;
    z-index: 15;
    min-width: 70px;
}

.modern-product-card:hover .best-seller-badge.best-seller-edge {
    transform: translateY(50%) scale(1.03);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.best-seller-star {
    width: 8px;
    height: 10px;
    color: #FFFFFF;
    flex-shrink: 0;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}

/* Hover effects */
.modern-product-card:hover .best-seller-badge {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 4px 16px rgba(249, 115, 22, 0.35);
    background: linear-gradient(135deg, #ea580c 0%, #dc2626 100%);
    border-color: rgba(255, 255, 255, 0.3);
}

.modern-product-card:hover .best-seller-star {
    transform: rotate(5deg) scale(1.1);
}

/* Product Condition Badges - Flat Design with Icons */
.condition-badge {
    position: relative;
    padding: 6px 12px 6px 32px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    border: 1px solid;
    backdrop-filter: blur(8px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 80px;
    justify-content: center;
}

.condition-badge::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    filter: brightness(0) invert(1);
    transition: all 0.3s ease;
    z-index: 2;
}

.condition-badge::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent);
    transition: left 0.6s ease;
    z-index: 1;
}

.modern-product-card:hover .condition-badge::after {
    left: 100%;
}

/* NUOVO - Green #60CA99 */
.condition-badge.condition-nuovo {
    background: rgba(96, 202, 153, 0.5);
    color: #064e3b;
    border-color: rgba(96, 202, 153, 0.4);
    text-shadow: none;
    box-shadow: 0 2px 8px rgba(96, 202, 153, 0.2);
}

.condition-badge.condition-nuovo::before {
    background-image: url('https://audiocostruzioni.com/wp-content/uploads/2023/01/stato-1.png');
    filter: none !important;
}

.modern-product-card:hover .condition-badge.condition-nuovo {
    background: rgba(96, 202, 153, 0.6);
    transform: scale(1.02);
    box-shadow: 0 3px 12px rgba(96, 202, 153, 0.25);
    border-color: rgba(96, 202, 153, 0.5);
}

/* USATO - Yellow #FFC11F */
.condition-badge.condition-usato {
    background: rgba(255, 193, 31, 0.5);
    color: #92400e;
    border-color: rgba(255, 193, 31, 0.4);
    text-shadow: none;
    box-shadow: 0 2px 8px rgba(255, 193, 31, 0.2);
}

.condition-badge.condition-usato::before {
    background-image: url('https://audiocostruzioni.com/wp-content/uploads/2023/01/stato-3.png');
    filter: none !important;
}

.modern-product-card:hover .condition-badge.condition-usato {
    background: rgba(255, 193, 31, 0.6);
    transform: scale(1.02);
    box-shadow: 0 3px 12px rgba(255, 193, 31, 0.25);
    border-color: rgba(255, 193, 31, 0.5);
}

/* USATO VINTAGE - Brown #945830 */
.modern-product-card .condition-badge.condition-usato-vintage {
    background: rgba(148, 88, 48, 0.5) !important;
    color: #5e3214 !important;
    border-color: rgba(148, 88, 48, 0.4) !important;
    text-shadow: none !important;
    box-shadow: 0 2px 8px rgba(148, 88, 48, 0.2) !important;
}

.modern-product-card .condition-badge.condition-usato-vintage::before {
    background-image: url('https://audiocostruzioni.com/wp-content/uploads/2023/01/stato-4.png') !important;
    filter: none !important;
}

.modern-product-card:hover .condition-badge.condition-usato-vintage {
    background: rgba(148, 88, 48, 0.6) !important;
    transform: scale(1.02);
    box-shadow: 0 3px 12px rgba(148, 88, 48, 0.25) !important;
    border-color: rgba(148, 88, 48, 0.5) !important;
}

/* Fallback for USATO VINTAGE with space (in case attribute has space instead of hyphen) */
.modern-product-card .condition-badge.condition-usato.vintage {
    background: rgba(148, 88, 48, 0.5) !important;
    color: #5e3214!important;
    border-color: rgba(148, 88, 48, 0.4) !important;
    text-shadow: none !important;
    box-shadow: 0 2px 8px rgba(148, 88, 48, 0.2) !important;
}

.modern-product-card .condition-badge.condition-usato.vintage::before {
    background-image: url('https://audiocostruzioni.com/wp-content/uploads/2023/01/stato-4.png') !important;
    filter: none !important;
}

.modern-product-card:hover .condition-badge.condition-usato.vintage {
    background: rgba(148, 88, 48, 0.6) !important;
    transform: scale(1.02);
    box-shadow: 0 3px 12px rgba(148, 88, 48, 0.25) !important;
    border-color: rgba(148, 88, 48, 0.5) !important;
}

/* Additional specificity override for USATO VINTAGE - ensures brown color always applies */
.jet-woo-products .modern-product-card .condition-badge.condition-usato-vintage,
.jet-woo-products .modern-product-card .condition-badge.condition-usato.vintage {
    background: rgba(148, 88, 48, 0.5) !important;
    color: #5e3214 !important;
    border-color: rgba(148, 88, 48, 0.4) !important;
}

/* EX DEMO - Orange #FF7916 */
.condition-badge.condition-ex-demo,
.condition-badge.condition-demo {
    background: rgba(255, 121, 22, 0.4);
    color: #7c2d12;
    border-color: rgba(255, 121, 22, 0.3);
    text-shadow: none;
    box-shadow: 0 2px 8px rgba(255, 121, 22, 0.2);
}

.condition-badge.condition-ex-demo::before,
.condition-badge.condition-demo::before {
    background-image: url('https://audiocostruzioni.com/wp-content/uploads/2023/01/stato-2.png');
    filter: none !important;
}

.modern-product-card:hover .condition-badge.condition-ex-demo,
.modern-product-card:hover .condition-badge.condition-demo {
    background: rgba(255, 121, 22, 0.6);
    transform: scale(1.02);
    box-shadow: 0 3px 12px rgba(255, 121, 22, 0.25);
    border-color: rgba(255, 121, 22, 0.4);
}

/* VINTAGE - Soft Rose */
.condition-badge.condition-vintage {
    background: rgba(252, 165, 165, 0.5);
    color: #7f1d1d;
    border-color: rgba(252, 165, 165, 0.4);
    text-shadow: none;
    box-shadow: 0 2px 8px rgba(252, 165, 165, 0.2);
}

.condition-badge.condition-vintage::before {
    background-image: url('https://audiocostruzioni.com/wp-content/uploads/2023/01/stato-4.png');
    filter: none !important;
}

.modern-product-card:hover .condition-badge.condition-vintage {
    background: rgba(252, 165, 165, 0.6);
    transform: scale(1.02);
    box-shadow: 0 3px 12px rgba(252, 165, 165, 0.25);
    border-color: rgba(252, 165, 165, 0.5);
}

/* RICONDIZIONATO - Soft Lavender */
.condition-badge.condition-ricondizionato {
    background: rgba(196, 181, 253, 0.5);
    color: #4c1d95;
    border-color: rgba(196, 181, 253, 0.4);
    text-shadow: none;
    box-shadow: 0 2px 8px rgba(196, 181, 253, 0.2);
}

.condition-badge.condition-ricondizionato::before {
    background-image: url('https://audiocostruzioni.com/wp-content/uploads/2023/01/stato-2.png');
    filter: none !important;
}

.modern-product-card:hover .condition-badge.condition-ricondizionato {
    background: rgba(196, 181, 253, 0.6);
    transform: scale(1.02);
    box-shadow: 0 3px 12px rgba(196, 181, 253, 0.25);
    border-color: rgba(196, 181, 253, 0.5);
}

/* Simple icon hover effect */
.modern-product-card:hover .condition-badge::before {
    transform: translateY(-50%) scale(1.05);
    filter: brightness(0) invert(1);
}

/* Subtle pulse for new items */
.condition-badge.condition-nuovo {
    animation: newItemPulse 4s ease-in-out infinite;
}

@keyframes newItemPulse {
    0%, 100% {
        box-shadow: 0 2px 8px rgba(96, 202, 153, 0.2);
    }
    50% {
        box-shadow: 0 2px 8px rgba(96, 202, 153, 0.3);
    }
}

/* Button interaction fixes for anchor wrapper */
.product-card-link .wishlist-button,
.product-card-link .add-to-cart-btn {
    position: relative;
    z-index: 10;
    pointer-events: auto;
}

/* Prevent link activation on button areas */
.product-card-header,
.quick-actions {
    pointer-events: auto;
}

/* Wishlist - Minimal style with important overrides */
.wishlist-button {
    background: #F1F5F9 !important;
    border: none !important;
    border-radius: 50% !important;
    width: 36px !important;
    height: 36px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    padding: 0 !important;
    box-shadow: none !important;
}

.wishlist-button:hover {
    border-color: #F97316 !important;
    background: #FEF3F2 !important;
    transform: scale(1.05) !important;
    box-shadow: 0 2px 6px rgba(249, 115, 22, 0.15) !important;
}

.wishlist-button i {
    font-size: 16px !important;
    color: #6B7280 !important;
    transition: color 0.2s ease !important;
}

.wishlist-button:hover i {
    color: #F97316 !important;
}

.wishlist-button.active {
    background: #F97316 !important;
    border-color: #F97316 !important;
    box-shadow: 0 2px 8px rgba(249, 115, 22, 0.3) !important;
}

.wishlist-button.active i {
    color: #FFFFFF !important;
}

/* Image Container - Clean white background */
.product-image-container {
    position: relative;
    background: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 272px;
    padding: 0;
    z-index: 2;
}

/* Use background image instead of img tag */
.product-image-container {
    background-size: cover !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
}

.product-image-container {
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.modern-product-card:hover .product-image-container {
    transform: scale(1.02);
}

/* Cart Button - Positioned at bottom edge of image area, right-aligned */
.quick-actions {
    position: absolute;
    bottom: 0px;
    right: 20px;
    z-index: 15;
    transform: translateY(50%);
}

.add-to-cart-btn {
    background: #3b2ca2 !important;
    border: none !important;
    border-radius: 10px !important;
    width: 42px !important;
    height: 42px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.2) !important;
    padding: 0 !important;
    position: relative !important;
    overflow: hidden !important;
}

.add-to-cart-btn::before {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    left: -100% !important;
    width: 100% !important;
    height: 100% !important;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent) !important;
    transition: left 0.3s ease !important;
    border-radius: 10px !important;
}

.add-to-cart-btn:hover::before {
    left: 100% !important;
}

.add-to-cart-btn:hover {
    background: #412ec3 !important;
    transform: scale(1.05) !important;
    box-shadow: 0 4px 12px rgba(61, 38, 235, 0.3) !important;
}

.add-to-cart-btn i {
    font-size: 22px !important;
    color: #FFFFFF !important;
    position: relative !important;
    z-index: 1 !important;
}
.add-to-cart-btn.in-cart i{
    font-size: 18px !important;
}

/* Enhanced button states for add to cart */
.add-to-cart-btn.loading {
    background: #6B7280 !important;
    cursor: not-allowed !important;
    transform: none !important;
}

.add-to-cart-btn.loading::before {
    display: none !important;
}

.add-to-cart-btn.loading::after {
    content: '' !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    width: 16px !important;
    height: 16px !important;
    margin: -8px 0 0 -8px !important;
    border: 2px solid transparent !important;
    border-top: 2px solid #FFFFFF !important;
    border-radius: 50% !important;
    animation: spin 1s linear infinite !important;
    z-index: 2 !important;
}

.add-to-cart-btn.loading i {
    opacity: 0 !important;
}

.add-to-cart-btn.success {
    background: #10B981 !important;
    transform: scale(1.05) !important;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3) !important;
}

.add-to-cart-btn.success:hover {
    background: #059669 !important;
}

.add-to-cart-btn.in-cart {
    background: #10B981 !important;
    border-color: #10B981 !important;
}

.add-to-cart-btn.in-cart:hover {
    background: #059669 !important;
    transform: scale(1.05) !important;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3) !important;
}

.add-to-cart-btn.in-cart i {
    color: #FFFFFF !important;
}

/* Processing state for the entire card */
.modern-product-card.processing {
    pointer-events: none;
    opacity: 0.7;
}

.modern-product-card.processing .loading-overlay {
    opacity: 1;
    visibility: visible;
}

/* Enhanced loading spinner */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Wishlist button loading state */
.wishlist-button.loading {
    background: #6B7280 !important;
    cursor: not-allowed !important;
    transform: none !important;
}

.wishlist-button.loading::after {
    content: '' !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    width: 12px !important;
    height: 12px !important;
    margin: -6px 0 0 -6px !important;
    border: 1.5px solid transparent !important;
    border-top: 1.5px solid #FFFFFF !important;
    border-radius: 50% !important;
    animation: spin 1s linear infinite !important;
    z-index: 2 !important;
}

.wishlist-button.loading i {
    opacity: 0 !important;
}

/* Toast notification styles - enhanced */
.custom-toast {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    max-width: 300px !important;
    word-wrap: break-word !important;
}

.custom-toast::before {
    content: '\f00c' !important;
    font-family: "Line Awesome Free" !important;
    font-weight: 900 !important;
    font-size: 16px !important;
    flex-shrink: 0 !important;
}

/* Success animation for buttons */
@keyframes successPulse {
    0% { transform: scale(1.05); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1.05); }
}

.add-to-cart-btn.success {
    animation: successPulse 0.6s ease-in-out !important;
}

/* Product Info - Enhanced hierarchy with better spacing */
.product-info {
    padding: 20px 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
    min-height: 140px; /* Consistent height for balanced spacing */
    flex: 1;
    justify-content: space-between;
}


/* Price Section - Highest priority with enhanced styling */
.product-pricing {
    order: 3;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-top: auto; /* Push to bottom for consistent spacing */
    margin-bottom: 0;
    padding: 6px 0;
    border-radius: 8px;
    transition: all 0.3s ease;
}


.price-section {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.original-price {
    color: #374151 !important;
    font-size: 22px;
    font-weight: 800;
    line-height: 1;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.original-price.has-sale {
    color: #6d7a8d;
    font-size: 14px;
    font-weight: 400;
    text-decoration: line-through;
    text-decoration-thickness: 1.5px;
    text-decoration-color: #6d7a8d;
    text-shadow: none;
    opacity: 0.8;
}

.sale-price-container {
    color: #374151 !important;
    font-size: 22px;
    font-weight: 800;
    line-height: 1;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.modern-product-card:hover .sale-price-container {
    transform: scale(1.02);
}

.modern-product-card:hover .original-price {
    transform: scale(1.01);
}

/* Category - Subtle styling with emoji, less prominent than product name */
.product-category {
    order: 1;
    color: #9CA3AF;
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    display: flex;
    align-items: center;
    gap: 4px;
    position: relative;
    margin-bottom: 4px;
    padding: 2px 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    transition: color 0.3s ease;
}

.modern-product-card:hover .product-category {
    color: #6B7280;
}

/* Title - Enhanced typography with better readability and distinction from price */
.product-title {
    order: 2;
    font-size: 18px;
    font-weight: 600;
    color: #374151;
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-family: "Poppins", Sans-serif;
    transition: color 0.3s ease, transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    cursor: pointer;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    min-height: 36px; /* Consistent title height */
}

.modern-product-card:hover .product-title {
    color: #1F2937;
    transform: translateY(-1px);
}

/* Enhanced title structure */
.product-title .brand-name {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: #9CA3AF;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.product-title .product-name {
    text-align: left;
    display: block;
    font-size: 16px;
    font-weight: 600;
    color: inherit;
    text-transform: none;
    letter-spacing: -0.025em;
}

/* Enhanced category structure */
.product-category .category-text {
    text-align: left;
    position: relative;
    z-index: 1;
}

/* Enhanced price structure with consistent spacing */
.price-group {
    display: flex;
    flex-direction: column;
    gap: 2px;
    align-items: flex-start;
    width: 100%;
}

/* New price line styling - both prices on same line */
.price-line {
    display: flex;
    align-items: center;
    gap: 8px !important ;
    width: 100%;
    margin-bottom: 0;
    flex-wrap: wrap;
}

/* Crossed price line - for crossed out original price */
.crossed-price-line {
    display: flex;
    align-items: center;
    width: 100%;
    margin-bottom: 4px;
    order: 2;
}

/* Sale price line - for the actual sale price */
.sale-price-line {
    display: flex;
    align-items: center;
    width: 100%;
    margin-bottom: 0;
    order: 3;
}

/* Consistent spacing for regular price (no discount) */
.price-group .original-price:not(.has-sale) {
    margin-bottom: 0;
}

.original-price .currency,
.sale-price-container .currency {
    font-size: 22px;
    margin-right: 2px;
    margin-left: -6px;
}

.original-price .price-value,
.sale-price-container .sale-price {
    font-weight: inherit;
}

.price-group .price-line {
    order: 2;
    margin-bottom: 0;
}


/* Status - Clean Modern Design */
.product-status {
    order: 4;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    width: fit-content;
    margin-top: 6px;
    transition: all 0.2s ease;
    border: 1px solid;
}

.product-status::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
}

/* NEW - Fresh Green */
.stato-nuovo {
    background: #F0FDF4;
    color: #15803D;
    border-color: #BBF7D0;
}

.modern-product-card:hover .stato-nuovo {
    background: #DCFCE7;
    border-color: #86EFAC;
}

/* USED - Warm Orange */
.stato-usato {
    background: #FFF7ED;
    color: #C2410C;
    border-color: #FED7AA;
}

.modern-product-card:hover .stato-usato {
    background: #FFEDD5;
    border-color: #FDBA74;
}

/* RECONDITIONED - Professional Blue */
.stato-ricondizionato {
    background: #EFF6FF;
    color: #1E40AF;
    border-color: #BFDBFE;
}

.modern-product-card:hover .stato-ricondizionato {
    background: #DBEAFE;
    border-color: #93C5FD;
}

/* Quality Rating - Minimal */
.product-quality {
    order: 6;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-top: 1px solid #F1F5F9;
    margin-top: 6px;
}

.quality-stars {
    display: flex;
    gap: 1px;
}

.star {
    color: #E5E7EB;
    font-size: 12px;
}

.star.active {
    color: #FBBF24;
}

.quality-text {
    font-size: 9px;
    font-weight: 600;
    color: #6B7280;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Hide duplicate elements */
.wishlist-jetloop [ti_wishlists_addtowishlist],
.cont-btns {
    display: none !important;
}


/* Loading states */
.loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 20;
    border-radius: 16px;
}

.loading-overlay.active {
    opacity: 1;
    visibility: visible;
}

.loading-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid #F1F5F9;
    border-top: 2px solid #2563EB;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .modern-product-card {
        margin-bottom: 16px;
        border-radius: 4px;
    }

    .product-image-container {
        min-height: 248px;
        padding: 0;
    }
    
    .product-info {
        padding: 16px 12px 12px;
        gap: 8px;
    }
    
    .product-title {
        font-size: 14px;
        margin-bottom: 10px;
    }
    
    .original-price {
        font-size: 20px;
    }
    
    .sale-price-container {
        font-size: 20px;
    }
    
    .product-category {
        font-size: 10px;
        letter-spacing: 0.6px;
        margin-bottom: 4px;
    }

    .product-title .brand-name {
        font-size: 10px;
        margin-bottom: 3px;
    }
    
    .product-title .product-name {
        font-size: 14px;
    }
    
    .original-price .currency,
    .sale-price-container .currency {
        font-size: 0.75em;
    }
    
    /* Mobile adjustments for new pricing layout */
    .price-line {
        gap: 8px;
        margin-bottom: 3px;
    }
    
    .price-group {
        gap: 6px;
    }
    
    .price-group .original-price:not(.has-sale) {
        margin-bottom: 4px; /* Consistent mobile spacing */
    }
    
    .original-price.has-sale {
        font-size: 12px;
    }

    .add-to-cart-btn {
        width: 40px !important;
        height: 40px !important;
    }
    
    .add-to-cart-btn i {
        font-size: 18px !important;
    }
    .add-to-cart-btn.in-cart i{
        font-size: 16px !important;
    }
    
    .quick-actions {
        bottom: 0px !important;
        right: 16px !important;
        transform: translateY(50%) !important;
    }
    
    .wishlist-button {
        width: 28px !important;
        height: 28px !important;
    }
    
    .wishlist-button i {
        font-size: 14px !important;
    }
    
    /* Mobile adjustments for condition badges */
    .condition-badge {
        padding: 4px 4px 4px 20px;
        font-size: 7px;
        border-radius: 8px;
        min-width: 60px;
        letter-spacing: 0.2px;
    }
    
    .condition-badge::before {
        left: 6px;
        width: 12px;
        height: 12px;
    }
    
    /* Reduce condition badge hover effects on mobile */
    .modern-product-card:hover .condition-badge {
        transform: scale(1.03) translateY(-1px);
    }
    
    .discount-badge {
        padding: 3px 6px;
        font-size: 9px;
    }
    
    .promo-badge {
        padding: 2px 4px;
        font-size: 8px;
    }
    
    /* Mobile adjustments for promo badge edge */
    .promo-badge-edge {
        padding: 3px 6px;
        font-size: 8px;
        letter-spacing: 0.2px;
        min-width: 40px;
        border-radius: 0 8px 8px 0px;
        left: 16px;
    }
    
    /* Mobile adjustments for best seller badge */
    .best-seller-badge {
        padding: 1px 6px;
        font-size: 6px;
        border-radius: 10px;
        gap: 4px;
        min-width: 50px;
        letter-spacing: 0.3px;
    }
    
    /* Mobile adjustments for best seller badge at edge */
    .best-seller-badge.best-seller-edge {
        padding: 3px 6px;
        font-size: 8px;
        border-radius: 0 8px 8px 8px;
        min-width: 60px;
    }
    
    .best-seller-star {
        width: 6px;
        height: 9px;
    }
    
    /* Reduce hover effects on mobile */
    .modern-product-card:hover .best-seller-badge {
        transform: translateY(-1px) scale(1.01);
    }
    
    .modern-product-card:hover .best-seller-star {
        transform: rotate(3deg) scale(1.05);
    }
    
    .modern-product-card:hover .promo-badge-edge {
        transform: translateY(50%) scale(1.01);
    }
    
    .modern-product-card:hover .promo-badge-edge.promo-above-bestseller {
        transform: translateY(0%) scale(1.01);
    }
    
    .modern-product-card:hover .best-seller-badge.best-seller-edge {
        transform: translateY(50%) scale(1.01);
    }
    
}

/* Grid layout optimization - Balanced spacing */
.jet-woo-products__item {
    padding: 0px 15px 15px 0px !important;
    box-sizing: border-box !important;
}

.jet-woo-products .jet-woo-products__inner-box {
    padding: 0px !important;
    margin: 0px !important;
    box-sizing: border-box !important;
}

/* Ensure consistent grid spacing */
.jet-woo-products {
    margin-right: -15px !important;
    display: flex !important;
    flex-wrap: wrap !important;
}

/* For 3-column layouts (tablets) */
@media (max-width: 1024px) {
    
    .jet-woo-products__item {
        padding: 0px 12px 12px 0px !important;
    }
    
    .jet-woo-products {
        margin-right: -12px !important;
    }
}

/* For 2-column layouts (mobile) */
@media (max-width: 768px) {
    
    .jet-woo-products__item:nth-child(2n) {
        padding-right: 0px !important;
    }
    
    .jet-woo-products__item {
        padding: 0px 10px 10px 0px !important;
    }
    
    .jet-woo-products {
        margin-right: 0 !important;
		margin-left: 0 !important;
		margin-top: 8px !important;
    }
}

/* For single column layouts (small mobile) */
@media (max-width: 480px) {
    .jet-woo-products__item:nth-child(2n) {
        padding-right: 10px !important;
    }
    
    .jet-woo-products__item {
        padding: 4px 8px 4px 0px !important;
    }
	
	.jet-woo-products.jet-woo-products--preset-1 {
		margin-right: -10px !important;
		margin-top: 5px !important;
	}
}

/* Focus states for accessibility */
.wishlist-button:focus,
.add-to-cart-btn:focus {
    outline: 2px solid #2563EB;
    outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .modern-product-card,
    .wishlist-button,
    .add-to-cart-btn {
        transition: none !important;
    }
    
    .modern-product-card:hover {
        transform: none !important;
    }
}

/* Performance optimizations */
.modern-product-card {
    contain: layout style paint;
    will-change: transform;
}

/* Typography improvements */
.product-category {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Ensure proper stacking */
.modern-product-card {
    isolation: isolate;
}


.barrato-yes .price-line span {
    text-decoration: line-through;
}

.barrato-yes .quick-action-btn.add-to-cart-btn {
    display: none !important;
}

.out-of-stock .quick-action-btn.add-to-cart-btn {
    display: none !important;
}