/* ══════════════════════════════════════════════════
   NAV — sticky, 64px, clean white
══════════════════════════════════════════════════ */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 64px;
  background: #fff;
  box-shadow: 0 1px 0 #e5e5e5;
}

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

/* ── Logo ── */
.nav__logo {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #000;
  text-decoration: none;
  flex-shrink: 0;
  margin-right: 2.5rem;
}

/* ── Desktop nav list ── */
.nav__list {
  display: flex;
  align-items: center;
  gap: 2px;
  list-style: none;
  padding: 0;
  margin: 0 0 0 auto;
}

.nav__item { position: relative; }

/* ── Base link style (shared by <a> and <button> toggles) ── */
.nav__link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  font-size: 15px;
  font-weight: 450;
  color: #000;
  text-decoration: none;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.nav__link:hover { color: #22c55e; }

.nav__link.active {
  color: #22c55e;
  font-weight: 600;
}

/* ── Chevron ── */
.nav__chevron {
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

/* ══════════════════════════════════════════════════
   DROPDOWN
══════════════════════════════════════════════════ */
.nav__item--drop { position: relative; }

/* Rotate chevron on hover and when .open */
.nav__item--drop:hover .nav__chevron,
.nav__item--drop.open  .nav__chevron {
  transform: rotate(180deg);
}

.nav__drop-panel {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(-4px);
  background: #fff;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04);
  min-width: 240px;
  padding: 6px 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s;
  z-index: 200;
}

/* Invisible bridge over the hover gap */
.nav__drop-panel::before {
  content: '';
  position: absolute;
  top: -10px;
  left: 0;
  right: 0;
  height: 10px;
}

/* Show on hover (CSS) OR .open (JS click fallback) */
.nav__item--drop:hover .nav__drop-panel,
.nav__item--drop.open  .nav__drop-panel {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

/* ── Dropdown items ── */
.nav__drop-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 450;
  color: #000;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.12s ease;
}

.nav__drop-link:hover { background: #fafafa; }

.nav__drop-icon {
  font-size: 15px;
  flex-shrink: 0;
  width: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav__drop-icon img { display: block; }

/* Separator */
.nav__drop-sep {
  height: 1px;
  background: #e5e5e5;
  margin: 6px 0;
}

/* Custom Projekt entry */
.nav__drop-link--custom {
  background: #fafafa;
  color: #888;
  font-style: italic;
}

.nav__drop-link--custom:hover { background: #f0f0f0; }

/* ══════════════════════════════════════════════════
   ACTIONS: CTA + BURGER
══════════════════════════════════════════════════ */
.nav__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  margin-left: 32px;
}

.nav__cta {
  font-size: 14px;
  font-weight: 500;
  background: #000;
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  padding: 10px 20px;
  white-space: nowrap;
  transition: background 0.15s ease;
}

.nav__cta:hover { background: #22c55e; }

.nav__burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  padding: 6px;
  border: none;
  background: none;
  cursor: pointer;
  border-radius: 6px;
  transition: background 0.12s ease;
}

.nav__burger:hover { background: #f5f5f5; }

.nav__burger span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: #000;
  border-radius: 2px;
  transform-origin: center;
  transition: transform 0.22s ease, opacity 0.22s ease;
}

.nav__burger.open span:nth-child(1) { transform: translateY(6.5px)  rotate(45deg); }
.nav__burger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav__burger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ══════════════════════════════════════════════════
   MOBILE MENU — full-screen slide-in below nav
══════════════════════════════════════════════════ */
.nav__mobile {
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  bottom: 0;
  background: #fff;
  overflow-y: auto;
  padding: 1rem 1.25rem 2rem;
  z-index: 99;
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

.nav__mobile.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* Mobile list */
.nav__mob-list {
  list-style: none;
  padding: 0;
  margin: 0;
  flex: 1;
}

.nav__mob-item {
  border-bottom: 1px solid #f0f0f0;
}

.nav__mob-item:last-child { border-bottom: none; }

/* Mobile links + toggle buttons share base style */
.nav__mob-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 14px 4px;
  font-size: 16px;
  font-weight: 500;
  color: #000;
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  text-align: left;
  transition: color 0.12s ease;
}

.nav__mob-link:hover { color: #22c55e; }

.nav__mob-toggle.open .nav__chevron { transform: rotate(180deg); }

/* Mobile sub-menu (accordion) */
.nav__mob-sub {
  list-style: none;
  padding: 0;
  margin: 0 0 8px;
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.28s ease;
}

.nav__mob-sub.open { max-height: 480px; }

.nav__mob-sub-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  font-size: 14px;
  font-weight: 450;
  color: #555;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.12s ease, color 0.12s ease;
}

.nav__mob-sub-link:hover {
  background: #fafafa;
  color: #000;
}

/* Sub separator */
.nav__mob-sub-sep {
  height: 1px;
  background: #e5e5e5;
  margin: 6px 12px;
  list-style: none;
}

/* Custom Projekt in mobile sub */
.nav__mob-sub-link--custom {
  background: #fafafa;
  color: #888;
  font-style: italic;
}

.nav__mob-sub-link--custom:hover { background: #f0f0f0; }

/* Mobile CTA button */
.nav__mob-cta {
  display: block;
  text-align: center;
  margin-top: 1.5rem;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 500;
  background: #000;
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.15s ease;
}

.nav__mob-cta:hover { background: #22c55e; }

/* ══════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .nav__list,
  .nav__cta {
    display: none;
  }

  .nav__burger { display: flex; }
}
