﻿:root {
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #17a2b8;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --glass-bg: rgba(255, 255, 255, 0.25);
    --glass-border: rgba(255, 255, 255, 0.18);
}

body {
    transition: all 0.3s ease;
    background-color: var(--light-color);
    color: var(--dark-color);
}

/* Animated Background Particles */
.particles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: radial-gradient(circle, var(--primary-color), transparent);
    border-radius: 50%;
    animation: float 15s infinite linear;
    opacity: 0.6;
}

@keyframes float {
    0% {
        transform: translateY(100vh) translateX(0px) rotate(0deg);
        opacity: 0;
    }

    10% {
        opacity: 0.6;
    }

    90% {
        opacity: 0.6;
    }

    100% {
        transform: translateY(-100px) translateX(100px) rotate(360deg);
        opacity: 0;
    }
}

/* Success Metrics */
.metrics-container {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
}

.metric-card {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 15px;
    text-align: center;
    min-width: 150px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

    .metric-card::before {
        content: '';
        position: absolute;
        top: -50%;
        left: -50%;
        width: 200%;
        height: 200%;
        background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
        transform: rotate(45deg);
        transition: all 0.6s ease;
        opacity: 0;
    }

    .metric-card:hover::before {
        animation: shimmer 1.5s ease-in-out;
    }

@keyframes shimmer {
    0% {
        transform: translateX(-100%) translateY(-100%) rotate(45deg);
        opacity: 0;
    }

    50% {
        opacity: 1;
    }

    100% {
        transform: translateX(100%) translateY(100%) rotate(45deg);
        opacity: 0;
    }
}

.metric-number {
    font-size: 1.6rem;
    font-weight: bold;
    color: var(--primary-color);
    display: block;
}

.metric-label {
    font-size: 0.9rem;
    color: var(--secondary-color);
}

/* Enhanced Filter Buttons */
.country-filter {
    margin-bottom: 1rem;
}

    .country-filter ul {
        margin: 0;
        padding: 0;
        list-style: none !important;
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem;
        align-items: center;
    }

        .country-filter ul li {
            flex-shrink: 0;
            list-style: none !important;
            list-style-type: none !important;
            margin: 0;
            padding: 0;
        }

/* UPDATED: 25% Smaller Filter Items */
.filter-item {
    display: inline-block;
    padding: 0.5rem 0.75rem; /* Reduced from 0.5rem 1rem (25% smaller) */
    color: var(--secondary-color);
    text-decoration: none;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 2px solid var(--glass-border);
    border-radius: 25px;
    transition: all 0.3s ease;
    cursor: pointer;
    white-space: nowrap;
    font-size: 0.656rem; /* Reduced from 0.875rem (25% smaller) */
    font-weight: 500;
    min-width: fit-content;
    position: relative;
    overflow: hidden;
}

    .filter-item:hover,
    .filter-item.active {
        transform: translateY(-2px) scale(1.05);
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    }

    .filter-item[data-filter="*"] {
        border-color: var(--primary-color);
    }

        .filter-item[data-filter="*"]:hover,
        .filter-item[data-filter="*"].active {
            background-color: #3B2E74;
            color: #ffffff;
        }

    /* UPDATED: 25% Smaller Country Count Badges */
    .filter-item::after {
        padding-bottom: 0.2rem !important;
        content: attr(data-count);
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        background: #3b2e74eb;
        color: white;
        border-radius: 4.5px 4.5px 0 0; /* Reduced from 6px (25% smaller) */
        font-size: 0.563rem; /* Reduced from 0.75rem (25% smaller) */
        font-weight: 600;
        font-size: 0.6rem; /* Reduced from 0.75rem (25% smaller) */
        line-height: 0.45; /* Reduced from 0.6 (25% smaller) */
        text-align: center;
        padding: 1.5px 0; /* Reduced from 2px 0 (25% smaller) */
        box-sizing: border-box;
    }

    .filter-item[data-filter="*"]::after {
        margin-block-start: 2px;
        content: attr(data-total);
    }

/* Flag icon styling */
.flag-icon {
    margin-right: 0.5rem;
    border-radius: 2px;
}

/* UPDATED: 25% Smaller Responsive Adjustments */
@media (max-width: 768px) {
    .country-filter ul {
        gap: 0.5rem; /* Reduced from 0.25rem (25% smaller) */
    }

    .filter-item {
        padding: 0.281rem 0.563rem; /* Reduced from 0.375rem 0.75rem (25% smaller) */
        font-size: 0.6rem; /* Reduced from 0.8rem (25% smaller) */
    }
}

@media (max-width: 576px) {
    .country-filter ul {
        justify-content: flex-start;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.5rem;
        scrollbar-width: thin;
    }

        .country-filter ul::-webkit-scrollbar {
            height: 4px;
        }

        .country-filter ul::-webkit-scrollbar-track {
            background: #f1f1f1;
            border-radius: 2px;
        }

        .country-filter ul::-webkit-scrollbar-thumb {
            background: var(--primary-color);
            border-radius: 2px;
        }

    .filter-item {
        padding: 0.5rem 0.563rem; /* Reduced from 0.375rem 0.75rem (25% smaller) */
        font-size: 0.563rem; /* Reduced from 0.75rem (25% smaller) */
    }
}

/* Enhanced Swiper */
.clients-swiper {
    overflow: hidden;
    position: relative;
}

.swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 80px;
    transition: all 0.5s ease;
    opacity: 0;
    transform: translateY(30px);
}

    .swiper-slide.slide-visible {
        opacity: 1;
        transform: translateY(0);
    }

    .swiper-slide.filtered-hidden {
        display: none !important;
    }

/* Glassmorphism Client Logos */
.client-logo {
    background: #3f78e099;
    backdrop-filter: blur(10px);
    border: 2px solid var(--glass-border);
    border-radius: 15px;
    padding: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: #495057;
    text-decoration: none;
    transition: all 0.3s ease;
    min-height: 100px;
    width: 100%;
    max-width: 180px;
    text-align: center;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    flex-direction: column;
}

    .client-logo img {
        max-width: 140px;
        max-height: 70px;
        width: auto;
        height: auto;
        object-fit: contain;
        filter: grayscale(70%);
        transition: filter 0.3s ease, transform 0.3s ease;
        display: block;
    }

    /* Magnetic hover effect */
    .client-logo.magnetic {
        transition: transform 0.1s ease-out;
    }

    /* Hover effects */
    .client-logo:hover {
        border-color: var(--primary-color);
        transform: translateY(-2px) scale(1.05);
        box-shadow: 0 8px 25px rgba(0, 123, 255, 0.25);
    }

        .client-logo:hover img {
            filter: grayscale(0%);
            transform: rotate(360deg) scale(1.1);
        }

    /* Optional decorative ::before effect on hover */
    .client-logo::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 0;
        height: 0;
        background: radial-gradient(circle, rgba(255, 255, 255, 0.8) 0%, rgba(0, 123, 255, 0.1) 40%, transparent 70%);
        border-radius: 50%;
        transform: translate(-50%, -50%);
        transition: all 0.5s ease;
        z-index: 1;
        opacity: 0;
    }

/* Smoke Swirl Animation - In and Out Effect */
@keyframes smokeSwirl {
    0% {
        width: 0;
        height: 0;
        opacity: 0;
        transform: translate(-50%, -50%) rotate(0deg) scale(0);
        filter: blur(0px);
    }

    25% {
        width: 80px;
        height: 80px;
        opacity: 0.8;
        transform: translate(-50%, -50%) rotate(90deg) scale(1.1);
        filter: blur(2px);
    }

    50% {
        width: 150px;
        height: 150px;
        opacity: 1;
        transform: translate(-50%, -50%) rotate(180deg) scale(1);
        filter: blur(3px);
    }

    75% {
        width: 200px;
        height: 200px;
        opacity: 0.4;
        transform: translate(-50%, -50%) rotate(270deg) scale(1.2);
        filter: blur(5px);
    }

    100% {
        width: 250px;
        height: 250px;
        opacity: 0;
        transform: translate(-50%, -50%) rotate(360deg) scale(1.5);
        filter: blur(8px);
    }
}

/* Alternative: More dramatic smoke effect with multiple swirls */
@keyframes smokeSwirl-dramatic {
    0% {
        width: 0;
        height: 0;
        opacity: 0;
        transform: translate(-50%, -50%) rotate(0deg) scale(0) skewX(0deg);
        filter: blur(0px);
    }

    15% {
        width: 40px;
        height: 60px;
        opacity: 0.6;
        transform: translate(-45%, -55%) rotate(45deg) scale(0.8) skewX(10deg);
        filter: blur(1px);
    }

    30% {
        width: 100px;
        height: 120px;
        opacity: 0.9;
        transform: translate(-50%, -50%) rotate(120deg) scale(1) skewX(-5deg);
        filter: blur(2px);
    }

    50% {
        width: 150px;
        height: 150px;
        opacity: 1;
        transform: translate(-52%, -48%) rotate(200deg) scale(1.1) skewX(8deg);
        filter: blur(3px);
    }

    70% {
        width: 180px;
        height: 200px;
        opacity: 0.6;
        transform: translate(-48%, -52%) rotate(280deg) scale(1.3) skewX(-12deg);
        filter: blur(5px);
    }

    85% {
        width: 220px;
        height: 240px;
        opacity: 0.2;
        transform: translate(-50%, -50%) rotate(340deg) scale(1.6) skewX(15deg);
        filter: blur(7px);
    }

    100% {
        width: 280px;
        height: 300px;
        opacity: 0;
        transform: translate(-50%, -50%) rotate(420deg) scale(2) skewX(0deg);
        filter: blur(10px);
    }
}

/* Updated client logo hover with improved smoke effect */
.client-logo::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient( ellipse at center, rgba(255, 255, 255, 0.9) 0%, rgba(0, 123, 255, 0.3) 30%, rgba(135, 206, 235, 0.2) 50%, rgba(255, 255, 255, 0.1) 70%, transparent 100% );
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: none;
    z-index: 1;
    opacity: 0;
    pointer-events: none;
}

.client-logo:hover::before {
    animation: smokeSwirl 1.5s ease-out forwards;
    /* OR use the dramatic version: */
    /* animation: smokeSwirl-dramatic 2s ease-out forwards; */
}

/* Optional: Add a secondary smoke layer for more depth */
.client-logo::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient( circle, rgba(0, 123, 255, 0.4) 0%, rgba(255, 255, 255, 0.2) 40%, transparent 70% );
    border-radius: 50%;
    transform: translate(-50%, -50%);
    z-index: 0;
    opacity: 0;
    pointer-events: none;
}

.client-logo:hover::after {
    animation: smokeSwirl 1s ease-out 0.1s forwards;
}

/* Text Logo Fallback */
.logo-text-fallback {
    display: inline-block;
    width: 100px;
    height: 50px;
    font-size: 11px;
    font-weight: 600;
    color: #6c757d;
    text-align: center;
    line-height: 1.2;
    word-break: break-word;
    vertical-align: middle;
}

/* Debug Info */
.debug-info {
    position: fixed;
    top: 10px;
    right: 10px;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    color: var(--dark-color);
    padding: 10px;
    border-radius: 10px;
    font-size: 12px;
    z-index: 1000;
    max-width: 200px;
}

/* Staggered entrance animation */
.clients-wrapper {
    animation: slideLeft 20s linear infinite;
}

@keyframes slideLeft {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.slide-enter {
    animation: slideInUp 0.6s ease-out forwards;
}

/* Canvas / Text Logo Rendering */
.text-logo {
    display: inline-block;
    width: 64px;
    height: 64px;
    object-fit: contain;
}
