nav {
    align-items: center;
    background-color: var(--secondary);
    /* background: linear-gradient(90deg,rgba(255, 220, 175, 1) 0%, rgba(255, 192, 200, 1) 50%, rgba(255, 253, 254, 1) 100%); */
    border-right: 2px solid var(--highlight);
    border-radius: 8px 0px 0px 60px;
    display: flex;
    filter: drop-shadow(1px 2px 3px var(--text));
    justify-content: space-between;
    position: fixed;
    transition: all 0.1s ease-in-out;
    right: 0;
    z-index: 100;
}
nav ul {
    align-items: center;
    display: flex;
    gap: 2px;
    height: 5em;
    justify-content: flex-end;
    list-style: none;
    margin: 0;
    padding-left: 0;
    padding-right: 1em;
    position:relative;
}
nav li {
    border: 2px solid transparent;
    border-radius: 12px;
    cursor: pointer;
    position: relative;
    text-align: center;
    transition: all 0.25s ease-in-out;
}
nav li > a {
    color: var(--text);
    display: block;
    font-family: 'Bodoni Moda', Verdana, sans-serif;
    font-size: calc(1em + 0.25vw);
    font-weight: bold;
    padding: 12px;
    text-decoration: none;
    transition: all 0.25s ease-in-out;
}
nav > a:first-child {
    display: flex;
    font-size: 1em;
}
nav li:hover > a {
    color: var(--primary);
}
.nav-highlight {
    background-color: var(--secondary);
    border: 2px solid var(--background);
    border-radius: 10px;
    transition: all 0.25s ease-in-out;
}
.nav-highlight a {
    color: var(--background);
}
.nav-highlight:hover {
    background-color: var(--background);
    border-color: var(--secondary);
}
.nav-highlight:hover a {
    color: var(--secondary);
}
.nav-logo {
    height: 6em;
}

.nav-submenu-header {
    align-items: center;
    border-radius: 0px;
    cursor: default;
    display: flex;
    position: relative
}
.nav-submenu-header:hover {
    border-bottom: 2px solid var(--highlight);
}

.nav-submenu-header span {
    color: var(--primary);
    display: block;
    font-family: 'Bodoni Moda', Verdana, sans-serif;
    font-size: 2em;
    padding-top: 3px;
}

.nav-submenu-header > img {
    padding: 0.25em;
    transform: rotate(0deg);
    transition: all 0.35s;
    width: 1.25em;
}

.nav-submenu-header:hover > img {
    transform: rotate(180deg)
}

.nav-submenu {
    align-items: end;
    background-color: var(--secondary);
    border-right: 2px solid var(--highlight);
    border-top: 2px solid var(--highlight);
    clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
    display: none;
    flex-direction: column;
    gap: 0;
    height: unset;
    margin: 0;
    padding: 1em 0em 1em 1em;
    position: absolute;
    right: -2px;
    top: calc(100% + 2px);
    transition: display 0.3s allow-discrete, opacity 0.2s ease, clip-path 0.2s ease;
    width: fit-content;
    z-index: 10;
}


.nav-submenu li {
    margin-right: 1em;
    text-align: right;
    white-space: nowrap;
}
.nav-submenu li > a {
    color: var(--text);
    padding-right: 0.5em;
}

.nav-submenu-header:hover .nav-submenu {
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    display: flex;
}
@starting-style {
  .nav-submenu-header:hover .nav-submenu {
    clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
  }
}

.burger-wrapper {
    position: absolute;
    right: 0;
    top: 0;
}
.nav-burger {
    color: var(--background);
    cursor: pointer;
    display: none;
    filter: drop-shadow(0px 0px 1px black);
    height: 4em;
    position: relative;
    width: 4em;
    margin-left: auto;
}
.nav-burger:hover {
    color: var(--background);
}
.nav-burger span {
    background-color: currentColor;
    display: block;
    height: 2px;
    left: calc(50% - 8px);
    position: absolute;
    transform-origin: center;
    transition-duration: 86ms;
    transition-property: background-color, opacity, transform;
    transition-timing-function: ease-out;
    width: 24px;
}
.nav-burger span:nth-child(1) {
    top: calc(50% - 6px);
}
.nav-burger span:nth-child(2) {
    top: calc(50% - 1px);
}
.nav-burger span:nth-child(3) {
    top: calc(50% + 4px);
}
.nav-burger.is-active span:nth-child(1) {
  transform: translateY(5px) rotate(45deg);
}
.nav-burger.is-active span:nth-child(2) {
  opacity: 0;
}
.nav-burger.is-active span:nth-child(3) {
  transform: translateY(-5px) rotate(-45deg);
}
@media screen and (max-width: 960px){
    nav {
        align-items: center;
        border-radius: 0;
        border-right: none;
        flex-direction: column;
        height: 100%;
        justify-content: flex-start;
        max-height: 4em;
        width: 100%;
    }
    nav > a:first-child {
        margin-left: 0;
        margin-right: auto;
        padding: 0;
        width: 200px;
    }
    nav.is-active {
        max-height: 100vh;
        overflow-y: scroll;
    }
    nav ul {
        align-items: flex-start;
        animation-name: none;
        clip-path: none;
        display: none;
        flex-direction: column;
        gap: 12px;
        height: unset;
        justify-content: flex-start;
        padding: 1em;
    }
    nav > ul::before { 
        display: none;
    }
    nav.is-active ul {
        display: flex;
        order: 2;
    }
    .nav-logo {
        height: 4em;
    }
    .nav-burger {
        display: block;
    }
    .nav-highlight {
        order: 1;
    }
    nav li:hover {
        border-color: transparent;
    }
    .nav-submenu-header {
        align-items: start;
        flex-direction: column;
    }
    .nav-submenu-header > img {
        display: none;
    }
    .nav-submenu-header:hover > img {
        transform: rotate(0deg);
    }
    .nav-submenu-header>span {
        font-size: 1.5em;
    }
    .nav-submenu {
        align-items: flex-start;
        background-color: unset;
        border-bottom: none;
        border-left: 1px dotted var(--primary);
        border-right: none;
        border-top: none;
        box-shadow: none;
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
        display: flex;
        margin-top: 12px;
        padding: 0;
        position: initial;
    }

    .nav-submenu li {
        border-right: none;
        margin-left: 0.5em;
        padding-right: 0;
        white-space: normal;
    }
    .nav-submenu li > a {
        padding-right: 0.5em;
        text-align: left;
    }
}