/* Import main style */

.testimonials__card-image {
    border-radius: var(--border-radius-xl);
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid var(--color-muted);
    cursor: pointer;
    position: relative;
}

.testimonials__card-image:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.testimonials__card-image::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cpath d='m21 21-4.35-4.35'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 16px;
}

.testimonials__card-image:hover::after {
    opacity: 1;
}

.testimonials__card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.testimonials__card-text {
    padding-bottom: 20px;
}

/* ==========================================================================
    MAGNIFY MODAL STYLES
    ========================================================================== */

.testimonials-magnify-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.testimonials-magnify-modal.active {
    opacity: 1;
    visibility: visible;
}

.testimonials-magnify-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.testimonials-magnify-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: var(--border-radius-lg);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.testimonials-magnify-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.testimonials-magnify-close:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.1);
}

/* ==========================================================================
    RESPONSIVE DESIGN
    ========================================================================== */

@media (max-width: 768px) {
    .testimonials-magnify-content {
        max-width: 95%;
        max-height: 95%;
    }
    
    .testimonials-magnify-close {
        top: -40px;
        font-size: 1.5rem;
        width: 35px;
        height: 35px;
    }
    
    .testimonials__card-image::after {
        width: 35px;
        height: 35px;
        background-size: 14px;
    }
}

/* ==========================================================================
    ACCESSIBILITY ENHANCEMENTS
    ========================================================================== */

.testimonials__card-image:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

.testimonials-magnify-close:focus {
    outline: 2px solid white;
    outline-offset: 2px;
}

/* ==========================================================================
    ANIMATIONS
    ========================================================================== */

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.testimonials-magnify-modal.active .testimonials-magnify-content {
    animation: modalFadeIn 0.3s ease-out;
}