/* CloudSynQ Team Gallery Styles */

/* Gallery Grid */
.cloudsynq-team-gallery {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(4, 1fr);
}

/* Team Member Card */
.cloudsynq-team-member {
    position: relative;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.cloudsynq-team-member:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Hover Effects */
.cloudsynq-team-gallery[data-hover-effect="zoom"] .cloudsynq-team-member:hover img {
    transform: scale(1.05);
}

.cloudsynq-team-gallery[data-hover-effect="lift"] .cloudsynq-team-member:hover {
    transform: translateY(-10px);
}

/* Member Image */
.cloudsynq-member-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1 / 1;
}

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

/* Member Overlay */
.cloudsynq-member-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cloudsynq-team-member:hover .cloudsynq-member-overlay {
    opacity: 1;
}

.cloudsynq-view-details {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 10px 20px;
    border: 2px solid #fff;
    border-radius: 25px;
    transition: all 0.3s ease;
}

.cloudsynq-view-details:hover {
    background: #fff;
    color: #333;
}

/* Member Info */
.cloudsynq-member-name {
    font-size: 18px;
    font-weight: 600;
    margin: 15px 15px 5px;
    color: #333;
    line-height: 1.2;
}

.cloudsynq-member-title {
    font-size: 14px;
    color: #666;
    margin: 0 15px 15px;
    line-height: 1.4;
}

/* Modal Styles */
.cloudsynq-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(3px);
    animation: fadeIn 0.3s ease;
}

.cloudsynq-modal.active {
    display: flex;
    align-items: center; /* vertical center */
    justify-content: center; /* horizontal center */
}

/* Lock page scroll while modal is open */
body.cloudsynq-modal-open,
html.cloudsynq-modal-open {
    overflow: hidden;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.cloudsynq-modal-content {
    background-color: #fff;
    margin: 15px;
    border-radius: 15px;
    width: 75vw; /* limit width to 75% of viewport */
    height: auto;
    max-width: 1200px;
    max-height: 75vh; /* limit height to 75% of viewport */
    overflow: hidden; /* constrain internal scroll to body area */
    display: flex;
    flex-direction: column;
    position: relative;
    animation: slideInUp 0.4s ease;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

@keyframes slideInUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Close Button */
.cloudsynq-modal-close {
    position: absolute;
    top: 20px;
    right: 25px;
    color: #666;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    transition: all 0.3s ease;
}

.cloudsynq-modal-close:hover {
    color: #000;
    background: #fff;
    transform: scale(1.1);
}

/* Modal Body */
.cloudsynq-modal-body {
    display: flex;
    padding: 40px;
    gap: 30px;
    overflow: auto; /* scroll inside content, not the whole screen */
    flex: 1 1 auto;
    min-height: 0; /* allow flex child to shrink for overflow to work */
}

.cloudsynq-modal-left {
    flex: 0 0 300px;
    text-align: center;
}

.cloudsynq-modal-right {
    flex: 1;
    min-width: 0;
}

.cloudsynq-modal-image {
    width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    margin: 0 auto;
    display: block;
}

/* Modal Text Content */
.cloudsynq-modal-name {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin: 0 0 10px 0;
    line-height: 1.2;
}

.cloudsynq-modal-credentials {
    font-size: 16px;
    color: #007cba;
    font-weight: 600;
    margin: 0 0 5px 0;
}

.cloudsynq-modal-title {
    font-size: 18px;
    color: #555;
    font-weight: 500;
    margin: 0 0 8px 0;
}

.cloudsynq-modal-location {
    font-size: 16px;
    color: #666;
    margin: 0 0 20px 0;
    font-style: italic;
}

.cloudsynq-modal-bio {
    margin: 20px 0 30px 0;
}

.cloudsynq-modal-bio p {
    font-size: 16px;
    line-height: 1.6;
    color: #444;
    margin: 0;
}

/* Modal Links */
.cloudsynq-modal-links {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 25px;
}

.cloudsynq-modal-links a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #f8f9fa;
    color: #333;
    text-decoration: none;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
}

.cloudsynq-modal-links a:hover {
    background: #007cba;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 124, 186, 0.3);
}

.cloudsynq-link-website:hover {
    background: #28a745;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.cloudsynq-link-linkedin:hover {
    background: #0077b5;
    box-shadow: 0 4px 15px rgba(0, 119, 181, 0.3);
}

.cloudsynq-link-email:hover {
    background: #dc3545;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .cloudsynq-team-gallery {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .cloudsynq-modal-body {
        flex-direction: column;
        padding: 30px;
    }
    
    .cloudsynq-modal-left {
        flex: none;
        max-width: 250px;
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    .cloudsynq-team-gallery {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .cloudsynq-modal-content {
        margin: 10px;
        border-radius: 10px;
        width: 90vw; /* on small screens, allow more width */
        max-height: 85vh;
    }
    
    .cloudsynq-modal-body {
        padding: 20px;
        gap: 20px;
    }
    
    .cloudsynq-modal-name {
        font-size: 24px;
    }
    
    .cloudsynq-modal-links {
        justify-content: center;
    }
    
    .cloudsynq-modal-links a {
        flex: 1;
        justify-content: center;
        min-width: 120px;
    }
}

@media (max-width: 480px) {
    .cloudsynq-team-gallery {
        grid-template-columns: 1fr;
    }
    
    .cloudsynq-modal-body {
        padding: 15px;
    }
    
    .cloudsynq-modal-close {
        top: 15px;
        right: 15px;
        width: 35px;
        height: 35px;
        font-size: 24px;
    }
    
    .cloudsynq-member-name {
        font-size: 16px;
    }
    
    .cloudsynq-member-title {
        font-size: 13px;
    }
}

/* Accessibility */
.cloudsynq-team-member:focus {
    outline: 2px solid #007cba;
    outline-offset: 2px;
}

.cloudsynq-modal-close:focus {
    outline: 2px solid #007cba;
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .cloudsynq-modal {
        display: none !important;
    }
} 