@import 'shared/variables.css';

/* Header */
.header {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 999;
    background: linear-gradient(to right, var(--background-color-left), var(--background-color-right));
    padding: 10px;
    align-items: center;
}

.nav-elements {
    display: flex;
    justify-content: flex-end;
    flex-grow: 1;
}

.home {
    display: flex;
    align-items: center;
}

.home img {
    width: 30px;
    margin-right: 10px;
}

.header ul {
    display: flex;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
}

.header ul li {
    margin: 0 12px;
    padding: 9px;
    border-bottom: 1.5px solid transparent;
    transition: border-bottom 0.3s ease;
}

.header ul a {
    color: var(--text-color-1);
    font-weight: 500;
    font-family: var(--font);
    font-size: var(--font-size-1);
    text-decoration: none;
    transition: color 0.3s ease;
}

.header ul a:hover {
    color: var(--text-color-1-hover);
}

.header ul li:hover {
    border-bottom: 1.5px solid var(--text-color-1-hover);
}

.theme-icon {
    font-size: var(--font-size-nav-icon);
    color: var(--text-color-1);
    cursor: pointer;
    transition: color 0.3s ease;
}

.theme-icon:hover {
    color: var(--text-color-1-hover);
}

/* Burger Menu for Mobile */
.burger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 30px;
    cursor: pointer;
    z-index: 1001;
    transition: all 0.3s ease-in-out;
}

.burger-menu div {
    width: 100%;
    height: 4px;
    background-color: var(--text-color-1);
    border-radius: 5px;
    transition: all 0.3s ease-in-out;
}

/* Cross Transformation */
.burger-menu.open div:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.burger-menu.open div:nth-child(2) {
    opacity: 0;
    transform: translateX(-80px);
}

.burger-menu.open div:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}



@media (max-width: 900px) {
    .nav-elements {
        display: none;
    }

    .nav-elements.active {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 60px;
        right: 0;
        width: 100%;
        background-color: var(--background-color-left);
    }

    .nav-elements ul {
        flex-direction: column;
        padding: 10px;
    }

    .nav-elements ul li {
        margin: 10px 0;
    }

    .burger-menu {
        display: flex;
        /* Show burger menu in mobile */
    }

    .home {
        display: flex;
        align-items: center;
    }

    .home img {
        width: 20px;
    }
}