@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');

:root {
    --primary-navy: #ffffff;
    --accent-blue: #38bdf8;
    --bg-light: #0f172a;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: var(--bg-light);
    background-image: url('WEB_BG.png');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: #ffffff;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow-x: hidden;
}

/* --- Navigation Bar Styles --- */
.navbar {
    width: 100%;
    background-color: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.2rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo-img {
    height: 35px;
    width: auto;
    display: block;
}

.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    color: #ffffff;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
}

.nav-wrapper {
    display: flex;
    align-items: center;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    padding-bottom: 0.25rem;
    transition: color 0.2s ease, border-bottom 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff;
    border-bottom: 2px solid #ffffff;
}

.nav-icon {
    font-size: 0.75rem;
}

/* Dropdown Menu Styles */
.dropdown {
    position: relative;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    list-style: none;
    min-width: 200px;
    padding: 0.5rem 0;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    z-index: 101;
}

.dropdown:hover .dropdown-menu {
    display: block;
}

.dropdown-menu li a {
    display: block;
    padding: 0.6rem 1.2rem;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.85rem;
    transition: background 0.2s ease, color 0.2s ease;
}

.dropdown-menu li a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--accent-blue);
}

/* --- Main Container & Layout --- */
.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 3rem 2rem;
    position: relative;
    z-index: 1;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* --- Hero Title Section --- */
.portal-header {
    width: 100%;
    max-width: 900px;
    margin: 0 auto 3rem auto;
    text-align: center;
}

.portal-header.center-header {
    max-width: 900px;
    text-align: center;
    margin: 0 auto 3rem auto;
}

/* Montserrat Header Title */
.portal-header h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 3.2rem;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: 1.5px;
    color: var(--primary-navy);
    text-transform: uppercase;
    margin-bottom: 0.75rem;
    text-align: center;
}

/* Times New Roman Subtext & Description */
.portal-header p,
.description-dropdown p {
    font-family: 'Times New Roman', Times, serif !important;
    font-style: italic;
    font-size: 0.95rem !important;
    color: rgba(255, 255, 255, 0.85);
    text-align: center;
    line-height: 1.6;
}

.description-dropdown {
    width: 100%;
    max-width: 900px;
    margin: 1rem auto 0 auto;
    text-align: center;
}

.description-dropdown summary::-webkit-details-marker {
    display: none;
}

.description-dropdown summary {
    font-family: 'Montserrat', sans-serif;
    list-style: none;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    cursor: pointer;
    padding: 0.5rem 1.25rem;
    border: 1.5px solid rgba(255, 255, 255, 0.6);
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.6);
    color: #ffffff;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: all 0.3s ease;
    user-select: none;
}

.description-dropdown summary:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: #ffffff;
}

.description-dropdown summary .toggle-icon {
    font-size: 0.75rem;
    transition: transform 0.3s ease;
}

.description-dropdown[open] summary .toggle-icon {
    transform: rotate(180deg);
}

.description-dropdown p {
    margin-top: 1.2rem;
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Section Title Styles --- */
.team-section {
    width: 100%;
    margin-bottom: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.section-title {
    text-align: center;
    margin-bottom: 2.5rem;
}

/* Montserrat Section Heading */
.section-title h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    color: #ffffff;
    text-transform: uppercase;
    text-align: center;
}

.title-underline {
    width: 80px;
    height: 3px;
    background-color: #ffffff;
    margin: 0.5rem auto 0;
    border-radius: 2px;
}

/* --- Centered 4-Card Layout & Interactive Hover Behavior --- */
.team-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    width: 100%;
    max-width: 780px;
    margin: 0 auto;
}

.member-card {
    flex: 0 1 calc(50% - 1rem);
    min-width: 280px;
    max-width: 360px;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(12px);
    border: 1.5px solid rgba(255, 255, 255, 0.25);
    border-radius: 16px;
    padding: 0;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), 
                border-color 0.35s ease, 
                box-shadow 0.35s ease;
}

.member-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent-blue);
    box-shadow: 0 18px 35px rgba(0, 0, 0, 0.6), 0 0 15px rgba(56, 189, 248, 0.2);
}

.member-photo-frame {
    width: 100%;
    height: 360px;
    border-radius: 14px;
    overflow: hidden;
    position: relative;
    background: #1e293b;
}

.member-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.member-card:hover .member-photo {
    transform: scale(1.05);
}

.member-badge {
    position: absolute;
    bottom: 12px;
    left: 12px;
    right: 12px;
    z-index: 2;
    background: rgba(15, 23, 42, 0.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    padding: 0.75rem 0.9rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    transition: border-color 0.35s ease, background 0.35s ease;
}

.member-card:hover .member-badge {
    border-color: rgba(56, 189, 248, 0.6);
    background: rgba(15, 23, 42, 0.95);
}

.member-details {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    overflow: hidden;
}

/* Montserrat Member Name */
.member-name {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.82rem;
    font-weight: 800;
    color: #ffffff !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0;
}

/* Times New Roman Member Role */
.member-role {
    font-family: 'Times New Roman', Times, serif;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
    font-style: italic;
    white-space: nowrap;
}

/* --- Responsive Breakpoints --- */
@media (max-width: 1024px) {
    .nav-container {
        padding: 0.8rem 1.25rem !important;
        position: relative !important;
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
    }

    .mobile-menu-toggle {
        display: block !important;
        z-index: 1002;
    }

    .nav-wrapper {
        display: none !important;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: rgba(15, 23, 42, 0.98);
        backdrop-filter: blur(12px);
        border-bottom: 1px solid rgba(255, 255, 255, 0.15);
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
        z-index: 1001;
    }

    .nav-wrapper.active {
        display: block !important;
    }

    .nav-menu {
        display: flex !important;
        flex-direction: column !important;
        padding: 1.5rem !important;
        gap: 1.25rem !important;
        align-items: flex-start !important;
        width: 100%;
        list-style: none;
    }

    .nav-menu li {
        width: 100%;
    }

    .nav-menu li a {
        display: block;
        width: 100%;
    }

    .dropdown-menu {
        position: static;
        display: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        background-color: rgba(255, 255, 255, 0.05);
        box-shadow: none;
        border: none;
        margin-top: 0.5rem;
        padding-left: 1rem;
    }

    .dropdown:hover .dropdown-menu {
        display: block;
    }

    .member-card {
        flex: 0 1 calc(50% - 1.5rem);
    }

    .portal-header h1 {
        font-size: 2.8rem;
    }

    .container {
        padding: 2rem 1.25rem;
    }
}

@media (max-width: 768px) {
    .member-card {
        flex: 0 1 100%;
        max-width: 380px;
    }

    .portal-header h1 {
        font-size: 2.2rem;
    }
}