body { 
    font-family: sans-serif; 
    background-color: #f4f4f4; 
    margin: 0; 
    padding: 20px; 
}
.timeline-main-container { 
    max-width: 900px; 
    margin: 40px auto; 
    padding: 20px; 
    background-color: #fff; 
    border-radius: 8px; 
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); 
}
.timeline-main-container h2 { 
    text-align: center; 
    color: #2c3e50; 
    margin-bottom: 30px; 
}
.timeline { 
    position: relative; 
    padding: 20px 0; 
}
.timeline::before { 
    content: ''; 
    position: absolute; 
    left: 20px; 
    top: 0; 
    bottom: 0; 
    width: 4px; 
    background-color: #3498db; 
}
.timeline-item { 
    position: relative; 
    margin-bottom: 40px; 
    padding-left: 60px; 
}
.timeline-icon { 
    position: absolute; 
    left: 8px; 
    top: 5px; 
    width: 24px; 
    height: 24px; 
    background-color: #fff; 
    border: 3px solid #3498db; 
    border-radius: 50%; 
    z-index: 1; 
}
.timeline-date { 
    font-size: 1.1em; 
    font-weight: bold; 
    color: #2980b9; 
    margin-bottom: 10px; 
}
.timeline-content { 
    background-color: #ffffff; 
    padding: 20px; 
    border-radius: 6px; 
}
.timeline-content h3 { 
    margin-top: 0; 
}
.twentytwenty-container { 
    margin-top: 15px; 
}
.timeline-nav { 
    position: fixed; 
    left: 20px; 
    top: 50%; 
    transform: translateY(-50%); 
    background-color: #fff; 
    padding: 15px; 
    border-radius: 8px; 
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2); 
    z-index: 1000; 
}
.timeline-nav ul { 
    list-style-type: none; 
    margin: 0; 
    padding: 0; 
}
.timeline-nav ul li { 
    margin-bottom: 10px; 
}
.timeline-nav ul li a { 
    text-decoration: none; 
    color: #3498db; 
    font-weight: bold; 
    font-size: 16px; 
    padding: 5px; 
    display: block; 
    transition: background-color 0.2s; 
    border-radius: 4px; 
}
.timeline-nav ul li a:hover { 
    color:#E35A46; 
}
.timeline-nav ul li a.active { 
    background-color: #f0f0f0; 
    color: #E35A46; 
}
.twentytwenty-container img { 
    max-width: 100%; 
    max-height: 550px; 
    height: auto; 
    object-fit: contain; 
}
.video-container { 
    position: relative; 
    padding-bottom: 56.25%; 
    height: 0; 
    overflow: hidden; 
    max-width: 100%; 
    background: #000; 
    border-radius: 6px; 
    margin-top: 15px; 
    box-shadow: 0 2px 8px rgba(0,0,0,0.1); 
}
.video-container video { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    border: 0; 
}
.lightbox-button { 
    display: inline-block; 
    margin-top: 15px; 
    padding: 8px 15px; 
    background-color: #3498db; 
    color: white; 
    text-align: center; 
    text-decoration: none; 
    border-radius: 5px; 
    font-weight: bold; 
    transition: background-color 0.3s ease; 
}
.lightbox-button:hover { 
    background-color: #2980b9; 
    color: white; 
}

/* --- Ladebalken als Floating Window --- */
#loading-progress-container { 
    position: fixed; 
    bottom: 25px; 
    right: 25px; 
    width: 280px; 
    background-color: #ffffff; 
    border-radius: 8px; 
    box-shadow: 0 5px 15px rgba(0,0,0,0.15); 
    padding: 15px; 
    z-index: 9999; 
    opacity: 0; 
    transform: translateX(100px); 
    transition: opacity 0.4s ease-out, transform 0.4s ease-out; 
    pointer-events: none; 
}
#loading-progress-container.visible { 
    opacity: 1; 
    transform: translateX(0); 
    pointer-events: auto; 
}
#progress-text { 
    font-size: 15px; 
    color: #333; 
    font-weight: bold; 
    margin-bottom: 10px; 
}
#progress-bar-background { 
    width: 100%; 
    height: 8px; 
    background-color: #e9ecef; 
    border-radius: 4px; 
    overflow: hidden; 
}
#loading-progress-bar { 
    width: 0%; 
    height: 100%; 
    background-color: #3498db; 
    border-radius: 4px; 
    transition: width 0.3s ease-in-out; 
}
#progress-counter { 
    font-size: 13px; 
    color: #666; 
    margin-top: 8px; 
    text-align: right; 
}

/* --- Info-Modal --- */
#info-modal-overlay { 
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    background-color: rgba(0, 0, 0, 0.6); 
    z-index: 10000; 
    display: flex; 
    justify-content: center; 
    align-items: center; 
    opacity: 0; 
    pointer-events: none; 
    transition: opacity 0.3s ease-in-out; 
}
#info-modal-overlay.visible { 
    opacity: 1; 
    pointer-events: auto; 
}
#info-modal { 
    background-color: #fff; 
    padding: 25px 30px; 
    border-radius: 8px; 
    max-width: 500px; 
    width: 90%; 
    box-shadow: 0 5px 20px rgba(0,0,0,0.2); 
    transform: scale(0.95); 
    transition: transform 0.3s ease-in-out; 
}
#info-modal-overlay.visible #info-modal { 
    transform: scale(1); 
}
#info-modal h2 { 
    margin-top: 0; 
    color: #2c3e50; 
}
#info-modal ul { 
    padding-left: 20px; 
    line-height: 1.6; 
}
#info-modal ul li { 
    margin-bottom: 10px; 
}
#close-modal-btn { 
    display: block; 
    width: 100%; 
    padding: 12px; 
    margin-top: 20px; 
    border: none; 
    background-color: #3498db; 
    color: white; 
    font-size: 16px; 
    font-weight: bold; 
    border-radius: 5px; 
    cursor: pointer; 
    transition: background-color 0.2s; 
}
#close-modal-btn:hover { 
    background-color: #2980b9; 
}

/* =========================================================
   FINALE, ZUVERLÄSSIGE LÖSUNG: Fade-In & Lade-Animation
   ========================================================= */

/* --- 1. Fade-In für die Vorschaubilder in der Timeline --- */
.twentytwenty-container.lazy-slider {
    display: block ;
    min-height: 400px;
    background-color: #f0f0f0;
    border-radius: 6px;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
}
.twentytwenty-container.lazy-slider.images-loaded {
    opacity: 1;
}

/* --- 2. Lade-Animation für die grosse Ansicht (Fancybox) --- */
.fancybox__spinner {
  width: 50px;
  height: 50px;
  animation: none;
  position: absolute;
  top: 50%;
  left: 50%;
  margin: -25px 0 0 -25px;
  background-color: transparent;
}
.fancybox__spinner::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 5px solid rgba(255, 255, 255, 0.4);
  border-top-color: #ffffff;
  animation: fancybox-custom-spin 1s linear infinite;
}
@keyframes fancybox-custom-spin {
  to {
    transform: rotate(360deg);
  }
}