:root {
    --color-primary: #0FA4AF;
    --color-secondary: #024950;
    --color-accent: #964734;
    --color-bg: #AFDDE5;
    --color-bg-tint: #AFDDE5;
    --color-bg-mid: #AFDDE5;
    --gradient-primary: linear-gradient(135deg, #0FA4AF, #024950);
    --gradient-accent: linear-gradient(90deg, #003135, #024950, #0FA4AF);
}

/* Prevent header shift from scrollbar */
html {
    overflow-y: scroll;
}

/* HEADER */
header {
    background: rgba(255, 255, 255, 0.97);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06), 0 2px 12px rgba(0, 0, 0, 0.04);
    padding: 14px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    width: 100%;
    box-sizing: border-box;
    height: 70px;
    transition: none;
}

header .logo {
    display: flex;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s;
    text-decoration: none;
}

header .logo img {
    display: block;
    border: none;
    background: transparent;
}

header .logo:hover {
    transform: scale(1.05);
}

nav {
    display: flex;
    gap: 8px;
    align-items: center;
}

nav a {
    padding: 8px 16px;
    text-decoration: none;
    font-size: 14px;
    color: #374151;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.3s ease;
}

nav a:hover {
    background: rgba(15, 164, 175, 0.08);
    color: var(--color-primary);
}

nav a.active {
    background: rgba(15, 164, 175, 0.12);
    color: var(--color-primary);
    font-weight: 600;
}

nav a strong {
    color: var(--color-primary);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 22px;
    color: var(--color-primary);
    cursor: pointer;
    padding: 8px;
    transition: all 0.2s;
}

.mobile-menu-btn:hover {
    transform: scale(1.1);
}

.mobile-menu-btn:active {
    transform: scale(0.95);
}

.mobile-nav {
    display: none;
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    max-width: 85vw;
    height: 100vh;
    max-height: 100vh;
    background: white;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
    z-index: 2000;
    transition: right 0.3s ease;
    padding: 80px 20px 20px;
    overflow-y: auto;
}

.mobile-nav.active {
    right: 0;
}

.mobile-nav a {
    display: block;
    padding: 16px 20px;
    text-decoration: none;
    color: #374151;
    font-weight: 500;
    border-radius: 8px;
    margin-bottom: 8px;
    transition: all 0.3s ease;
    font-size: 16px;
}

.mobile-nav a:hover,
.mobile-nav a:active {
    background: rgba(15, 164, 175, 0.08);
    color: var(--color-primary);
}

.mobile-nav a.active {
    background: rgba(15, 164, 175, 0.12);
    color: var(--color-primary);
    font-weight: 600;
}

.mobile-nav a strong {
    color: var(--color-primary);
}

.mobile-nav-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(15, 164, 175, 0.1);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
}

.mobile-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1999;
}

.mobile-overlay.active {
    display: block;
}

/* User Profile & Dropdown */
.user-profile-container {
    position: relative;
    display: none;
}

.user-profile-container.active {
    display: block;
}

.profile-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: white;
    border: none;
    cursor: pointer;
    font-weight: 700;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(15, 164, 175, 0.2);
}

.profile-icon:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(15, 164, 175, 0.3);
}

.profile-dropdown {
    position: absolute;
    top: 55px;
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    min-width: 220px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    border: 1px solid rgba(175, 221, 229, 0.8);
}

.profile-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.profile-dropdown-header {
    padding: 16px;
    border-bottom: 1px solid rgba(175, 221, 229, 0.8);
}

.profile-dropdown-name {
    font-weight: 600;
    color: #1f2937;
    font-size: 14px;
    margin-bottom: 4px;
}

.profile-dropdown-email {
    font-size: 12px;
    color: #6b7280;
    word-break: break-all;
}

.profile-dropdown-item {
    padding: 12px 16px;
    color: #374151;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
}

.profile-dropdown-item:hover {
    background: rgba(15, 164, 175, 0.06);
    color: var(--color-primary);
}

.profile-dropdown-item.admin-button {
    color: var(--color-primary);
    font-weight: 600;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    margin-bottom: 4px;
}

.profile-dropdown-item.admin-button:hover {
    background: rgba(15, 164, 175, 0.08);
}

/* Mobile profile styles */
.mobile-profile-section {
    display: none;
    padding: 20px;
    border-bottom: 2px solid rgba(0, 0, 0, 0.08);
    margin-bottom: 16px;
}

.mobile-profile-section.active {
    display: block;
}

.mobile-profile-info {
    margin-bottom: 16px;
}

.mobile-profile-name {
    font-weight: 700;
    color: var(--color-primary);
    font-size: 18px;
    margin-bottom: 4px;
}

.mobile-profile-email {
    font-size: 14px;
    color: #6b7280;
}

.mobile-profile-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.mobile-mentee-btn,
.mobile-mentor-btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mobile-mentee-btn:hover,
.mobile-mentor-btn:hover {
    box-shadow: 0 4px 12px rgba(15, 164, 175, 0.3);
    transform: translateY(-2px);
}

.mobile-admin-btn {
    width: 100%;
    padding: 12px;
    background: var(--color-primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mobile-admin-btn:hover {
    background: #0FA4AF;
    box-shadow: 0 4px 12px rgba(15, 164, 175, 0.2);
}

.mobile-logout-btn {
    width: 100%;
    padding: 12px;
    background: #dc2626;
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mobile-logout-btn:hover {
    background: #b91c1c;
}

.auth-links.hidden {
    display: none;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
    header {
        padding: 14px 20px;
    }

    nav {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    /* Enable mobile navigation */
    .mobile-nav {
        display: block;
    }

    /* Enable mobile overlay */
    .mobile-overlay {
        display: block;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s ease;
    }

    .mobile-overlay.active {
        display: block;
        opacity: 1;
        pointer-events: auto;
    }

    /* Show user profile icon on mobile */
    .user-profile-container {
        display: block !important;
    }

    .user-profile-container.active {
        display: block !important;
    }
}

@media (max-width: 768px) {
    header {
        padding: 12px 18px;
        height: 65px;
    }

    header .logo img {
        height: 36px;
    }

    .profile-icon {
        width: 36px;
        height: 36px;
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    header {
        padding: 10px 16px;
        height: 60px;
    }

    header .logo img {
        height: 32px;
    }

    .profile-icon {
        width: 34px;
        height: 34px;
        font-size: 14px;
    }

    .mobile-nav {
        width: 280px;
        max-width: 85vw;
        right: -100%;
    }
}