/* WooCommerce Variant Pricing Chart Styles */
.variant-pricing-chart {
    margin: 20px 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.pricing-chart-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #333;
}

.pricing-chart-wrapper {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.variant-pricing-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

.variant-pricing-table th {
    background: #f8f9fa;
    padding: 15px 12px;
    text-align: left;
    font-weight: 600;
    color: #6c757d;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #e9ecef;
}

.variant-pricing-table td {
    padding: 18px 12px;
    border-bottom: 1px solid #e9ecef;
    vertical-align: middle;
}

.variant-row:hover {
    background: #f8f9fa;
}

.variant-row:last-child td {
    border-bottom: none;
}

.variant-item {
    font-weight: 600;
    color: #333;
}

.variant-description {
    color: #666;
}

.variant-price {
    font-weight: 600;
    color: #28a745;
}

.quantity-controls {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    max-width: 120px;
}

.qty-btn {
    background: #f1f3f4;
    border: 1px solid #dadce0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    transition: all 0.2s ease;
    user-select: none;
}

.qty-btn:hover {
    background: #e8eaed;
}

.qty-btn:active {
    background: #dadce0;
}

.qty-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.qty-decrease {
    border-radius: 4px 0 0 4px;
}

.qty-increase {
    border-radius: 0 4px 4px 0;
}

.qty-input {
    width: 60px;
    height: 32px;
    text-align: center;
    border: 1px solid #dadce0;
    border-left: none;
    border-right: none;
    margin: 0;
    font-size: 14px;
    background: #fff;
}

.qty-input:focus {
    outline: none;
    border-color: #1a73e8;
    z-index: 1;
    position: relative;
}

.quantity-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.item-total {
    font-weight: 600;
    color: #1a73e8;
    font-size: 14px;
}

.min-qty-notice {
    color: #5f6368;
    font-size: 11px;
}

.pricing-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

.summary-left, .summary-right {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.total-items-count, .subtotal-amount {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.subtotal-amount {
    color: #1a73e8;
}

.summary-left small, .summary-right small {
    color: #5f6368;
    font-size: 12px;
}

.checkout-notice {
    margin-top: 8px;
    text-align: center;
}

.checkout-notice small {
    color: #5f6368;
    font-size: 11px;
}

.checkout-notice a {
    color: #1a73e8;
    text-decoration: none;
}

.checkout-notice a:hover {
    text-decoration: underline;
}

.chart-actions {
    padding: 20px;
    text-align: center;
    background: #fff;
}

.btn-add-to-cart {
    background: #1a73e8;
    color: white;
    padding: 12px 32px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 160px;
}

.btn-add-to-cart:hover:not(:disabled) {
    background: #1557b0;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(26, 115, 232, 0.3);
}

.btn-add-to-cart:disabled {
    background: #dadce0;
    color: #5f6368;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Loading states */
.variant-pricing-chart.loading {
    opacity: 0.7;
    pointer-events: none;
}

.btn-add-to-cart.loading {
    position: relative;
    color: transparent;
}

.btn-add-to-cart.loading::after {
    content: "";
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive design */
@media (max-width: 768px) {
    .variant-pricing-table {
        font-size: 14px;
    }
    
    .variant-pricing-table th,
    .variant-pricing-table td {
        padding: 12px 8px;
    }
    
    .pricing-summary {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
    
    .quantity-controls {
        max-width: 100px;
    }
    
    .qty-input {
        width: 50px;
    }
    
    .qty-btn {
        width: 28px;
        height: 28px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .variant-pricing-table th:nth-child(2),
    .variant-pricing-table td:nth-child(2) {
        display: none;
    }
    
    .pricing-chart-title {
        font-size: 20px;
    }
}