/* --- CSS Reset and Base Styles --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;}
 .projects {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: #ffffff; /* White background as requested */
    color: #2D3748;
    line-height: 1.6;
    padding: 2rem 1rem;
}

/* --- Typography & Header --- */
.header {
    text-align: center;
    margin-bottom: 3rem;
    animation: fadeInDown 0.8s ease-out;
}

.header h1 {
    font-size: 2.5rem;
    color: #1A365D; /* Corporate dark blue */
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.header p {
    font-size: 1.125rem;
    color: #718096;
}

/* --- Grid Layout --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2.5rem;
    margin-bottom: 3rem;
    min-height: 50vh; /* Prevents layout shift during pagination */
}

/* --- Project Card Styling (Pinterest/Modern Minimalist) --- */
.card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    border: 1px solid #edf2f7;
    display: flex;
    flex-direction: column;
    animation: fadeIn 0.5s ease forwards;
    opacity: 0;
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.card-img-wrapper {
    width: 100%;
    height: 220px; /* Medium size as requested */
    overflow: hidden;
    background-color: #E2E8F0;
}

.card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.card:hover .card-img-wrapper img {
    transform: scale(1.08); /* Dynamic zoom on hover */
}

.card-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #2D3748;
    margin-bottom: 0.5rem;
}

.card-desc {
    font-size: 0.875rem;
    color: #4A5568;
    flex-grow: 1;
}

.card-location {
    margin-top: 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: #3182ce;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* --- Pagination Styling --- */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.page-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background-color: #EDF2F7;
    color: #4A5568;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    justify-content: center;
    align-items: center;
}

.page-btn:hover:not(:disabled) {
    background-color: #E2E8F0;
}

.page-btn.active {
    background-color: #1A365D;
    color: #ffffff;
    box-shadow: 0 4px 6px rgba(26, 54, 93, 0.2);
}

.page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* --- Keyframe Animations --- */
@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Responsive Design (Updated for 2 Cards on Mobile) --- */
@media (max-width: 768px) {
    .projects-grid {
        /* Forces exactly two equal-width columns */
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem; /* Reduced gap to fit small screens better */
    }
    
    .header h1 { 
        font-size: 2rem; 
    }

    /* Tweaking the card internals so text and images fit the narrow 2-column layout */
    .card-img-wrapper {
        height: 140px; /* Reduced image height to maintain aspect ratio */
    }

    .card-content {
        padding: 0.8rem; /* Tighter padding inside the card */
    }

    .card-title {
        font-size: 0.95rem; /* Slightly smaller title */
        margin-bottom: 0.25rem;
        line-height: 1.2;
    }

    .card-desc {
        font-size: 0.75rem; /* Smaller description */
    }

    .card-location {
        margin-top: 0.5rem;
        font-size: 0.7rem; /* Smaller location text */
    }
}

/* Fallback for extremely small screens (e.g., older phones under 380px wide) */
@media (max-width: 380px) {
    .projects-grid {
        grid-template-columns: 1fr;
    }
    .card-img-wrapper {
        height: 180px; 
    }
}



        /* client section css  */


       /* --- Base Setup --- */
        .clients-section {
            padding: 80px 20px;
            background: #ffffff;
            overflow: hidden;
            position: relative;
        }

        .section-title {
            text-align: center;
            margin-bottom: 60px;
        }

        .section-title h2 {
            font-size: 2.5rem;
            color: #1a365d;
            font-weight: 800;
            letter-spacing: -0.5px;
            margin-bottom: 10px;
        }

        /* --- Animated Slider Container --- */
        .slider-viewport {
            width: 100%;
            padding: 40px 0;
            position: relative;
            /* Gradient masking for soft edges */
            mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
            -webkit-mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
        }

        .slider-track {
            display: flex;
            width: calc(250px * 12); /* Based on (6 images * 2 for loop) */
            animation: infiniteScroll 25s linear infinite;
        }

        .slider-track:hover {
            animation-play-state: paused;
        }

        /* --- Individual Client Card --- */
        .client-card {
            width: 200px;
            height: 120px;
            margin: 0 30px;
            display: flex;
            align-items: center;
            justify-content: center;
            background: rgba(255, 255, 255, 0.8);
            border-radius: 15px;
            /* Creative Glass Effect */
            backdrop-filter: blur(5px);
            border: 1px solid #edf2f7;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
            transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
            padding: 20px;
        }

        .client-card img {
            max-width: 100%;
            max-height: 100%;
            object-fit: contain;
            /* filter: grayscale(100%); */
            opacity: 0.7;
            transition: all 0.4s ease;
        }

        /* --- Creative Hover State --- */
        .client-card:hover {
            transform: scale(1.1) rotate(2deg);
            background: #ffffff;
            border-color: #3182ce;
            box-shadow: 0 20px 30px rgba(0, 0, 0, 0.1);
            z-index: 10;
        }

        .client-card:hover img {
            filter: grayscale(0%);
            opacity: 1;
        }

        /* --- Keyframes --- */
        @keyframes infiniteScroll {
            0% { transform: translateX(0); }
            100% { transform: translateX(calc(-260px * 6)); } /* Adjust based on width + margins */
        }

        /* Floating Animation for variety */
        .client-card:nth-child(odd) {
            animation: float 4s ease-in-out infinite;
        }
        .client-card:nth-child(even) {
            animation: float 5s ease-in-out infinite reverse;
        }

        @keyframes float {
            0%, 100% { transform: translateY(0); }
            50% { transform: translateY(-10px); }
        }

        @media (max-width: 768px) {
            .client-card { width: 150px; height: 100px; margin: 0 15px; }
            .section-title h2 { font-size: 1.8rem; }
        }