header {
  background-color: var(--background-color);
  border-bottom: 1px solid var(--header-border-color);
  height: 75px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: -webkit-fill-available;
  width: -moz-available;
  z-index: 1000;
  padding: 0 45px;
}

.sign-in{
  transition: opacity ease 0.175s;
  padding: 0 20px !important;
  height: 40px;
  margin: 0px !important; 
}
.sign-in:hover {
  opacity: 0.7;
} 

.logo-wrapper {
  display: flex;
  align-items: center;
  cursor: pointer;
  text-decoration: none;
  color: var(--test-color);
}

.logo-wrapper > h1 {
  margin: 0px;
  font-weight: 500;
  margin-left: 10px;
  font-size: 17px;
  margin-bottom: -2px;
}

.logo {
  width: 160px;
  height: 41px;
  transition: opacity 0.3s ease;
}

.logo:hover {
  opacity: 0.7;
}

.buttons-wrapper {
  display: grid;
  grid-auto-flow: column;
  grid-gap: 30px;
  height: 100%;
}

.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  outline: none;
  transition: transform 0.2s ease;
  margin: 0px;
}

.icon-toggle {
  font-size: 24px;
  display: none;
}

.sun-icon {
  display: var(--sun-display, none);
}

.moon-icon {
  display: var(--moon-display, none);
}

.language-selector-wrapper {
  position: relative;
  display: inline-block;
}

#language-selector {
  background-color: var(--background-color);
  border: 2px solid var(--hover-color);
  border-radius: 20px;
  padding: 10px 15px;
  font-size: 14px;
  color: var(--text-color);
  appearance: none;
  cursor: pointer;
  transition: border-color 0.3s ease;
  text-align: center;
}

#language-selector:focus {
  border-color: var(--active-color);
  outline: none;
}

.flag-icon {
  font-size: 20px;
}

@media (max-width: 1024px) {
  header {
    padding: 0 15px;
  }

  .buttons-wrapper {
    grid-gap: 15px;
  }

  .logo-wrapper > h1 {
    font-size: 18px;
  }

  .theme-toggle {
    width: 35px;
    height: 35px;
  }
}

@media (max-width: 790px) {
  .logo-wrapper > h1 {
    font-size: 18px;
    display: none;
  }
}

@media (max-width: 675px) {
  header {
    height: auto;
    padding: 10px;
    justify-content: center;
  }

  .center {
    display: flex;
    align-items: center;  
    justify-content: center;
    margin-right: -10px !important;
  }

  .sign-in {
    width: 80px;
    display: flex;
    align-items: center;  
    justify-content: center;
  }

  .logo-wrapper {
    width: 100%;
    margin-bottom: 10px;
    align-items: center;
    margin-bottom: 0;
  }

  .buttons-wrapper {
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
    gap: 5px;
    padding: 0;
  }

  .simple.button,
  .default.button {
    padding: 6px 10px;
    font-size: 12px;
    flex: 1;
    max-width: 120px;
    margin: 0px;
    
  }

  .theme-toggle {
    display: none;
    width: 30px;
    height: 30px;
    order: -1;
  }
}

@media (max-width: 576px) {
  header {
    height: auto;
    padding: 10px;
  }

  .buttons-wrapper {
    width: 100%;
    justify-content: center;
    gap: 5px;
    padding: 0;
  }

  .theme-toggle {
    width: 25px;
    height: 25px;
  }

  .logo-wrapper > h1 {
    font-size: 16px;
  }
}

.auth-wrapper {
  display: flex;
  align-items: center;
  position: relative;
}

.api-key-input {
  font-size: 14px;
  padding: 5px;
  background: #fd65654d;
  color: #fd6565;
  border: none;
  border-radius: 3px;
  outline: none;
  margin-right: 10px;
  transition: background 0.5s ease-in-out, color 0.5s ease-in-out;
}

.api-key-input.valid {
  background: none;
  color: inherit;
}

.api-key-input.invalid {
  background: white;
  color: black;
}

.icon-wrapper {
  margin-right: 10px;
}

.try-it-button {
  border-radius: 4px;
  text-decoration: none;
  cursor: pointer;
  opacity: 1;
  transition: opacity 0.3s ease;
}

.header-buttons {
  display: flex;
  align-items: center;
  height: 100%;
}

.header-buttons > *:last-child {
  margin-left: 16px;
}

.logo {
}
.logo-mobile {
  display: none !important;
}

.dropdown {
  position: relative;
  display: inline-block;
  height: 100%;
  display: flex;
  align-items: center;
  margin: 0 12px;
}

.dropdown-toggle{
  transition: opacity ease 0.175s;
}
.dropdown-toggle:hover {
  opacity: 0.7;
} 

.dropdown-toggle {
  background-color: var(--dropdown-toggle-color);
  color: #FFF;
  font-size: 17px;
  font-weight: 400;
  min-width: 85px;
  border: medium none;
  height: 40px;
  line-height: 40px;
  border-radius: 12px;
  display: inline-block;
  padding: 0 20px;
  text-decoration: none;
  border: var(--border-color-dropdown-toggle);
}

.dropdown-menu {
  display: none;
  position: absolute;
  background-color: var(--background-color);
  min-width: 160px;
  box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
  z-index: 1;
  border-radius: 4px;
  right: 0;
  top: 95%;
  margin-top: 2px;
  border: 1px solid var(--border-color);
  border-radius: 10px;
}

.dropdown-menu a {
  color: var(--text-color);
  padding: 12px 16px;
  text-decoration: none;
  display: block;
  text-align: left;
  transition: background-color 0.2s, color 0.2s;
}

.dropdown-menu a:hover {
  background-color: var(--hover-bg);
  color: var(--hover-color);
  border-radius: 10px;
}

.dropdown:hover .dropdown-menu {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

.dropdown:hover .dropdown-menu {
  animation: fadeIn 0.2s ease-out forwards;
}
@media (max-width: 420px) {
  .logo-wrapper {
    width: unset;
  }
  .logo {
    display: none !important;
  }

  .logo-mobile {
    display: block !important;
  }
}
