/* ==========================================
   HOME PAGE SPECIFIC STYLES
   ========================================== */

/* Product Detail in Modal */
.product-detail {
    padding: 30px 20px;
}

.product-image {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    background: linear-gradient(135deg, var(--surface-alt) 0%, #F0F4F8 100%);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 24px;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-info h2 {
    margin-bottom: 8px;
    font-size: 1.6rem;
}

.product-description {
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-size: 0.95rem;
    line-height: 1.6;
}

.price-section {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.price {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--primary);
}

.discount {
    background-color: var(--danger);
    color: white;
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
}

.availability-badge {
    display: inline-block;
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.availability-badge.available {
    background-color: #E8F5E9;
    color: var(--success);
}

.availability-badge.unavailable {
    background-color: #FFEBEE;
    color: var(--danger);
}

.quantity-selector {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.qty-input {
    width: 50px;
    padding: 8px;
    text-align: center;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
}

.qty-input:focus {
    outline: none;
    border-color: var(--primary);
}

/* Loading and Animation States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.loader {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Toast Notifications */
.toast {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background: var(--surface);
    padding: 16px 20px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    z-index: 2000;
    animation: slideUp 0.3s ease;
    max-width: 300px;
}

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

.toast.success {
    border-left: 4px solid var(--success);
}

.toast.error {
    border-left: 4px solid var(--danger);
}

.toast.info {
    border-left: 4px solid var(--info);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-secondary);
}

.empty-state-icon {
    font-size: 64px;
    margin-bottom: 16px;
}

.empty-state h3 {
    margin-bottom: 8px;
    color: var(--text-primary);
}

/* Animations */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

.skeleton {
    background: linear-gradient(90deg, var(--surface-alt) 25%, #FFFFFF 50%, var(--surface-alt) 75%);
    background-size: 1000px 100%;
    animation: shimmer 2s infinite;
}

/* Responsive Text */
@media (max-width: 480px) {
    .product-info h2 {
        font-size: 1.3rem;
    }

    .price {
        font-size: 1.4rem;
    }

    .product-detail {
        padding: 20px;
    }
}
