/* ======================================= */
/* MENU-BUTTON                             */
/* ======================================= */

.menu-bar {
  background-image: linear-gradient(to right,
    hsl(0,100%,60%),
    hsl(60,100%,60%),
    hsl(120,100%,60%),
    hsl(180,100%,60%),
    hsl(240,100%,60%),
    hsl(300,100%,60%),
    hsl(360,100%,60%)
  );
  background-size: 400% 100%;
  background-position: 25% 0%;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 40px;
  overflow: visible;
  cursor: pointer;
  z-index: 200;
  opacity: 0.9;
  transition: background-position 8s ease, height 1s ease, opacity 0.3s ease;
}

/* Wenn geöffnet: voll opak damit menu-content nicht durchscheint */
.menu-bar-visible {
  opacity: 1 !important;
}

.menu-bar:hover,
.menu-bar:focus {
  opacity: 1;
}

.menu-bar-visible {
  width: 100vw;
  height: 100vh;
}

/* ======================================= */
/* MENU-INHALT                             */
/* ======================================= */

.menu-content {
  position: fixed;
  top: 30px;
  bottom: 30px;
  left: 30px;
  right: 30px;
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  box-sizing: border-box;
  opacity: 0;
  pointer-events: none;
  overflow-y: scroll;
  transition: opacity 1s, background-color 8s ease;
}

.menu-bar-visible .menu-content {
  opacity: 1;
  pointer-events: auto;
}

/* ======================================= */
/* ICON CLOSE                              */
/* ======================================= */

.icon-close {
  cursor: pointer;
  position: fixed;
  top: 60px;   /* 30px Fensterrand + 30px Abstand */
  right: 60px; /* 30px Fensterrand + 30px Abstand */
  transition: transform 1s, opacity 0.3s, visibility 0.3s;
  transform: rotate(-180deg);
  opacity: 0;
  visibility: hidden;
}

.menu-bar-visible .icon-close {
  transform: rotate(0deg);
}

.icon-close:hover {
  transform: rotate(-180deg);
}

.menu-bar-visible .icon-close:hover {
  transform: rotate(0deg);
}

/* ======================================= */
/* CHRONOLOGIE-SUBMENÜ                     */
/* ======================================= */

.chrono-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  cursor: pointer;
  z-index: 210; /* über dem Hauptmenü */
  background-color: rgba(0, 0, 0, 0.35); /* dimmt den Rest des Bildschirms ab */
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.8s ease; /* langsames Ausblenden */
}

.chrono-bar-visible {
  opacity: 1 !important;
  pointer-events: auto;
  transition: opacity 0.15s ease; /* schnelles Einblenden */
}

.chrono-content {
  position: fixed;
  top: 50px;
  left: 50px;
  right: 10px;
  bottom: 10px;
  padding: 30px;
  box-sizing: border-box;
  opacity: 0;
  pointer-events: none;
  overflow-y: scroll;
  transition: opacity 0.8s ease, background-color 8s ease; /* langsames Ausblenden */
}

.chrono-bar-visible .chrono-content {
  opacity: 1;
  pointer-events: auto;
  transition: opacity 0.15s ease, background-color 8s ease; /* schnelles Einblenden */
}

.chrono-close {
  cursor: pointer;
  position: fixed;
  top: 80px;  /* 50px Fensterrand + 30px Abstand */
  right: 40px; /* 10px Fensterrand + 30px Abstand */
  z-index: 220; /* über chrono-content */
  transition: transform 1s, opacity 0.3s, visibility 0.3s;
  transform: rotate(-180deg);
  opacity: 0;
  visibility: hidden;
}

.chrono-bar-visible .chrono-close {
  transform: rotate(0deg);
}

.chrono-close:hover {
  transform: rotate(-180deg);
}

.chrono-bar-visible .chrono-close:hover {
  transform: rotate(0deg);
}

.chrono-years {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 12px 24px;
  align-content: start;
}

.chrono-year-link {
  display: block;
  text-decoration: none;
  color: inherit;
  font-size: 1.4em;
}

.chrono-year-link:hover {
  text-decoration: underline;
}

/* Auf kleinen Bildschirmen einspaltig, sonst liegen die Jahreszahlen
   teils hinter dem Schließen-Kreuz */
@media (max-width: 600px) {
  .chrono-years {
    grid-template-columns: 1fr;
  }
}

/* ======================================= */
/* NAVIGATION                              */
/* ======================================= */

.menu-separator {
  transform: rotate(-8deg);
  margin-left: 0;
  margin-top: 40px;
  margin-bottom: 40px;
  border: none;
  background-color: #111111;
  height: 2px;
  width: 300px;
  max-width: 60%;
}

.menu-title {
  margin: 0 !important;
}

/* ======================================= */
/* SPALTEN-LAYOUT                          */
/* ======================================= */
/* Ersatz für das WordPress-Columns-Block-CSS, das ohne echten
   wp:columns-Block im Content nicht automatisch geladen wird. */

.menu-columns {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  row-gap: 2em;
  column-gap: 0;
}

.menu-column {
  flex: 1;
  min-width: 0;
}

@media (max-width: 600px) {
  .menu-columns {
    flex-direction: column;
  }

  .menu-column {
    flex-basis: 100% !important;
  }
}

/* ======================================= */
/* MENÜLISTEN (statisch)                   */
/* ======================================= */

.menu-nav-list {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 0.25em !important;
}

.menu-nav-list li {
  margin: 0 !important;
  padding: 0 !important;
  line-height: normal !important;
}

.menu-nav-list a {
  display: block;
  text-decoration: none;
  color: inherit;
  margin: 0 !important;
  padding: 0 !important;
}

.menu-nav-list a:hover {
  text-decoration: none !important;
}

.chrono-trigger a:hover,
.menu-title a:hover,
.menu-social-links a:hover {
  text-decoration: none !important;
}

.chrono-trigger {
  margin: 0 !important;
}

.menu-social-links {
  list-style: none;
  display: flex;
  gap: 12px;
  margin: 20px 0 0 0;
  padding: 0;
}

.menu-social-links img {
  display: block;
  width: 24px;
  height: 24px;
}

.menu-categories-col .menu-nav-list,
.menu-categories-col .chrono-trigger {
  font-size: 1.125rem;
}

/* Auf kleinen Bildschirmen: statische Seiten eine Stufe kleiner als der Rest */
@media (max-width: 600px) {
  .menu-nav-list--pages {
    font-size: 0.9rem;
  }

  /* Titel und Kategorien auf die gleiche Größe wie die Jahreszahlen
     im Chronologie-Submenü bringen (dort: 1.4em auf gleicher Basis) */
  .menu-title,
  .menu-categories-col .menu-nav-list,
  .menu-categories-col .chrono-trigger {
    font-size: 1.4em !important;
  }
}
