/* Shared styles across all pages */
body {
    font-family: 'Vazirmatn', sans-serif;
}

/* Animations */
@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.animate-fade-in {
    animation: fade-in 1s ease-out;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* Brands Slider */
.brands-slider {
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.brands-track {
    display: inline-flex;
    animation: scroll 20s linear infinite;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #3b82f6;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #2563eb;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}
/* Responsive images */
img {
    max-width: 100%;
    height: auto;
}
/* Responsive fixes for footer and cards */
@media (max-width: 640px) {
    .footer-content {
        grid-template-columns: 1fr !important;
        text-align: center;
        gap: 1.5rem;
    }
    .social-links {
        justify-content: center;
    }
    .contact-item {
        justify-content: center;
    }
    .product-card, .review-card {
        margin: 0 auto;
        max-width: 100%;
    }
    .brands-track {
        gap: 1rem;
    }
    .brand-item {
        padding: 0.5rem 1rem;
        font-size: 0.875rem;
    }
}

/* Ensure single column for new products list on small screens */
@media (max-width: 768px) {
    .group > div {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    .group > div > div:last-child {
        width: 100%;
        justify-content: space-between;
    }
}

/* New products list responsive tweaks */
@media (max-width: 640px) {
    .group > div {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    .group > div > div:last-child {
        width: 100%;
        justify-content: space-between;
    }
    .group h4 {
        font-size: 1rem;
    }
    .group p {
        font-size: 0.75rem;
    }
    .group span.text-2xl {
        font-size: 1.25rem;
    }
    .group span.bg-red-100 {
        font-size: 0.65rem;
        padding: 0.25rem 0.5rem;
    }
}

/* Brands slider responsive */
@media (max-width: 768px) {
    .brands-track {
        animation-duration: 15s;
    }
    .brand-item {
        padding: 0.5rem 1rem;
        font-size: 0.875rem;
    }
}

/* Review cards responsive */
@media (max-width: 768px) {
    .review-card {
        padding: 1rem;
    }
    .review-card img {
        width: 2.5rem;
        height: 2.5rem;
    }
    .review-card h4 {
        font-size: 0.875rem;
    }
    .review-card p {
        font-size: 0.75rem;
    }
}

/* Footer responsive */
@media (max-width: 768px) {
    .footer-section h3 {
        font-size: 1rem;
    }
    .footer-section p, .footer-section a {
        font-size: 0.875rem;
    }
    .social-links a {
        width: 2rem;
        height: 2rem;
    }
}
/* Loading animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Hover effects */
.hover-lift {
    transition: transform 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
}

/* Glass morphism */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Gradient text */
.gradient-text {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}