#menu ul {
  margin: 0;
  padding: 0;
}

.link-styling a {
  color:#0151A2;
}

.trigger-box-1 .link-styling a::after{
  margin-left:4px;
}


.trigger-box h5, .trigger-box p {
  font-size:16px;
  margin-bottom:10px;
}

.trigger-box a {
  padding-top:0:
}

.trigger-box {
  flex-direction:column;
  background-color:#f0f0f0;
  padding:20px;
}

.link-styling a {
  color:#0151A2!important;
}

.trigger-box .trigger-box-1 a, .trigger-box .trigger-box-2 a {
  padding:0 0!important;
  padding-top:0!important;
}

.open-menu-icon svg {
  margin-top: 5px;
}

#menu .open-menu-icon {
  display: block;
}
#menu .close-menu-icon {
  display: none;
}

#menu li .active {
  background-color: #f0f0f0; 
}

/* When the menu checkbox is checked, hide the open icon and show the close icon */
#tm:checked ~ label .open-menu-icon {
  display: none;
}
#tm:checked ~ label .close-menu-icon {
  display: block;
}

.main-menu .cf li {
  list-style:none;
}

#menu .main-menu {
  display: none;
}

#tm:checked + .main-menu {
  position: absolute;
  top: 93%;
  left: 0%;
  display: block;
  width: 100%;
  height: 100vh;
  background-color:#C1C1C1;
  color:#152331;
  overflow-y: auto;
  padding-bottom: 200px;
}

#menu input[type="checkbox"], 
#menu ul span.drop-icon {
  display: none;
}

#menu li, 
#toggle-menu, 

#menu li, 
#toggle-menu {
  border-width: 0 0 1px;
}

#menu .sub-menu {
  background-color: #C1C1C1;
  border-width: 1px 1px 0;
}

#menu .sub-menu li:last-child {
  border-width: 0;
}

#menu li, 
#toggle-menu, 
#menu a {
  position: relative;
  display: block;
  color: #152331;
}

#menu {
  background-color: transparent;
}

#toggle-menu {
  background: transparent;
}


#toggle-menu {
  padding: 10px 0;
}

#menu a {
  font-weight:500;
  padding: 10px 20px;
  transition: all .125s ease-in-out;
  -webkit-transition: all .125s ease-in-out;
}

.menu-depth-2 a:hover {
  color: #0151A2!important;
}

#menu .sub-menu {
  display: none;
}

#menu input[type="checkbox"]:checked + .sub-menu {
  display: block;
}

#menu .sub-menu a:hover {
  color: #444;
}

#toggle-menu .drop-icon {
  position: absolute;
  left: -6px;
  top: -4px;
  width: 73vh;
}

#menu li label.drop-icon {
  position: absolute;
  left: -6px;
  top: 2px;
  display: flex;
  justify-content: flex-end;
  width: 100%;
}


#menu input[type="checkbox"]:checked + label.drop-icon {
  position: absolute;
  right: 3px;
  top: -4px;
  width: 100vh;
  transform: rotate(179deg);
}

/* Apply the style when the 'active' class is present on the 'label' (if you're using JavaScript to toggle an active class) */
#menu li.active label.drop-icon {
  position: absolute;
  right: 3px;
  top: -4px;
  width: 100vh;
  transform: rotate(179deg);
}

#menu label.drop-icon, #toggle-menu span.drop-icon {
  padding: 1em;
  font-size: 1em;
  text-align: center;
  text-shadow: 0 0 0 transparent;
  color: #152331;
}

#menu a.active {
  color: #152331 
}

#menu label.drop-icon svg {
  transition: transform 0.3s ease;
}

@media only screen and (max-width: 1024px) { /* or whatever breakpoint you want */
  #menu label.drop-icon.is-active svg {
    transform: rotate(90deg);
  }
}

@media screen and (min-width:430px) {

}

@media only screen and (min-width: 1024px) {
  .menu-depth-1 .drop-icon svg path {
    stroke: #FFFFFF; /* White color */
  }

  .menu-depth-2 .drop-icon svg path,
  .menu-depth-3 .drop-icon svg path,
  .menu-depth-4 .drop-icon svg path {
    stroke: #152331;
  }

  #menu .sub-menu .menu-depth-2 .drop-icon{
    transform: rotate(359deg); 
  } 

  .fagstoff-inner,
  .logistikk-inner {
    position: relative;
    display: inline-block;
  }

  .fagstoff-badge,
  .logistikk-badge {
    position: absolute;
    top: -0px;
    right: -19px;
    width: 16px;
    height: 16px;
    background-color: yellow;
    color: black;
    font-size: 10px;
    font-weight: bold;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .logistikk-badge {
    top: 10px;
    right: 0px;
  }

  #menu .sub-menu .menu-depth-2 a {
    padding:5px 28px;
  }

  #menu .sub-menu {
    background-color:#F4F4F4;
  }

  #menu .main-menu {
    display: block;
  }

  #menu a {
    padding: 10px 7px 10px 30px;
  }

  #menu .menu-item .menu-depth-2 a {
    color: #152331;
  }

  #menu a, #menu li, #toggle-menu {
    color:#E8E8E8;
  }

  .header__container__black_text #menu a, #menu li, #toggle-menu {
    color:#152331;
  }

  .header__container__black_text .menu-depth-1 .drop-icon svg path {
    stroke: #152331;
  }

  #toggle-menu, 
  #menu label.drop-icon {
    display: none;
  }

  #menu ul span.drop-icon {
    display: inline-block;
    transform: rotate(90deg);
    margin-top: 3px;
  }

  #menu li {
    float: left;
    border-width: 0 1px 0 0;
    border-width: 0 1px 0 0;
    float: left;
    display: flex;
    align-items: center;
  }

  #menu li.active-branch > a{
    position: relative; 
    display: inline-block; 
  }

  #menu li.active > a {
    font-weight: 600;
  }

  .header-scrolled #menu .sub-menu li.active-branch > a::after {
    content: '';
    position: absolute;
    left: 23%;
    right: 0;
    bottom: 33%;
    height: 0.5em;
    background-color: #f4f4f4;
    z-index: -1;
    transform: translateY(50%);
  }

  #menu .sub-menu li.active-branch > a::after {
    content: '';
    position: absolute;
    left: 23%;
    right: 0;
    bottom: 33%; 
    height: 0.5em; 
    background-color: #f4f4f4; 
    z-index: -1; 
    transform: translateY(50%); 
  }

  .header_blue #menu li.active-branch > a::after {
    content: '';
    position: absolute;
    left: 23%;
    right: 0;
    bottom: 33%; 
    height: 0.5em; 
    background-color: #0151A2; 
    z-index: -1; 
    transform: translateY(50%); 
  }

  .header-scrolled #menu li.active-branch > a::after {
    content: '';
    position: absolute;
    left: 23%;
    right: 0;
    bottom: 33%; 
    height: 0.5em; 
    background-color: #0151A2; 
    z-index: -1; 
    transform: translateY(50%); 
  }

  #menu li.active-branch > a::after {
    content: '';
    position: absolute;
    left: 23%;
    right: 0;
    bottom: 33%; 
    height: 0.5em; 
    background-color: #e0e0e0; 
    z-index: -1; 
    transform: translateY(50%); 
  }


  #menu .sub-menu li {
    float: none;
  }

  #menu .sub-menu {
    border-width: 0;
    margin: 0;
    position: absolute;
    top: 100%;
    left: 0;
    width: 15em;
    z-index: 3000;
  }

  #menu .sub-menu, 
  #menu input[type="checkbox"]:checked + .sub-menu {
    display: none;
    padding: 13px 0;
  }

  #menu .sub-menu li {
    border-width: 0 0 1px;
  }

  #menu .sub-menu li:hover {
    background-color:#E4E4E4;
  }

  #menu .sub-menu .sub-menu {
    top: 0%;
    left: 100%;
    height: 100%;
  }

  #menu .menu-depth-2 > .sub-menu {
    border-left: 2px solid #152331; /* Add the right border to the submenu */
  }

  .drop-icon{
    position:relative;
  }

  #menu .sub-menu .drop-icon {
    position: absolute;
    right: 0;
    padding: 1em;
  }

  #menu li:hover > input[type="checkbox"] + .sub-menu {
    display: block;
  }

  .trigger-box {
    width: 470px;
    background-color: #f4f4f4;
    padding: 20px 30px;
    position: absolute;
    flex-direction:row;
    top: 100%;
    left: -112%;
    gap: 20px;
    justify-content:center;
  }

  #menu li label.drop-icon {
    display:none;
  }

  .trigger-box-1 p, .trigger-box-2 p {
    line-height:20px;
  }

  .trigger-box-1 {
    border-right:1px solid #707070;
    padding-right:20px;
    height: 100px;
  }

  .sub-menu li {
    position:static!important;
  }
}