/* ============================================================
   HEADER — Layout, Swap, Grain
============================================================ */

:root {
  --header-height: 60px !important;
}

/* BASE */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  border-bottom: 1px solid transparent;

  padding: 32px 0;

  display: flex;
  align-items: center;

  z-index: 1000;
  transition:
    background .35s ease,
    border-color .35s ease,
    padding .35s ease;
}

/* SCROLLED */
.site-header.scrolled {
  background: #fbfaf8;
  border-bottom: 1px solid rgba(0,0,0,.12);
  padding: 12px 0;
}

/* GRAIN */
.site-header::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;

  opacity: 0;
  mix-blend-mode: soft-light;
  filter: contrast(140%) brightness(115%);
  transition: opacity .35s ease;
}

.site-header.scrolled::before {
  opacity: .45;
}

/* INNER */
.header-inner {
  width: 100%;
  display: flex;
  align-items: center;
  padding-inline: clamp(24px, 4vw, 48px);
  column-gap: 40px;
  position: relative;
  z-index: 5;

  justify-content: space-between;
}

/* LEFT: Logo + Divider */
.header-left {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-shrink: 0;
}

.header-left + .header-center {
  margin-left: 40px;
}

/* DIVIDER */
.header-divider {
  display: block;
  width: 1px;
  height: 26px;
  background: rgba(255,255,255,.7);
  transition: background .35s ease;
}

.site-header.scrolled .header-divider {
  background: rgba(0,0,0,.3);
}

/* LOGO */
.header-logo {
  position: relative;
  width: 120px;
  height: 65px;
  display: block;
  overflow: hidden;
  margin-top: -15px;
  margin-bottom: -10px;
}

.header-logo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity .3s ease;
  pointer-events: none;
}

/* Start */
.logo-light { opacity: 1; }
.logo-default { opacity: 0; }

/* Scroll */
.site-header.scrolled .logo-light { opacity: 0; }
.site-header.scrolled .logo-default { opacity: 1; }

/* ============================================
   NAV DESKTOP
============================================ */
.nav-desktop {
  margin-left: 40px;
  margin-right: auto;
}

.nav-desktop ul {
  display: flex;
  gap: clamp(1.6rem, 3vw, 3rem);
  list-style: none;
}

.nav-desktop a {
  color: #fff;
  font-weight: 300;
  font-size: var(--fs-body);
  font-family: var(--font-headline);
  letter-spacing: .01em;

  padding: 6px 0;
  transition: color .25s ease, opacity .25s ease;
}

.site-header.scrolled .nav-desktop a {
  color: var(--ink-body);
}

.nav-desktop a:hover {
  opacity: .7;
  color: var(--ink-meta);
}

/* ============================================
   RIGHT: HEADER CTA (Telefon + Exposé)
============================================ */

.header-cta {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Base button */
.header-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;

  padding: 6px 14px;
  border-radius: 999px;

  font-size: var(--fs-body);
  font-weight: 300;
  font-family: var(--font-body);
  text-decoration: none;
  white-space: nowrap;

  transition: color .25s ease, background .25s ease, opacity .25s ease;
}

/* Phone button */
.header-btn-phone {
  display: inline-flex;
  align-items: center;
  gap: 6px;

  padding: 6px 14px;
  border-radius: 10px;
  border: 1px solid #ffffff26;
  background: rgba(255,255,255,0.14);
  backdrop-filter: blur(6px);

  color: #fff;
  text-decoration: none;
  font-weight: 300;
  font-family: var(--font-body);

  transition: color .25s ease, background .25s ease, opacity .25s ease;
}

.site-header.scrolled .header-btn-phone {
  background: #623a181c;
  color: var(--brand);
  border: 1px solid #623b1839;
}

.header-btn-phone:hover {
  background: rgba(255,255,255,0.26);
  opacity: .9;
}

/* Exposé primary button */
.header-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;

  padding: 6px 16px;
  border-radius: 10px;
  border: 1px solid #ffffff26;
  background: rgba(255,255,255,0.22);
  backdrop-filter: blur(6px);

  color: #fff;
  font-family: var(--font-body);
  font-weight: 300;
  text-decoration: none;
}

.site-header.scrolled .header-btn-primary {
  background: #623a181c;
  color: var(--brand);
  border: 1px solid #623b1839;
}

.header-btn-primary:hover {
  background: rgba(255,255,255,0.32);
}
.header-contact .contact-link {
  color: #fff;
  font-weight: 300;
  text-decoration: none;
  font-size: var(--fs-body);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color .25s ease, opacity .25s ease;
}

.site-header.scrolled .header-contact .contact-link {
  color: var(--ink-body);
}

.header-contact .contact-link:hover {
  color: var(--brand);
  opacity: .85;
}



/* ============================================
   BURGER
============================================ */

.burger {
  display: none;
  width: 30px;
  height: 22px;
  position: relative;
  cursor: pointer;
}

.burger span {
  position: absolute;
  height: 2px;
  width: 100%;
  left: 0;
  background: #fff;
  transition: .3s ease;
}

.site-header.scrolled .burger span {
  background: var(--ink-body);
}

.burger .b1 { top: 4px; }
.burger .b2 { top: 10px; width: 70%; }
.burger .b3 { top: 16px; width: 40%; }

.burger[aria-expanded="true"] .b1 {
  top: 10px;
  transform: rotate(45deg);
}
.burger[aria-expanded="true"] .b2 { opacity: 0; }
.burger[aria-expanded="true"] .b3 {
  top: 10px;
  width: 100%;
  transform: rotate(-45deg);
}

/* ============================================
   NAV MOBILE
============================================ */
.nav-mobile {
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  background: var(--base-bg);
  border-bottom: 1px solid rgba(0,0,0,.08);
  padding: 10px clamp(1.5rem, 6vw, 3rem);

  transform: translateY(-20px);
  opacity: 0;
  pointer-events: none;

  transition: .3s ease;
  z-index: 999;
}

.nav-mobile.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.nav-mobile ul {
  display: flex;
  flex-direction: column;
  gap: 0;
  list-style: none;
}

.nav-mobile a {
  color: var(--brand);
  font-size: var(--fs-body);
  font-weight: 300;
  font-family: var(--font-headline);
  padding: 14px 0;
  line-height: 1.2;
  padding-left: 20px;
  padding-right: 20px;
  display: block;
  position: relative;
}

.nav-mobile li + li::before {
  content: "";
  display: block;
  width: 100%;
  height: 1px;
  background: color-mix(in srgb, var(--brand) 45%, transparent);
  opacity: 0.35;
  margin: 0;
}

.nav-mobile li {
  padding: 0;
}

.nav-mobile a:hover {
  color: var(--brand);
}

/* ============================================
   RESPONSIVE
============================================ */
@media (max-width: 1024px) {
  .nav-desktop,
  .header-contact,
  .header-divider {
    display: none;
  }

  .burger {
    display: block;
  }

   .site-header:not(.scrolled) {
    padding: 18px 0;     /* vorher 32px → nun höher platziert */
  }

  .header-logo {
    height: 42px;        /* leicht kompakter */
  }

  .burger {
    transform: translateY(-4px); /* feiner optischer Ausgleich */
  }
}

@media (min-width: 1024px) {
  .nav-mobile { display: none; }
}