/* General Styles */
body {
    font-family: Arial, sans-serif;
    background-color: #ffffff;
    margin: 0;
    padding: 0;
    text-align: center;
}

body.dark-mode > .team-section > h2 {
    color: white;
}

/* Header Section */
.header {
    background: #222;
    text-align: center;
    padding: 80px 0;
    font-size: 36px;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Team Section */
.team-section {
    text-align: center;
    padding: 30px 20px;
}

.team-section h2 {
    font-size: 28px;
    margin-bottom: 40px;
    color: #222;
    font-weight: 600;
}

/* Team Members Grid */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 30px;
    justify-content: center;
    align-items: center;
    padding: 20px;
    max-width: 1000px;
    margin: auto;
}

.team-tech {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-column: span 2;
    gap: 8  0px;
    justify-content: center; /* Ensures the grid is centered */
    align-items: center;
    padding: 20px;
    max-width: 650px; /* Adjust width for better centering */
    margin: auto;
}

/* Center last row when there's only one item */
.team-member:nth-child(7):nth-last-child(1) {
    grid-column: span 3;
    justify-self: center;
    margin-left: -20px;
}

/* Standardized Team Member */
.team-member {
    width: 240px;
    height: 327px;
    background: linear-gradient(135deg, #ffffff, #f8f8f8);
    padding: 25px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.team-member:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 25px rgba(0, 0, 0, 0.15);
}

/* Profile Picture */
.profile-pic {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #007bff;
    margin-bottom: 15px;
    transition: transform 0.3s ease;
}

.team-member:hover .profile-pic {
    transform: scale(1.1);
}

.dif-laurence {
    object-position: 50% 20%;
}

/* Name & Role */
.team-member h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 10px 0;
    color: #007bff;
}

.team-member p {
    font-size: 14px;
    color: #555;
}

body.dark-mode .team-member {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(25px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    box-shadow: inset 0 0 15px rgba(255, 255, 255, 0.1), 0 10px 25px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease-in-out;
  }

body.dark-mode .team-member p {
    color: white;
}
  
  body.dark-mode .team-member:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow:
      inset 0 0 12px rgba(255, 255, 255, 0.15),
      0 12px 30px rgba(0, 0, 0, 0.6);
    transform: translateY(-3px);
  }

/* Align 1 or 2 Profiles Correctly */
@media (max-width: 768px) {
    .team-grid {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
    }

    .team-member:nth-child(1) {
        margin-left: auto;
        margin-right: auto;
    }
    
  .team-section * {
    animation: none !important;
    transition: none !important;
  }

  .team-member:hover {
    transform: none !important;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1) !important;
  }

  .team-member:hover .profile-pic {
    transform: none !important;
  }
}
