.navbar {
    position: fixed;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    padding: 0 2vw;
    top: 15px;
    z-index: 1000;
    width: 100%;
    height: auto;
    margin-top: -2vh;
}

.wrapper {
    width: clamp(33rem, 43vw, 43rem);
    height: clamp(25rem, 33vw, 33rem);
    position: absolute;
    top: 0;
    left: 0;
    margin-left: -16rem;
    margin-top: -18rem;
    background: #000;
    border-radius: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    transform-origin: left top;
    z-index: -100;
}

.logo {
    height: clamp(180px, 14vw, 280px);
    z-index: 10000;
    position: absolute;
    margin-top: 280px;
    margin-left: 140px;
    transition: transform 1.6s ease-out, filter 1.6s ease-out;
}

.logo:hover {
    transform: scale(1.1) rotate(20deg);
    filter: brightness(1.2) contrast(1.5);
    animation: pulse 1.5s infinite alternate;
}

.navbar-left {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
}

.navbar-right {
    display: flex;
    flex-wrap: wrap;
    gap: clamp(10px, 2vw, 20px);
    justify-content: flex-end;
    align-items: center;
    flex: 1 1 auto;
    min-width: 0;
    margin-left: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: clamp(160px, 12vw, 220px);
    height: clamp(45px, 7vh, 70px);
    gap: 12px;
    border-radius: 50px;
    padding: 12px 12px 12px 12px;
    font-size: clamp(0.8rem, 1.1vw, 1.2rem);
    font-weight: bold;
    letter-spacing: 2px;
    background-color: rgba(255, 255, 255, 0.5);
    color: #1e1e1e;
    text-shadow: none;
    transition: transform 0.25s ease, border 0.25s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    will-change: transform;
    position: relative;
    margin-top: 2vw;
    font-family: "Outfit";
    flex-shrink: 0;
}

.nav-item span {
    display: block;
}

.nav-item:hover {
    transform: scale(1.07);
}

.JezikAInje {
    background-color: #e44f8a;
    color: black;
}

.Kalkulator {
    background-color: #f8bbd0;
    color: black;
}

.Znanstvenjak {
    background-color: #5fc9f8;
    color: black;
}

.Shramba {
    background-color: #35af60;
    color: black;
}

.Ekipa {
    background-color: #ffffff;
    color: black;
}

.nav-item img {
    height: clamp(20px, 2vw, 28px);
    width: clamp(20px, 2vw, 28px);
    filter: drop-shadow(0 0 4px rgba(0, 0, 0, 0.4));
    transition: transform 0.3s ease;
}

#coloured-egg {
    height: clamp(30px, 4vw, 50px);
    width: clamp(30px, 4vw, 50px);
    border-radius: 50%;
    transition: transform 0.3s ease;
}

#coloured-egg:hover {
    transform: scale(1.1);
}

.icon-wrapper {
    background-color: #000000;
    border-radius: 100%;
    width: clamp(24px, 2.5vw, 38px);
    height: clamp(24px, 2.5vw, 38px);
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    right: 10px;
    box-shadow: none;
    transition: box-shadow 0.3s ease;
}

.icon-wrapper:hover {
    box-shadow: none;
    animation: rotateIcon 0.6s ease-in-out;
}

@keyframes rotateIcon {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

@media only screen and (max-width: 768px) {
    .navbar-left {
        display: none;
    }

    .navbar-right {
        justify-content: center;
    }

    .icon-wrapper {
        background: none;
        right: auto;
    }

    .nav-item {
        padding: 5px 5px 5px 5px;
        width: 17%;
        height: clamp(25px, 4vh, 50px);
        justify-content: center;
        margin-top: 0;
    }

    .navbar {
        margin-top: 0.2vh;
    }


    .nav-item span {
        display: none;
    }
}

@media only screen and (min-width: 768px) {
    .navbar-left {
        display: none;
    }

    .nav-item {
        padding: 8px 8px 8px 8px;
        width: clamp(110px, 8vw, 140px);
        height: clamp(25px, 4vh, 50px);
        justify-content: center;
    }

    .navbar {
        margin-top: 0.2vh;
    }

    .navbar-right {
        justify-content: center;
    }

    .icon-wrapper {
        background: none;
        right: auto;
    }

    .nav-item span {
        display: none;
    }
}

@media only screen and (min-width: 880px) {
    .navbar-left {
        display: none;
    }

    .nav-item {
        padding: 8px 8px 8px 8px;
        width: clamp(120px, 8vw, 140px);
        height: clamp(35px, 4vh, 60px);
        justify-content: center;
    }

    .navbar {
         margin-top: 0.2vh;
     }

    .navbar-right {
        justify-content: center;
    }

    .icon-wrapper {
        background: none;
        right: auto;
    }

    .nav-item span {
        display: none;
    }
}

@media only screen and (min-width: 992px) {
    .navbar-left {
        display: flex;
    }

    .nav-item {
        padding: 5px 5px 5px 10px;
        width: clamp(140px, 14vw, 220px);
        height: clamp(45px, 4vh, 70px);
        justify-content: left;
    }

    .navbar {
        margin-top: -2vh;
    }

    .nav-item span {
        display: block;
    }

    .navbar {
        margin-top: 0.2vh;
    }

    .navbar-right {
        justify-content: flex-end;
    }

    .icon-wrapper {
        background: #000000;
        right: 10px;
    }
}

@media only screen and (min-width: 1200px) {
    .navbar-left {
        display: flex;
    }

    .nav-item {
        padding: 12px 12px 12px 20px;
        width: clamp(160px, 14vw, 220px);
        height: clamp(45px, 7vh, 70px);
        justify-content: left;
    }

    .navbar {
        margin-top: -2vh;
    }

    .nav-item span {
        display: block;
    }
}
