/* Homepage Enhanced Responsive Design */

/* Mobile-First Approach */
@media (max-width: 576px) {
    .container {
        padding: 0 10px;
    }
    
    .section-padding {
        padding: 30px 0;
    }
    
    .feature-card {
        padding: 1.5rem 1rem;
        margin-bottom: 1rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .stat-label {
        font-size: 0.9rem;
    }
    
    .team-member img {
        width: 100%;
        height: 250px;
        object-fit: cover;
        background-color: #f8f9fa;
    }
    
    .blog-card img {
        height: 150px;
    }
    
    .cert-item img {
        width: 80px;
        height: 80px;
    }
    
    .certification-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .service-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .team-grid,
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .department-section {
        padding: 1.5rem;
        margin: 1rem 0;
    }
    
    .member-card {
        padding: 1rem;
    }
    
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 2rem;
    }
    
    .btn-primary-custom {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

/* Tablet Styles */
@media (min-width: 577px) and (max-width: 768px) {
    .certification-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .service-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .team-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
}

/* Desktop Enhancements */
@media (min-width: 992px) {
    .service-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .team-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .certification-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Enhanced Hover Effects */
.feature-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 119, 182, 0.15);
}

.team-member {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.team-member:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.blog-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
}

/* Loading Animation */
.feature-card,
.team-member,
.blog-card {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.6s ease forwards;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Staggered Animation Delays */
.feature-card:nth-child(1) { animation-delay: 0.1s; }
.feature-card:nth-child(2) { animation-delay: 0.2s; }
.feature-card:nth-child(3) { animation-delay: 0.3s; }
.feature-card:nth-child(4) { animation-delay: 0.4s; }
.feature-card:nth-child(5) { animation-delay: 0.5s; }
.feature-card:nth-child(6) { animation-delay: 0.6s; }

.team-member:nth-child(1) { animation-delay: 0.1s; }
.team-member:nth-child(2) { animation-delay: 0.2s; }
.team-member:nth-child(3) { animation-delay: 0.3s; }
.team-member:nth-child(4) { animation-delay: 0.4s; }

/* Improved Typography */
.section-title {
    font-weight: 700;
    letter-spacing: -0.5px;
}

.lead {
    font-size: 1.15rem;
    font-weight: 400;
    line-height: 1.7;
}

/* Enhanced Social Icons */
.social-icons a {
    display: inline-block;
    width: 35px;
    height: 35px;
    background: #f8f9fa;
    border-radius: 50%;
    text-align: center;
    line-height: 35px;
    color: #0077b6;
    transition: all 0.3s ease;
    margin: 0 3px;
}

.social-icons a:hover {
    background: #0077b6;
    color: white;
    transform: translateY(-2px);
}

/* Improved Form Styling */
.newsletter form {
    background: white;
    border-radius: 25px;
    padding: 5px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.newsletter input {
    border: none;
    background: transparent;
    padding: 10px 15px;
}

.newsletter input:focus {
    outline: none;
    box-shadow: none;
}

.newsletter button {
    border-radius: 20px;
    padding: 8px 15px;
}

/* Enhanced Statistics Section */
.stats-section {
    position: relative;
    overflow: hidden;
}

.stats-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.1;
}

.stat-item {
    position: relative;
    z-index: 1;
}

/* Accessibility Improvements */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: #000;
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: 0 0 4px 4px;
    z-index: 10000;
}

.skip-link:focus {
    top: 0;
}

/* Print Styles */
@media print {
    .social-icons,
    .newsletter,
    .btn-primary-custom,
    .preview-banner {
        display: none !important;
    }
    
    .feature-card,
    .team-member,
    .blog-card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .stats-section {
        background: white !important;
        color: black !important;
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .feature-card {
        border: 2px solid #000;
    }
    
    .btn-primary-custom {
        border: 2px solid #000;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .feature-card,
    .team-member,
    .blog-card,
    .btn-primary-custom {
        transition: none;
        animation: none;
    }
    
    .feature-card:hover,
    .team-member:hover,
    .blog-card:hover {
        transform: none;
    }
}/*
 Team Section Enhancements */
.team-member {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.team-member:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.team-info {
    padding: 1.5rem;
    text-align: center;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.team-info h5 {
    color: #003f5c;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.team-info .text-muted {
    margin-bottom: 0.5rem;
}

.team-info .text-info {
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

.social-icons {
    margin-top: auto;
}

.social-icons a {
    display: inline-block;
    width: 35px;
    height: 35px;
    background: #f8f9fa;
    border-radius: 50%;
    text-align: center;
    line-height: 35px;
    color: #0077b6;
    transition: all 0.3s ease;
    margin: 0 3px;
    text-decoration: none;
}

.social-icons a:hover {
    background: #0077b6;
    color: white;
    transform: translateY(-2px);
}

/* Empty state styling */
.team-empty-state {
    text-align: center;
    padding: 3rem 2rem;
    background: #f8f9fa;
    border-radius: 12px;
    border: 2px dashed #dee2e6;
}

.team-empty-state .fa {
    font-size: 3rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

/* Responsive team grid adjustments */
@media (max-width: 576px) {
    .team-member img {
        height: 200px;
    }
    
    .team-info {
        padding: 1rem;
    }
    
    .social-icons a {
        width: 30px;
        height: 30px;
        line-height: 30px;
        font-size: 0.9rem;
    }
}

@media (min-width: 577px) and (max-width: 768px) {
    .team-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

@media (min-width: 769px) and (max-width: 991px) {
    .team-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 992px) {
    .team-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Ensure consistent height for team members */
.team-grid {
    display: grid;
    gap: 2rem;
    margin-top: 3rem;
}

.team-grid .team-member {
    min-height: 350px;
}