/* ============================================================
   willmixen2026-child — HEADER CSS (v0.9.3)
   ------------------------------------------------------------
   ISOLIERT:
   - Alle Tokens scoped auf .wmc-header (kein :root Pollution)
   - Alle Klassen mit `wmc-header__` Prefix (BEM)
   - Schriften: Gilroy (in global.css), bereits site-weit geladen
   - Astra-Default-Header rendert nicht (header.php ueberschreibt)
   ============================================================ */

.wmc-header {
  /* Scoped Design-Tokens — kollidieren nicht mit anderen */
  --wmc-h-bg:        #FFFFFF;
  --wmc-h-topbar:    #F3E7E8;
  --wmc-h-text:      #1C1917;
  --wmc-h-muted:     #78716C;
  --wmc-h-rose:      #B5626A;
  --wmc-h-border:    #EDE9E3;
  --wmc-h-rose-soft: #E8D0D2;

  font-family: 'Gilroy', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--wmc-h-bg);
  color: var(--wmc-h-text);
  position: relative;
  z-index: 100;
}

/* Skip-Link */
.skip-link.screen-reader-text {
  position: absolute !important;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.skip-link.screen-reader-text:focus {
  left: 6px;
  top: 6px;
  width: auto;
  height: auto;
  padding: 0.5rem 1rem;
  background: var(--wmc-h-text, #1C1917);
  color: #fff;
  z-index: 9999;
}

/* ============================================================
   TOP-BAR
   ============================================================ */
.wmc-header__topbar {
  background: var(--wmc-h-topbar);
  border-bottom: 1px solid var(--wmc-h-rose-soft);
}
.wmc-header__topbar-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0.45rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wmc-header__search-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--wmc-h-text);
  padding: 0;
  transition: color 0.2s ease;
}
.wmc-header__search-toggle:hover {
  color: var(--wmc-h-rose);
}

.wmc-header__social {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}
.wmc-header__social-link {
  color: var(--wmc-h-muted);
  display: flex;
  align-items: center;
  text-decoration: none;
  transition: color 0.2s ease;
}
.wmc-header__social-link:hover {
  color: var(--wmc-h-rose);
}

/* ============================================================
   HAUPT-HEADER (Nav | Logo | Nav)
   ============================================================ */
.wmc-header__main {
  background: var(--wmc-h-bg);
  border-bottom: 2.5px solid var(--wmc-h-text);
}
.wmc-header__main-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0.9rem 2rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1.5rem;
}

/* Logo */
.wmc-header__logo {
  justify-self: center;
  text-align: center;
}
.wmc-header__logo a {
  display: inline-block;
  line-height: 0;
  text-decoration: none;
}
.wmc-header__logo img,
.wmc-header__logo .custom-logo {
  max-height: 75px;
  width: auto;
  display: block;
}
.wmc-header__site-name {
  font-family: 'Perfectly Nineties', Georgia, serif;
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--wmc-h-text);
  letter-spacing: -0.02em;
}

/* Navigation */
.wmc-header__nav {
  display: flex;
  align-items: center;
}
.wmc-header__nav--left { justify-content: flex-end; }
.wmc-header__nav--right { justify-content: flex-start; }

.wmc-header__menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 0.15rem;
  flex-wrap: wrap;
}
.wmc-header__menu li {
  position: relative;
}
.wmc-header__menu a {
  display: block;
  padding: 0.35rem 0.55rem;
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--wmc-h-text);
  text-decoration: none;
  transition: color 0.2s ease;
  white-space: nowrap;
}
.wmc-header__menu a:hover,
.wmc-header__menu .current-menu-item > a,
.wmc-header__menu .current-menu-ancestor > a {
  color: var(--wmc-h-rose);
}

/* Submenue */
.wmc-header__menu .sub-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 200px;
  background: var(--wmc-h-bg);
  border: 1px solid var(--wmc-h-border);
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(28, 25, 23, 0.08);
  padding: 0.5rem 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
  z-index: 1000;
  list-style: none;
  margin: 0;
}
.wmc-header__menu li:hover > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.wmc-header__menu .sub-menu a {
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  padding: 0.45rem 1.1rem;
  font-size: 0.85rem;
}

/* ============================================================
   SUCHBAR (collapsible)
   ============================================================ */
.wmc-header__searchbar {
  background: #FAF8F5;
  border-bottom: 1px solid var(--wmc-h-border);
  padding: 0.75rem 0;
}
.wmc-header__searchbar-inner {
  max-width: 600px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.wmc-header__searchbar .search-form { flex: 1; }
.wmc-header__searchbar .search-field {
  width: 100%;
  border: 1.5px solid var(--wmc-h-text);
  border-radius: 0;
  padding: 0.6rem 1rem;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: var(--wmc-h-bg);
}
.wmc-header__search-close {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.4rem;
  color: var(--wmc-h-muted);
  padding: 0.25rem 0.5rem;
  line-height: 1;
}
.wmc-header__search-close:hover { color: var(--wmc-h-rose); }

/* ============================================================
   MOBILE-CONTROLS
   ============================================================ */
.wmc-header__mobile-controls {
  display: none;
  align-items: center;
  gap: 1rem;
  justify-self: end;
}
.wmc-header__hamburger {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.wmc-header__hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--wmc-h-text);
}

.wmc-header__mobile-nav {
  background: var(--wmc-h-bg);
  border-bottom: 1px solid var(--wmc-h-border);
  padding: 1rem 2rem 1.5rem;
}
.wmc-header__mobile-menu {
  list-style: none;
  margin: 0 0 0.5rem 0;
  padding: 0;
}
.wmc-header__mobile-menu a {
  display: block;
  padding: 0.6rem 0;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--wmc-h-text);
  text-decoration: none;
  border-bottom: 1px solid var(--wmc-h-border);
}
.wmc-header__mobile-menu a:hover { color: var(--wmc-h-rose); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .wmc-header__nav { display: none !important; }
  .wmc-header__mobile-controls { display: flex !important; }
  .wmc-header__main-inner {
    grid-template-columns: 1fr auto !important;
  }
  .wmc-header__logo { justify-self: start !important; }
  .wmc-header__topbar .wmc-header__social { display: none !important; }
}
@media (max-width: 640px) {
  .wmc-header__topbar-inner,
  .wmc-header__main-inner {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}
