/* Custom Effects for Datasyncsa */

:root {
    --primary: #019d70;
}

#hero-title {
    position: relative;
    cursor: default;
}

.char {
    display: inline-block;
    transition: transform 0.2s ease, color 0.2s ease;
}

.char:hover {
    color: var(--primary);
    transform: translateY(-5px) scale(1.1);
}

/* Gradient Shimmer Effect */
.shimmer {
    background: linear-gradient(90deg,
            currentColor 0%,
            #019d70 50%,
            currentColor 100%);
    background-size: 200% auto;
    color: transparent;
    -webkit-background-clip: text;
    background-clip: text;
    animation: shimmer 4s linear infinite;
}

@keyframes shimmer {
    to {
        background-position: 200% center;
    }
}

/* Infinite Scroll Logic */
.logo-carousel-container {
    display: flex;
    overflow: hidden;
    position: relative;
    width: 100%;
    /* Minimal side fade */
    mask-image: linear-gradient(90deg, transparent, #fff 5%, #fff 95%, transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, #fff 5%, #fff 95%, transparent);
    padding: 10px 0;
    /* Minimal vertical padding */
}

.logo-carousel-group {
    display: flex;
    white-space: nowrap;
    animation: scroll 40s linear infinite;
    flex-shrink: 0;
}

.logo-carousel-container:hover .logo-carousel-group {
    animation-play-state: paused;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-100%);
    }
}

.logo-item {
    flex: 0 0 auto;
    width: auto;
    /* Allow items to shrink to their content width */
    margin: 0 10px;
    /* Minimal margin for maximum closeness */
    height: 160px;
    /* Doubled height */
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s ease;
    filter: grayscale(100%);
    opacity: 0.5;
}

.logo-item:hover {
    filter: grayscale(0%);
    opacity: 1;
    transform: scale(1.1);
}

.logo-item img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.testimonial-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.testimonial-card:hover {
    transform: translateY(-4px);
}

/* Mobile Responsive Styles */
@media (max-width: 640px) {
    /* Hide decorative gradient elements on mobile */
    main section:first-of-type .absolute {
        display: none !important;
    }
    
    /* Hero title adjustments */
    #hero-title {
        font-size: clamp(2.25rem, 9.5vw, 3.1rem);
        line-height: 1.2;
        word-wrap: break-word;
        overflow-wrap: break-word;
        max-width: 100%;
        text-align: left;
    }
    
    /* Badge closer to title */
    .inline-flex.items-center.rounded-full {
        margin-bottom: 1rem !important;
    }
    
    #hero-title .char:hover {
        transform: translateY(-2px) scale(1.05);
    }

    main > section:first-of-type p.text-base {
        padding: 0.75rem 0.9rem;
    }
    
    /* Logo carousel - smaller on mobile */
    .logo-item {
        height: 80px;
        margin: 0 8px;
    }
    
    .logo-item img {
        max-width: 80px;
        max-height: 60px;
    }
    
    .logo-carousel-group {
        animation-duration: 25s;
    }
    
    /* Touch-friendly buttons */
    button, 
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    /* Cards padding adjustment */
    .group {
        padding: 1rem;
        margin-left: auto;
        margin-right: auto;
        width: 100%;
        max-width: 32rem;
    }
    
    /* Testimonials single column */
    .testimonial-card {
        padding: 1rem;
        margin-left: auto;
        margin-right: auto;
        width: 100%;
        max-width: 32rem;
    }
    
    /* Footer grid mobile */
    footer .grid {
        gap: 1.5rem;
    }
    
    /* Hero compact spacing for smoother handoff to client section */
    main > section:first-of-type {
        padding-top: 1rem !important;
        padding-bottom: 0.75rem !important;
    }

    main > section:first-of-type .mt-4 {
        margin-top: 0.5rem !important;
        margin-bottom: 0.9rem;
        justify-content: flex-start;
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    main > section:nth-of-type(2) > div {
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
    }

    main > section .section-heading {
        margin-bottom: 1.25rem !important;
        text-align: left;
    }
    
    /* Keep hero text naturally aligned on mobile */
    #title-part-1,
    #title-part-2 {
        width: auto !important;
        white-space: normal !important;
    }

    main section .h-1.w-full {
        max-width: 100%;
    }

    /* Keep footer compact and centered */
    footer .mx-auto {
        text-align: left;
    }
    
    /* Hide some decorative elements on mobile */
    .absolute.bottom-0.left-0 {
        display: none;
    }
}

/* Very small phones: iPhone SE / compact Android (<=360px) */
@media (max-width: 360px) {
    main > section:first-of-type {
        padding-top: 0.65rem !important;
        padding-bottom: 0.4rem !important;
    }

    #hero-title {
        font-size: 2.25rem;
        line-height: 1.14;
        margin-bottom: 0.6rem !important;
    }

    main > section:first-of-type .text-base {
        font-size: 0.93rem;
        line-height: 1.45;
        margin-bottom: 0.6rem !important;
    }

    main > section:first-of-type .mt-4 {
        margin-top: 0.3rem !important;
    }

    main > section:nth-of-type(2) > div {
        padding-top: 0.3rem;
        padding-bottom: 0.4rem;
    }

    main > section .section-heading {
        margin-bottom: 1rem !important;
    }
}

/* Small phones: 361px-390px */
@media (min-width: 361px) and (max-width: 390px) {
    main > section:first-of-type {
        padding-top: 0.75rem !important;
        padding-bottom: 0.5rem !important;
    }

    #hero-title {
        font-size: 2.4rem;
        line-height: 1.16;
        margin-bottom: 0.7rem !important;
    }

    main > section:first-of-type .text-base {
        font-size: 0.97rem;
        margin-bottom: 0.7rem !important;
    }

    main > section:nth-of-type(2) > div {
        padding-top: 0.35rem;
        padding-bottom: 0.45rem;
    }
}

/* Standard modern phones: 391px-430px */
@media (min-width: 391px) and (max-width: 430px) {
    main > section:first-of-type {
        padding-top: 0.85rem !important;
        padding-bottom: 0.6rem !important;
    }

    #hero-title {
        font-size: 2.6rem;
        margin-bottom: 0.75rem !important;
    }

    main > section:first-of-type .text-base {
        font-size: 1rem;
        margin-bottom: 0.8rem !important;
    }

    main > section:nth-of-type(2) > div {
        padding-top: 0.45rem;
        padding-bottom: 0.55rem;
    }
}

/* Large phones: 431px-640px */
@media (min-width: 431px) and (max-width: 640px) {
    main > section:first-of-type {
        padding-top: 1rem !important;
        padding-bottom: 0.75rem !important;
    }

    #hero-title {
        font-size: 2.8rem;
    }

    main > section:first-of-type .text-base {
        font-size: 1.03rem;
    }
}

@media (min-width: 641px) and (max-width: 768px) {
    #hero-title {
        font-size: 3.5rem;
    }
    
    .logo-item {
        height: 100px;
    }
    
    .logo-carousel-group {
        animation-duration: 30s;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    #hero-title {
        font-size: 4.5rem;
    }
    
    .logo-item {
        height: 120px;
    }
}

@media (min-width: 1024px) {
    .clients-heading {
        margin-bottom: 3.5rem !important;
    }
}
