/* ==========================================================================
   1. BASIS & RESET
   ========================================================================== */
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: #fff;
  color: #565656;
}

/* ==========================================================================
   2. HEADER & TOPBAR
   ========================================================================== */
header {
  position: relative;
  height: 180px;
  padding-top: 10px;
  background: url("../Bilder/Dia/head_mobil.jpg") center/cover no-repeat;
}

header_useite {
  position: relative;
  height: 100px;
  padding-top: 10px;
}

header::after,
header_useite::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0);
}

.topbar-bar {
  position: relative;
  z-index: 110;
  padding-top: 3px;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(4px);
  border-bottom: 1px solid rgba(0, 0, 0, .06);
}

.topbar {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  padding: 4px 8px;
  /* grid-template-columns entfernt, da display: flex aktiv ist */
}

/* ==========================================================================
   3. NAVIGATION (ALT & NEU)
   ========================================================================== */

/* Die alte Navigation (ul#Navigation) */
ul#Navigation li {
  list-style: none;
  float: left;
  position: relative;
}

ul#Navigation li ul {
  display: none;
  margin: 0;
  padding: 0;
  position: absolute;
  top: 20px;
  left: 0;
}

ul#Navigation li:hover ul {
  display: block;
  background: white;
}

ul#Navigation li ul li {
  float: none;
  display: block;
  margin-top: 10px;
}

ul#Navigation a,
ul#Navigation span {
  display: block;
  text-decoration: none;
  padding: 0 10px 3px 10px;
  color: #565656;
  background-color: white;
}

/* Die neue Overlay-Navigation (Mobil) */
#overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 98;
  display: none;
}

body.menu-open #overlay {
  display: block;
}

nav {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 100;
  width: 50%;
  max-width: 320px;
  height: 100%;
  padding: 80px 20px 20px;
  background: #fff;
  transform: translateX(-100%);
  transition: .25s ease;
}

body.menu-open nav {
  transform: translateX(0);
}

nav a {
  display: block;
  padding: 12px 0;
  border-bottom: 1px solid #ddd;
  text-decoration: none;
  color: #333;
  font-size: 18px;
}

#burger {
  position: relative;
  z-index: 120;
  width: 44px;
  height: 44px;
  margin-right: 12px;
  border: none;
  border-radius: 8px;
  background: rgba(69, 169, 238, .95);
  color: white;
  font-size: 26px;
  cursor: pointer;
}
/* ==========================================================================
   4. CONTENT & MODULE
   ========================================================================== */
main {
  padding: 15px;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: auto;
}

.modulbox {
  margin: 25px 0;
  padding: 14px 14px 16px 14px;
  background: #f7f9fb;
  border-left: 4px solid #45A9EE;
  border-radius: 6px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.04);
}

.trenner {
  clear: both;
  height: 1px;
  margin: 35px 0 30px 0;
  border-bottom: 1px solid #ddd;
}

/* ==========================================================================
   5. KOMPONENTEN (PILOTENINFO / ACCORDION)
   ========================================================================== */
.accordion {
  width: 100%;
  margin-top: 8px;
  padding: 12px;
  background: #f0f0f0;
  border: 1px solid #ccc;
  font-size: 16px;
  text-align: left;
  cursor: pointer;
}

.panel {
  display: none;
  padding: 10px;
  background: white;
  border: 1px solid #ccc;
  border-top: none;
}

.panel ul {
  padding-left: 18px;
}

@media(min-width: 900px) {
  .panel { display: block; }
}

/* PPR Hinweise */
.ppr-hinweis {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 8px 0 18px 0;
  padding: 10px 14px;
  background: #f5f5f5;
  border-left: 6px solid #ccc;
  border-radius: 6px;
  font-size: 15px;
}

.ppr-hinweis.gruen { background: #d4edda; border-left-color: green; }
.ppr-hinweis.gelb  { background: #fff3cd; border-left-color: orange; }
.ppr-hinweis.rot   { background: #f8d7da; border-left-color: red; }

/* Chronik / Iframe Wrapper */
.chronik-wrapper {
  width: 100%;
  max-width: 100%;
  height: 80vh;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid #ccc;
}

.chronik-frame {
  width: 1200px;
  height: 2000px;
  border: none;
}

/* ==========================================================================
   6. DIE AMPEL (TRAFFIC LIGHT)
   ========================================================================== */
#navAmpelContainer {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100px !important;
  height: 50px !important;
  z-index: 100;
  cursor: pointer;
  overflow: visible !important;
}

.traffic-light-mini {
  display: block !important;
  width: 50px !important;
  height: 18px !important;
  padding: 0 8px !important;
  background: #333 !important;
  border-radius: 6px !important;
  line-height: 18px !important;
  text-align: center !important;
  flex-shrink: 0 !important;
}

.l-mini {
  display: inline-block !important;
  width: 10px !important;
  height: 10px !important;
  margin: 0 2px !important;
  border-radius: 50% !important;
  vertical-align: middle !important;
  background-clip: padding-box !important;
}

/* Ampel Zustände */
.l-mini.off {
  background-color: #222 !important;
  opacity: 0.4 !important;
  box-shadow: inset 0 0 2px #000 !important;
}

.l-mini.rot:not(.off)   { background-color: #ff0000 !important; box-shadow: 0 0 6px #ff0000 !important; }
.l-mini.gelb:not(.off)  { background-color: #ffaa00 !important; box-shadow: 0 0 6px #ffaa00 !important; }
.l-mini.gruen:not(.off) { background-color: #00dd00 !important; box-shadow: 0 0 6px #00dd00 !important; }

#ampelStatusText {
  font-size: 9px !important;
  font-weight: bold !important;
  color: #565656 !important;
  text-transform: uppercase;
  white-space: nowrap !important;
  line-height: 1 !important;
}

/* ==========================================================================
   7. TYPOGRAFIE & LINKS
   ========================================================================== */
a, .logo, .ampel { text-align: center; }

a:link, a:visited, a:active {
  color: #565656;
  text-decoration: none;
  font-weight: bold;
}

a:hover, a:focus {
  color: #45A9EE;
  text-decoration: none;
}

/* ==========================================================================
   8. FOOTER
   ========================================================================== */
.footer {
  width: 100%;
  margin-top: 60px;
  padding: 20px 0;
  background: #565656;
}

.footer-inner {
  width: 80%;
  margin: auto;
  color: white;
  line-height: 1.4;
}

.footer-left {
  white-space: nowrap;
}

@media (max-width: 600px) {
  .footer-left { white-space: normal; }
}
