header {
  display: flex;
  flex-direction: column;
  background: linear-gradient(135deg, #1b3354 0%, #284f78 60%, #2e5c8a 100%);
  border-bottom: 2px solid rgba(255, 255, 255, 0.16);
  color: var(--text-light);
  padding: 0.75rem 1.75rem 0.5rem;
  position: relative;
  box-shadow: 0 12px 30px rgba(10, 25, 45, 0.25);
}

.header-content {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.header-auth-row {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  width: 100%;
  margin-bottom: 0.35rem;
  min-height: 1.75rem;
}

.header-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-bottom: 0.75rem;
  position: relative;
}

.header-top-row a {
  display: flex;
  align-items: center;
}

.header-logo-link {
  display: flex;
  align-items: center;
}

.header-logo {
  height: 5.5rem;
  width: auto;
  margin-right: 1rem;
  transition: opacity 0.3s ease;
}

.header-logo:hover {
  opacity: 0.9;
}

.header-title-link {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  color: var(--text-light);
  z-index: 1;
}

.header-title-link h1 {
  margin: 0;
  font-size: 1.65rem;
  font-weight: 600;
  text-align: center;
  letter-spacing: -0.01em;
}

.header-title-link:hover {
  text-decoration: underline;
}

.header-auth-section {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.header-user {
  font-size: 0.9rem;
  color: var(--text-light);
  padding: 0.25rem 0;
}

.header-auth-button {
  text-decoration: none;
  color: var(--text-light);
  font-size: 0.9rem;
  padding: 0.35rem 0.85rem;
  background-color: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  transition: all 0.3s ease;
}

.header-auth-button:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.55);
}

.header-buttons {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}

.header-button {
  text-decoration: none;
  color: var(--text-light);
  font-size: 1rem;
  padding: 0.55rem 1.15rem;
  background-color: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  transition: all 0.3s ease;
  display: inline-block;
  position: relative;
  white-space: nowrap;
}

.header-button:hover {
  background-color: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.42);
  text-decoration: none;
}

.header-button:not(:last-child) {
  border-right: none;
}

@media (max-width: 720px) {
  header {
    padding: 0.75rem 1rem 0.75rem;
  }

  .header-top-row {
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
  }

  .header-title-link {
    position: static;
    transform: none;
    order: 2;
  }

  .header-top-row a {
    justify-content: center;
  }

  .header-logo {
    margin-right: 0;
    height: 4.8rem;
  }
}