header {
  background-color: #f40000;
  color: white;
  padding: clamp(5px, 3vw, 0px) 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  top: 0;
  width: 100%;
  box-sizing: border-box;
  overflow: visible;
  transition: transform 0.6s ease-out, opacity 0.6s ease-in-out, background-color 0.4s ease;
}
header img {
  height: clamp(40px, 8vw, 50px);
  margin-left: 15px;
  display: block;
  background-color: white;
  padding: 3px;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.4);
  border: 1px solid #ffffff;
}
.header-content img {
  transition: all 0.3s ease-in-out;
}
header h1 {
  font-size: clamp(0.8rem, 3.5vw, 2rem);
  margin: 0;
  padding: clamp(0px, 0.5vw, 5px) 0;
  text-align: center;
  flex-grow: 1;
}
.sticky-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: #f40000;
  z-index: 1000;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  height: auto;
  padding: 4px 0;
  transition: all 0.4s ease-in-out;
}
.sticky-header .header-content {
  display: none;
}
@media (max-width: 880px) {
  header {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    padding: clamp(8px, 1vw, 12px) 0;
  }
  .header-content {
    display: flex;
    justify-content: center;
  }
  header img {
    height: clamp(35px, 7vw, 50px);
    margin-bottom: 5px;
    margin-left: 0;
  }
}
@media (min-width: 881px) {
  header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    display: grid;
    grid-template-columns: 1fr;
    align-items: center;
  }

  .header-content,
  nav {
    grid-column: 1;
    grid-row: 1;
  }

  .header-content {
    justify-self: start;
    z-index: 10;
    position: relative;
  }

  nav {
    justify-self: center;
    z-index: 5;
  }

  .sticky-header {
    position: static;
  }

  .sticky-header .header-content {
    display: block;
  }
}
