/**
 * Fortune Writers Kenya - Professional Price Calculator Styles
 * Enhances the visual presentation of the price calculator with animations and professional styling
 */

/* Price display styles */
#price_display {
    transition: all 0.3s ease-in-out;
    font-weight: 700;
    font-size: 1.5rem;
}

#price_display.calculating {
    opacity: 0.7;
}

.price-up {
    color: #28a745;
    animation: priceChange 0.5s ease-in-out;
}

.price-down {
    color: #dc3545;
    animation: priceChange 0.5s ease-in-out;
}

.price-up-indicator,
.price-down-indicator {
    animation: fadeOut 2s ease-in-out;
}

.price-up-indicator {
    color: #28a745;
}

.price-down-indicator {
    color: #dc3545;
}

/* Price breakdown styles */
.price-breakdown-container {
    font-size: 0.9rem;
    color: #495057;
    transition: all 0.3s ease;
}

.price-breakdown-updated {
    animation: highlightUpdate 0.5s ease-in-out;
}

.price-breakdown-section {
    margin-bottom: 1rem;
    padding: 0.75rem;
    background-color: #f8f9fa;
    border-radius: 0.25rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.price-breakdown-header {
    font-weight: 600;
    color: #495057;
    border-bottom: 1px solid #dee2e6;
    padding-bottom: 0.5rem;
}

.price-breakdown-item {
    padding: 0.4rem 0;
    border-bottom: 1px dashed #e9ecef;
}

.price-breakdown-item:last-child {
    border-bottom: none;
}

.breakdown-label {
    color: #6c757d;
}

.breakdown-value {
    font-weight: 500;
}

.price-breakdown-total {
    font-size: 1.1rem;
    padding-top: 0.5rem;
    border-top: 2px solid #dee2e6;
}

.discount-item .breakdown-value {
    color: #28a745;
}

/* Animations */
@keyframes priceChange {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@keyframes fadeOut {
    0% { opacity: 1; }
    70% { opacity: 1; }
    100% { opacity: 0; }
}

@keyframes highlightUpdate {
    0% { background-color: rgba(255, 243, 205, 0.2); }
    50% { background-color: rgba(255, 243, 205, 0.5); }
    100% { background-color: transparent; }
}

/* Price card styles */
.price-card {
    transition: all 0.3s ease;
    border-radius: 0.5rem;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.price-card:hover {
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.price-card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    padding: 1rem;
}

.price-card-body {
    padding: 1.25rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    #price_display {
        font-size: 1.25rem;
    }
    
    .price-breakdown-container {
        font-size: 0.8rem;
    }
    
    .price-breakdown-total {
        font-size: 1rem;
    }
}
