/* Header styles for KIRIALI s.r.o.
   Builds on base.css; scoped to .vp-header namespace */

.vp-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #050b18;
  color: #ffffff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(12px);
}

.vp-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.vp-header__brand {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
}

.vp-header__logo-link {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: inherit;
}

.vp-header__logo-mark {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 0.8rem;
  background: linear-gradient(135deg, #1c3b72, #6e8bbf);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Playfair Display", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: 0.06em;
}

.vp-header__logo-text {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* Navigation */

.vp-header__nav {
  flex: 1 1 auto;
}

.vp-header__nav-list {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.vp-header__nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 0.95rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  letter-spacing: 0.02em;
  transition: color 0.18s ease-out;
}

.vp-header__nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, #4f7dd6, #7db3ff);
  transition: width 0.18s ease-out;
}

.vp-header__nav-link:hover,
.vp-header__nav-link:focus-visible {
  color: #ffffff;
}

.vp-header__nav-link:hover::after,
.vp-header__nav-link:focus-visible::after {
  width: 100%;
}

.vp-header__nav-link:focus-visible {
  outline: 2px solid #7db3ff;
  outline-offset: 2px;
  border-radius: 4px;
}

.vp-header__nav-item--highlight .vp-header__nav-link--cta {
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(125, 179, 255, 0.4);
  background: linear-gradient(135deg, rgba(79, 125, 214, 0.16), rgba(7, 20, 56, 0.08));
  color: #ffffff;
}

.vp-header__nav-item--highlight .vp-header__nav-link--cta::after {
  display: none;
}

.vp-header__nav-item--highlight .vp-header__nav-link--cta:hover,
.vp-header__nav-item--highlight .vp-header__nav-link--cta:focus-visible {
  border-color: rgba(125, 179, 255, 0.9);
  background: linear-gradient(135deg, rgba(79, 125, 214, 0.28), rgba(7, 20, 56, 0.34));
}

/* Mobile toggle */

.vp-header__toggle {
  display: none;
  position: relative;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: transparent;
  padding: 0;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.vp-header__toggle:focus-visible {
  outline: 2px solid #7db3ff;
  outline-offset: 2px;
}

.vp-header__toggle-bar {
  width: 1.3rem;
  height: 2px;
  border-radius: 99px;
  background: #ffffff;
  transition: transform 0.2s ease-out, opacity 0.2s ease-out, width 0.2s ease-out;
}

.vp-header__toggle-bar + .vp-header__toggle-bar {
  margin-top: 0.22rem;
}

/* When menu is open */

.vp-header--menu-open .vp-header__toggle-bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.vp-header--menu-open .vp-header__toggle-bar:nth-child(2) {
  opacity: 0;
  width: 0;
}

.vp-header--menu-open .vp-header__toggle-bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* Responsive behavior */

@media (max-width: 768px) {
  .vp-header__inner {
    padding-inline: 1rem;
  }

  .vp-header__toggle {
    display: inline-flex;
    flex-direction: column;
  }

  .vp-header__nav {
    position: absolute;
    inset-inline: 0;
    top: 100%;
    background: rgba(5, 11, 24, 0.98);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    transform-origin: top;
    transform: scaleY(1);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.22s ease-out;
  }

  .vp-header__nav-list {
    flex-direction: column;
    align-items: flex-start;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0.5rem 1rem 1rem;
    gap: 0.25rem;
  }

  .vp-header__nav-link {
    width: 100%;
    padding-block: 0.5rem;
  }

  .vp-header__nav-item--highlight .vp-header__nav-link--cta {
    width: 100%;
    justify-content: center;
  }

  .vp-header--menu-open .vp-header__nav {
    max-height: 18rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .vp-header__nav-link,
  .vp-header__toggle-bar,
  .vp-header__nav {
    transition: none !important;
  }
}