/* Anwendung Webauftritt SebastianLorenz.art   */
/* V01.0 16.01.2026 Ersterstellung   */
/* ==============================
   Z-INDEX SYSTEM
   0    background / overlay
   10   page content
   20   image UI
   100  header
   200  mobile navigation
   1000 modal / lightbox
============================== */



/* ==============================
  Styleangaben für login-Seite
============================== */
.login-page {
  margin: 0;
  min-height: 100vh;
  display: flex;
  justify-content: center; /* horizontal */
  align-items: center;     /* vertikal */
}

.login-box {
  background: white;
  padding: 30px;
  border-radius: 8px;
  width: 500px;
}

.login-box input {
    width: 100%;
    padding: 12px;
    margin: 8px 0;
    box-sizing: border-box;

    font-size: 16px;
    line-height: 1.4;

    border: 1px solid #ccc;
    border-radius: 4px;
}

.login-box input,
.login-box button {
    width: 100%;
    padding: 10px;
    margin-top: 10px;
}

.login-box button {
    background: black;
    color: white;
    border: none;
    cursor: pointer;
}

.login-box .error {
    color: red;
    margin-top: 10px;
}

/* ==============================
  Grundlayout Anfang
============================== */

/* globale Variablen für Höhe header und footer */
:root {
  --header-height: 100px;
  --footer-height: 30px;
}

@media (max-width: 768px) {
  :root {
    --header-height: 130px;
    --footer-height: 45px;
  }
}


/* standardcontainer für bodyinhalte bei variablen header und footer */

.container {
  max-width: 1200px;
  /*height: 0 auto; */
  margin: var(--header-height) auto var(--footer-height) auto;  /* mittig zentriert zwischen header und footer, kein scrollen lks re*/
  padding: 0 20px;
  /*border: 5px solid rgb(247, 243, 8); */
}

.container-topversatz {
  margin: calc(var(--header-height) + 20px) auto 0 auto;  /* mit Abstand zu topbar und mittig zentriert */
  /*border: 5px solid rgb(247, 243, 8); */
}

/* A h1 Überschrift für alle Seiten */
h1 {
    text-align: center;
    margin: 2rem 0 1rem;
    font-weight: 400;
    letter-spacing: 0.1em;
}
/* E h1 Überschrift für alle Seiten */

/* A Container über Overlay Anker für absolute Positionierungen s. a. Beschreibungen wichtig*/
#container {
    position: relative;
    z-index: 10;
} 

/* E Container über Overlay Anker für absolute Positionierungen s. a. Beschreibungen wichtig*/

/* A neuer zentraler html und body */
html, body {
    margin: 0;           /* entfernt Ghostscroll */
    padding: 0;
    height: 100%;
    font-family: Arial, sans-serif;
    overflow-x: hidden;    /* 03.04.2026 verhindert seitliches scrollen insbesondere auf dem handy */
    overflow-y: hidden;
}

body:not(.historie) {
    display: flex;
    flex-direction: column;
    min-height: 100vh;    /* verhindert Ghostscroll */
    background-image: url('favicon/wallpaper.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: scroll; /* fixed wird tlw. von handybrowser nicht unterstützt */
}

/* 16.03.2026 ist Performancebremse auf mobil, daher nur desktop 
@media (min-width: 769px) {
  body:not(.historie) {
    background-attachment: fixed;
  }
}
 inaktiviert; für Fehlersuche */

body.historie {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0;
    min-height: 100vh;
    background: #0e0e0e;
    color: #fff;
}

/* E neuer zentraler html und body */

/* ==============================
   ANIMATIONEN – GLOBAL
============================== */

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* content immer zwischen topbar und footer */
main {
    flex: 1;                      /* nimmt verfügbare Höhe zwischen Header & Footer */
   /* margin-top: 10px; */
    /*margin-bottom: calc(var(--footer-height) + 60px); */
    margin-bottom: calc(var(--footer-height));
    
    /* height: calc(100vh - 200px); height: calc(100dvh - 200px); wird mit flex: 1 übersteuert */
    overflow-y: auto;              /* nur Main scrollt */
    position: relative;            /* für absolute Kinder wie Slideshow Caption */
    /* border: 5px solid rgb(80, 33, 167); für Test bei layout box */
}

body.gallerie main {
    flex: 1;
    overflow-y: auto;
}

/* Subtiles Overlay über Hintergrundbild für bessere Lesbarkeit 
 gilt für alle Seiten*/
#container::before {
    content: "";
    position: fixed;
    inset: 0;
    background: rgba(255,255,255,0.05);
    z-index: 0;
    pointer-events: none;
}



/* ==============================
  Grundlayout Ende
============================== */

/* =====================================
   HEADER – FINAL WORKING VERSION Anfang
===================================== */

/* ausblenden für test
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(0,0,0,0.1);
  z-index: 100;
}*/


.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(8px);
  z-index: 100;
  /*test layout box
  border: 2px solid rgb(86, 6, 117) !important;  */
}

.topbar-inner {
  max-width: 1200px;
  height: 100%;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;  
  /*border: 5px solid rgb(82, 14, 14) !important;*/
}

/* E Für Handy Topbar fixieren */

/* A Für alle medias Logo links und an topbar hängen
Änderungen für Logo links in topbar*/
.logo {
  position: relative;     /* kein fixed mehr */
  left: 0;
  top: 0;
  z-index: 210;
}

.logo img {
  height: 80px;
  width: auto;
  display: block;
  /* wegen Überlappung icon und Menue im Übergang von Tablet zu Handy mit Burger-menue*/
  opacity: 0.8;   /* 0 = unsichtbar | 1 = voll sichtbar */
}

/* E Für alle medias Logo links und an topbar hängen*/

/* A Für Handy Logo zentriert*/
/* Änderungen für logo dynasmisch positionieren*/
@media (max-width: 768px) {
  .topbar-inner {
    justify-content: center;   /* 🔥 alles mittig */
  }

  .logo {
    position: absolute;
/* Änderung zentriert und 5px von oben */
    top: 5px;
    left: 50%;
    transform: translateX(-50%);
  }
/* Reset von: durchscheinend wegen Überlappung icon und Menue im Übergang von Tablet zu Handy mit Burger-menue*/
  .logo img {  
  opacity: 1;   /* 0 = unsichtbar | 1 = voll sichtbar */
  }
  /* icon CSV Bearbeitung linksbündig für handy */
  .admin-link {
    margin-right: auto; /* schiebt alles andere nach rechts */
    display: flex;
    align-items: center;
  }
}
/* A Alter Stand vor Änderung logo positionieren
@media (max-width: 768px) {
  .logo {
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    justify-content: center;
    z-index: 210;
  }

  .logo img {
    height: 80px;
    width: auto;
  }
}
 A Alter Stand vor Änderung logo positionieren */
/* E Für Handy Logo zentriert*/

/* Seitentitel */
.page-title {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);

  font-family: "Montserrat", "Inter", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.45rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;

  color: #111;
  opacity: 0;
  white-space: nowrap;
  pointer-events: none;

  animation: titleFadeUp 1.2s ease-out forwards;
}

/* A Für Handy Page Title */
@media (max-width: 768px) {
  .page-title {
    top: auto;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1.05rem;
    letter-spacing: 0.14em;
    pointer-events: none;
    color: #111;
  }

  .page-title::after {
    width: 62px;
    max-width: 62px;
    margin-top: 6px;
  }
}
/* E Für Handy Page Title */

/* A Für sehr kleine Handy Page Title */
@media (max-width: 480px) {
    .page-title {
    bottom: 8px;
    font-size: 0.95rem;
    letter-spacing: 0.12em;
  }

  .page-title::after {
    width: 56px;
    max-width: 56px;
  }
}
/* E Für sehr kleine Handy Page Title */

/* Animation page-title */
@keyframes titleFadeUp {
  from {
    opacity: 0;
    transform: translate(-50%, -6px);
  }
  to {
    opacity: 0.9;
    transform: translate(-50%, 0);
  }
}

@keyframes lineFade {
  from {
    opacity: 0;
    width: 0;
  }
  to {
    opacity: 1;
    width: 150px;
  }
}

/* feine Galerie-Linie */
.page-title::after {
  content: "";
  display: block;
  height: 1px;
  margin: 8px auto 0;
  background: rgba(0,0,0,0.25);

  opacity: 0;
  width: 150px;         
  animation: lineFade 0.8s ease-out forwards;
  animation-delay: 0.6s;
}


/* ==============================
   TOGGLE MIT SLIDER – DEAKTIVIERT
==============================

.toggle {
    position: relative;
    width: 52px;
    height: 28px;
}

.toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    inset: 0;
    background: rgba(255,255,255,0.25);
    border-radius: 999px;
    cursor: pointer;
    transition: background 0.25s ease;
}

.slider::before {
    content: "";
    position: absolute;
    width: 22px;
    height: 22px;
    left: 3px;
    top: 3px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.25s ease;
}

.toggle input:checked + .slider {
    background: #a01919;
}

.toggle input:checked + .slider::before {
    transform: translateX(24px);
}

.toggle-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    margin: 14px auto 0;
    max-width: 1000px;
    padding-left: 20px;
}

.toggle-row {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #fff;
    font-size: 15px;
}

==============================
   TOGGLE MIT SLIDER – ENDE
============================== */


/* ==============================
   DESKTOP NAVIGATION
============================== */
/* für aufruf Bilddatei bearbeiten link in topbar */
#admin-link {
    position: absolute;   /* relativ zur Topbar */
    bottom: 5px;
    right: 10px;
    width: 1px;
    height: 1px;
    overflow: hidden;
    font-size: 20px;
    color: black;
    text-decoration: none;
    z-index: 9999;
    transition: color 0.2s ease;
}

/* Hover-Effekt: rot */
#admin-link:hover {
    color: red;
}

/* A DESKTOP NAV mit Auswahlmenue */
@media (min-width: 769px) {
  .main-nav {
    position: fixed;
    top: 55px;
    left: 50%;
    column-gap: 15px;
    row-gap: 2px;
    transform: translateX(-50%);

    width: min(600px, 90%);

    display: flex;
    justify-content: center;
    
    flex-wrap: wrap;         /* 🔥 wichtig */

    z-index: 200;
  }
  /* A alter Stand 
   .main-nav a {    
    opacity: 0.75;
    text-decoration: none;
    color: #111;
    letter-spacing: 0.08em;
    transition: opacity 0.2s ease;
    font-size: 13px;
  }
  E alter Stand */
  /* A neuer Stand Animaton Auswahlpunkt */
  .main-nav a {
  position: relative;
  text-decoration: none;
  color: #222;
  font-size: clamp(12px, 1.2vw, 14px);
  font-weight: 400;
  letter-spacing: 0.5px;
  transition: color 0.3s ease;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 1px;
  background: #c6a75e;   /* warmes Kunst-Gold */
  transition: width 0.35s ease;
}

.main-nav a:hover {
  color: #000;
}

.main-nav a:hover::after {
  width: 100%;
}
/* E neuer Stand Animaton Auswahlpunkt*/
/* für Zeilenumbruch nach Menuepunkt "Bilder in Privatbesitz" braucht display flex und flex-wrap flex in main-nav */
  .nav-break {
  flex-basis: 100%;
  height: 0;
}

  .main-nav a:hover {
    opacity: 1;
  }

  .burger {
    display: none;
  }
}

/* E DESKTOP NAV mit Auswahlmenue */
 
/* ==============================
   MOBILE NAVIGATION + BURGER
============================== */
@media (max-width: 768px) {

  /* Burger-Button */
  .burger {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 22px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 220;
    position: absolute;
    top: 50px;
    right: 20px;
  }

  .burger span {
    display: block;
    height: 3px;
    width: 100%;
    background-color: #111;
    border-radius: 2px;
    transition: all 0.3s ease;
  }

  .burger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .burger.active span:nth-child(2) {
    opacity: 0;
  }

  .burger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  /* Mobile Navigation */
  .main-nav {
    position: fixed;
    top: 130px;
    left: 50%;
    transform: translateX(-50%);
    width: max-content;      /* 🔥 Box passt sich Text an */
    min-width: 220px;        /* optional, für Optik */
    padding: 0;          /* 🔑 nur minimal */
    gap: 0;                  /* ❗ wichtig */

    display: none;
    flex-direction: column;

    background: #fff; 
    border-radius: 6px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
   
    z-index: 999;
  }
   
   .main-nav.active {
    display: flex;
    animation: slideDown 0.25s ease-out;
  }

  .main-nav a {
    display: block;
    padding: 6px 14px; /* 🔥 hier steuert man die Höhe */
    line-height: 1.3;    /* ❗ kein unnötiger Zeilenabstand */
    margin: 0;

    color: #111;
    white-space: nowrap;
    text-decoration: none;
    font-size: 15px;   
    letter-spacing: 0.08em;
    transition: background 0.2s, color 0.2s;
  }

  .main-nav a:hover {
    background: rgba(160,25,25,0.05);
    color: #a01919;
  }
  
} /* ✅ schließt @media */


/* =====================================
   HEADER – FINAL WORKING VERSION Ende
===================================== */

/*A Slideshow in index.php */

/* ==============================
   Galerie (index-galerie)
============================== */
.index-galerie { 
  /*test für layout box
  border: 5px solid red !important; */
  display: grid;                                
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  /*height: calc(100svh - var(--header-height) - var(--footer-height)); wird nicht benötigt, ansonsten scrollen über footer */
  gap: 20px;           /* Abstand der Elemente in einer Flexbox oder Grid-Container, hier horizontal für Desktop */
  max-width: 1200px;
  margin: 0 auto;
  padding: 50px 0px 0px 0px; /* Abstand über der Slideshow für desktop*/
}

/* für handy von grid auf flex bilder untereinander */
@media (max-width: 768px) {

  .index-galerie {
    /*test für layout box
    border: 5px solid red !important; */
    background-color: rgba(86, 18, 211, 0.1) !important; /* leichter roter Hintergrund */
    display: flex;
    flex-direction: column;
    gap: 10px;  /* Abstand der Elemente in einer Flexbox oder Grid-Container, hier vertikal für handy */
    margin: 0 auto;
    
    /* Padding o- zum container */
    padding-top: 10px;
    
    /* Höhe = verfügbare Höhe minus 50px verhindert vert. scrollen im container */
    height: calc(100svh - var(--header-height) - var(--footer-height) - 50px);
    
    overflow-y: hidden;     
  }

  

  .index-galerie .slideshow {
    flex: 1 1 auto;
    width: 100%;
    aspect-ratio: auto;                /* responsive */
  }

  .slideshow img {
    object-fit: contain;
    width: 100%;
    height: auto; 
  }
}

/* Hover nur hoverfähige Geräte z. B. Maus Desktop */
@media (hover: hover) {
    .slideshow:hover .caption {
        background: rgba(0,0,0,0.6);
    }
}

/* ==============================
   SLIDESHOW index.php
============================== */

/* beschleunigt Darstellung erstes Bild */
.slideshow img:first-child {
    opacity: 1;
}

.slideshow img.active {
    opacity: 1;
}

.slideshow {
    position: relative; /*sehr wichtig, sonst keine richtige Positionierung der slideshow */
    isolation: isolate;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #eee;
    will-change: opacity;
    z-index: 10;
}

.slideshow img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.9s ease; /* langsamer für Gallerie */
    z-index: 1;
}

.slideshow img.active {
    opacity: 1;
}

.slideshow .caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;

    background: rgba(0,0,0,0.45);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    color: #fff;
    text-align: center;
    padding: 0.75rem;

    z-index: 2;
}

/* nur wenn text und icon in einer Zeile */
.caption-inline {
    display: inline-flex; /* erlaubt Icon direkt neben Text */
    align-items: center;  /* vertikal zentrieren */
    gap: 5px;             /* Abstand zwischen Pfeil und Tür */
}

/* A Door index-gallerie */
.door-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 70px;
    border-radius: 5px;

    /* Glas-Effekt */
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    border: 1px solid rgba(255, 255, 255, 0.18);

    /* weicher Schatten */
    box-shadow: 
        0 8px 20px rgba(0, 0, 0, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);

    perspective: 600px;
    transition: all 0.3s ease;
}

/* leichter Hover-Glow */
.slideshow:hover .door-wrapper {
    box-shadow: 
        0 10px 25px rgba(0, 0, 0, 0.35),
        0 0 15px rgba(255, 255, 255, 0.15);
}

/* Tür */
.door {
    width: 65%;
    height: 65%;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 3px;
    transform-origin: left;
    transition: transform 0.7s cubic-bezier(.2,.8,.2,1);

    box-shadow: inset -2px 0 6px rgba(0,0,0,0.15);
}

/* Tür öffnen */
.slideshow:hover .door {
    transform: rotateY(-100deg);
}

.door-wrapper::before {
    content: "";
    position: absolute;
    width: 100%;
    height: 50%;
    top: 0;
    left: 0;
    border-radius: 10px;
    background: linear-gradient(
        to bottom,
        rgba(255,255,255,0.25),
        transparent
    );
    pointer-events: none;
}

.door-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 3; /* über Bild + Caption */

    display: flex;
    align-items: center;
    justify-content: center;
}

/* E Door index-gallerie */
/* A Portal */
/* Overlay mittig */
.portal-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Portal Wrapper mit Glas & Glow */
.portal-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    border-radius: 50%;

    background: transparent;              /* komplett transparent */
    backdrop-filter: none;                /* kein Glas */
    border: none;                         /* kein Rahmen */

    box-shadow:
        0 0 20px rgba(0,255,255,0.3);     /* nur Glow */

    transition: all 0.3s ease;
}

/* Hover Glow & Skalierung */
.slideshow:hover .portal-wrapper {
    box-shadow:
        0 0 30px rgba(0,255,255,0.3),
        inset 0 0 15px rgba(0,255,255,0.15);
    transform: scale(1.05);
}

/* Portal selbst */
.portal {
    width: 100%;
    height: 100%;
    border-radius: 50%;

    background: transparent;  /* keine Fläche */
    border: 2px solid rgba(0,255,255,0.6);  /* leuchtender Ring */

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow:
        0 0 10px rgba(0,255,255,0.6),
        0 0 25px rgba(0,255,255,0.4);

    animation: pulsePortal 2.5s infinite alternate;
}

/* Pulsieren */
@keyframes pulsePortal {
    0% {
        box-shadow:
            0 0 8px rgba(0,255,255,0.5),
            0 0 15px rgba(0,255,255,0.3);
    }
    100% {
        box-shadow:
            0 0 20px rgba(0,255,255,0.8),
            0 0 35px rgba(0,255,255,0.5);
    }
}


/* Knopf im Portal */
.portal-button {
    padding: 0.4rem 0.9rem;
    background: transparent;
    color: white;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;  /* semi-bold */
    transition: all 0.3s ease;
    z-index: 2;
}

.portal-button:hover {
    border-color: rgba(0,255,255,0.9);
    color: rgba(0,255,255,1);
}

/* Partikel im Portal */
.portal-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    background: radial-gradient(circle, rgba(0,255,255,0.25) 2%, transparent 50%);
    background-size: 8px 8px;
    animation: moveParticles 4s linear infinite;
    z-index: 1;
}

@keyframes moveParticles {
    0% { background-position: 0 0; }
    100% { background-position: 16px 16px; }
}

/* E Portal */
/*E Slideshow in index.php*/

/*A Galerie in gallerie.php  */

/* A lazy load der Bilder unsichtbar bis Bild geladen */
.lazy-img {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

/* Sichtbar, sanfter Fade-In */
.lazy-img.visible {
    opacity: 1;
}
/* E lazy load der Bilder unsichtbar bis Bild geladen */

#gallery { display: flex; flex-direction: column; gap: 25px; 
    max-width: 1000px; margin: 1px auto; background: rgba(27,25,25,0.85);
    padding: 20px; border-radius: 10px;
}

.card { display: flex; flex-direction: row; gap: 25px; background: rgba(240,240,240,0.85); 
    border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,0.2); padding: 20px; 
    cursor: default; transition: transform 0.2s;
    align-items: flex-start; /* 🔑 WICHTIG das watermark im Bild bleibt*/
    position: relative;
    z-index: 1;
    transform: translateZ(0); /* 🔑 erzwingt eigenen Layer */
}

/* Thumbnail für Kunstdruck */
.thumbnail {
    display: block;
    width: 70px;        /* feste Thumbnail-Breite */
    height: 70px;       /* feste Höhe für ein sauberes Raster */
    object-fit: cover;   /* Bild wird passend zugeschnitten */
    border-radius: 6px;  /* optional: leicht abgerundete Ecken */
    border: 1px solid #ccc;
    cursor: default;
}

@media (max-width: 768px) {   
  /* Card untereinander statt nebeneinander */
  .card {
    flex-direction: column;
    align-items: center;
  }
}

/* für sehr kleine Handys Anfang*/
@media (max-width: 480px) {  
  /* Card untereinander statt nebeneinander */
  .card {
    flex-direction: column;
    align-items: center;
  }  
 }
/* für sehr kleine Handys Ende*/

.card:hover { transform: translateY(-3px); box-shadow: 0 15px 35px rgba(0,0,0,0.25);
}

.img-wrapper {
    position: relative;
    display: inline-block;   /* 🔥 statt inline-flex */
    flex-shrink: 0;
}

/* für Bilder die geringere Höhe als die Card haben */
@media (min-width: 769px) {
.img-wrapper { display: inline-flex; }
}

.img-wrapper img:not(.thumbnail) {
    display: block;          /* 🔥 verhindert Unterkante-Abstand */
    width: 250px;
    height: auto;
    border-radius: 6px; 
    cursor: zoom-in;
}

/* Container für alle Buttons */
.img-wrapper .button-container {
    position: absolute;
    top: 10px;       /* Abstand vom oberen Rand des Bildes */
    left: 10px;      /* Abstand vom linken Rand */
    display: flex;
    gap: 10px;       /* Abstand zwischen den Buttons */
    z-index: 20;     /* Buttons über dem Bild */
}

/* Basis für alle runden Buttons */
.img-wrapper .button-container a {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: #fff;
    text-decoration: none;
    cursor: pointer;
    background: rgba(228, 22, 22, 0.6);
    transition: background 0.2s, transform 0.2s;
}

.img-wrapper .button-container a:hover {
    background: rgba(0,0,0,0.85);
    transform: scale(1.1);
}

@media (max-width: 768px) {  
  /* Bild oben, volle Breite */
  .img-wrapper img {
    width: 100%;
    max-width: 100%;
    height: auto;
  }
}
/* für sehr kleine Handys Anfang*/
@media (max-width: 480px) {
  /* Bild oben, volle Breite */
  .img-wrapper img {
    width: 100%;
    max-width: 100%;
    height: auto;
  }
 }
/* für sehr kleine Handys Ende*/

.watermark {
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;

    font-size: 16px;
    color: rgba(255,255,255,0.7);
    background: rgba(0,0,0,0.4);
    padding: 4px 8px;

    pointer-events: none;
    user-select: none;
}

.text { flex: 1; display: flex; flex-direction: column;
}
.kunstdruck-hinweis {
    text-align: left; /* oder center, wie du willst */
    margin: 0; font-size: 14px; color: #222;
}
.text h2 { margin: 0 0 5px; font-size: 18px; color: #222;
}
.text h3 { margin: 0 0 5px; font-size: 22px; color: #222;
}
.text p { margin: 5px 0; font-size: 15px; color: #555;
}
.text p.druck-hinweis { font-size: 18px; font-weight: 900; color: #a01919; margin-top: 8px;
}

/* Text-Blöcke in card Abstand zw den Blöcken für doppelten Durchlauf Original und Druck erstellen*/
.text-block + .text-block {
    margin-top: 30px; /* Abstand nur zwischen Blöcken */
}

/* A 14.06.2026 Beschreibungsfeld in rechter Spalte in bildcard */
.card-columns {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
}

.card-left {
    flex: 1;
}

.card-right {
    flex: 1;
    min-width: 250px;
}

.card-right h4 {
    margin-top: 0;
}

.card-right p {
    white-space: pre-line; /* Zeilenumbrüche aus Datenbank anzeigen */
}

@media (max-width: 768px) {
    .card-columns {
        flex-direction: column;
    }
}
/* E 14.06.2026 Beschreibungsfeld in rechter Spalte in bildcard */

@media (max-width: 768px) {  
  /* Text unter dem Bild */
  .text {
    width: 100%;
    margin-top: 12px;
    text-align: left;
  }
}

/* ===== Lightbox ===== */
/* Die Lightbox selbst */
/* 04.03.2026 lightbox neu strukturiert und zusammengefasst */
/* ==============================
   LIGHTBOX – FINAL CLEAN VERSION
============================== */

/* Overlay */
#lightbox {
    display: none;  
    position: fixed;
    inset: 0;                     /* statt top/left/width/height */
    background: rgba(0, 0, 0, 0.85);

    justify-content: center;
    align-items: center;

    z-index: 1000;
}

/* Aktiv */
#lightbox.active {
    display: flex;
}

/* Content-Container */
.lightbox-content {
    position: relative;

    width: 95vw;
    height: 90vh;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;
}

/* Bild-Wrapper */
.lightbox-img-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;

    background: #111;
}

/* Bild */
.lightbox-img-wrapper img {
    max-width: 95vw;
    max-height: 90vh;

    width: auto;
    height: auto;

    object-fit: contain;
    pointer-events: none;

    display: block;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

/* Close-Button */
.lightbox-close {
    position: absolute;
    top: 20px;
    right: 25px;
    background: rgba(0, 0, 0, 0.1);
    padding: 16px 16px; /* größerer hit-Bereich */

    font-size: 30px;
    color: #fff;
    cursor: pointer;

    z-index: 2000;
    pointer-events: auto;

    transition: opacity 0.2s ease;
}

.lightbox-close:hover {
    opacity: 0.7;
}

/* 18.03.2026 A für zoomfunktion in lightbox */
#lightbox-img-container {
    overflow: hidden;
    touch-action: none; /* 🔥 verhindert Browser-Zoom */
}

#lightbox-img-container img {
    max-width: 100%;
    max-height: 90vh;
    transition: transform 0.1s ease;
    will-change: transform;
}
/* 18.03.2026 E für zoomfunktion in lightbox */

/* Optional: Watermark */
.watermark-lightbox {
    position: absolute;
    top: 50%;
    left: 50%;

    transform:
        translate(-50%, -50%)
        rotate(-30deg)
        translateY(-10%);

    font-size: 32px;
    font-weight: 600;
    letter-spacing: 1px;

    white-space: nowrap;
    pointer-events: none;
    user-select: none;

    z-index: 10;

    transition: color 0.3s ease, text-shadow 0.3s ease;
}
/* 04.03.2026 lightbox neu strukturiert und zusammengefasst */

/* 04.03.2026 deaktiviert kein swipe
.lightbox-arrow { position: absolute; top: 50%; font-size: 50px; color: rgba(255,255,255,0.6); 
    cursor: pointer; user-select: none; transform: translateY(-50%);
}
.lightbox-arrow.left { left: 12px;}
.lightbox-arrow.right { right: 12px;}
.lightbox-arrow:hover { color: #fff;}
 04.03.2026 deaktiviert kein swipe */

/* E Galerie in gallerie.php  */

/* A slideshow für Historie der Bilder im Status in Bearbeitung in historie.php */
/* A Zurück button in historie.php */
.close-btn {
    position: fixed;
    top: 16px;
    right: 16px;
    background: rgba(0, 0, 0, 0.1);
    padding: 16px 16px; /* größerer hit-Bereich */
    color: #fff;
    border: none;
    font-size: 32px;
    line-height: 1;
    
    cursor: pointer;
    border-radius: 4px;
    z-index: 1000;
    transition: background 0.3s;
}

.close-btn:hover {
    background: rgba(0,0,0,0.85);
}
/* E Zurück button in historie.php */

.bildzähler {
    margin-bottom: 10px;
}

body.historie .bildzähler {
    position: fixed;
    top: 16px;
    left: 0;
    right: 0;

    display: flex;
    justify-content: center;
    text-align: center;  
    font-size: 18px;
    line-height: 1.5;
    opacity: 0.7;
    pointer-events: none;

    z-index: 900;
}

.slideshow-container-historie {
    position: relative;
    width: 90vw;
    height: 80vh;
}

.slideshow-container-historie picture {
    position: absolute;
    top: 10px;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
    border-radius: 8px;
    z-index: 1;
}

.slideshow-container-historie picture.active {
    opacity: 1;
    z-index: 2;
}

.slideshow-container-historie picture img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 8px;
}
/* E slideshow für Historie der Bilder im Status in Bearbeitung in historie.php */

/* A Runde Funktionsbotton in den Galerie-Bilder*/
.email-box, .download-btn, .bearbeitung-btn, .desc-btn {
    position: static;
    top:auto;
    left:auto;
    width: 38px;
    height: 38px;
    background: rgba(228, 22, 22, 0.6);
    color: #fff;
    font-size: 18px;
    text-decoration: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: auto;
    transition: background 0.2s, transform 0.2s;
}

.email-box:hover, .download-btn:hover, .bearbeitung-btn:hover, .desc-btn:hover {
    background: rgba(0,0,0,0.85);
    transform: scale(1.1);
}
/* E Runde Funktionsbotton in den Galerie-Bilder*/

/* 10.03.2026 A neuer Beschreibungsbutton */
#desc-overlay{
position:fixed;
top:0;
left:0;
width:100%;
height:100%;
background:rgba(0,0,0,0.7);
display:none;
align-items:center;
justify-content:center;
z-index:9999;
}

.desc-box{
background:white;
max-width:700px;
width:90%;
padding:30px;
border-radius:10px;
position:relative;
max-height:80vh;
overflow:auto;
}

.desc-close{
position:absolute;
top:10px;
right:10px;
border:none;
background:none;
font-size:20px;
cursor:pointer;
}

.desc-title{
margin-top:0;
}

.desc-content{
line-height:1.6;
}
/* 10.03.2026 E neuer Beschreibungsbutton */

/* A Datenschutz */
.datenschutz {
    margin: 20px auto;
    max-width: 600px;
    padding: 20px;
    border: 1px solid #ccc;
    border-radius: 8px;
    background-color: rgba(123, 176, 230, 0.7); /* rgba für durchscheinenden Hintergrund */
    text-align: left; /* Für linksbündige Ausrichtung der Inhalte */
}

/* A Formular Stil */
/* Formular-Stil */
form {
    margin: 20px auto;
    max-width: 600px;
    padding: 20px;
    border: 1px solid #ccc;
    border-radius: 8px;
    background-color: rgba(123, 176, 230, 0.7); /* rgba für durchscheinenden Hintergrund */
    text-align: left; /* Für linksbündige Ausrichtung der Inhalte */
}

/* Formular-Gruppe */
.form-group {
    margin-bottom: 5px;
    width: 100%; /* Damit die Gruppe die gesamte Breite einnimmt */
}

/* Labels */
label {
    display: block;
    font-weight: bold;
}

/* Eingabefelder und Textareas */
input, textarea {
    width: 100%; /* Setzt die Breite auf 100% der Container-Breite */
    padding: 5px;
    margin-top: 5px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box; /* Stellt sicher, dass Padding und Border in der Breite enthalten sind */
}

/* Button */
.submit-btn {
    background-color: #4CAF50;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    width: 100%; /* Button wird über die gesamte Breite gezogen */
}

.submit-btn:hover {
    background-color: #45a049;
}

/* A Formular Stil */

/* Footer */
/* fix am unteren BS-Rand */
footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: var(--footer-height);
    background: #fff;
    color: #000;
    z-index: 100;

    display: flex;
    justify-content: center;
    align-items: center;
}

.site-footer-inner {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 100px;
    max-width: 1200px;
    width: 100%;
    font-size: 14px;
}

.footer-left, .footer-right {
    color: #777;
}

.footer-left a,
.footer-right a {
    text-decoration: none;
    color: inherit;
}

.footer-left a:hover,
.footer-right a:hover {
    color: #000;
    text-decoration: underline;
}

@media (max-width: 768px) {   
    .site-footer-inner {
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }
}

/* A 14.06.2026 bilder_bearbeiten_einzelsatz.php */
/* A Formular mit 4 Spalten Dateibearbeitung werkverzeichnis.csb Stil */
.form-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px 12px;
}

.form-field {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.form-field label {
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 2px;
}

.form-field input,
.form-field textarea,
.form-field select {
    width: 100%;
    box-sizing: border-box;

    padding: 3px 6px;
    margin: 0;

    font-size: 13px;
    line-height: 1.2;
}

textarea {
    width: 100%;
    min-height: 100px;
    font-family: inherit;
    resize: vertical;
}

form {
    width: 95%;
    max-width: 1800px;
}
/* E Formular mit 4 Spalten Dateibearbeitung werkverzeichnis.csb Stil */

/* A 14.06.2026 Datensatz Container  */
.datensatz-container {
    flex: 1;
    min-width: 0;
    padding: 5px;
    margin: 5px;
    border: 3px solid #641010;
    border-radius: 8px;
    background: #fff;
}

.datensatz-container h3 {
    margin-bottom: 5px;
    font-size: 14px;
}

.datensatz-container.highlight {
    border: 2px solid #2d6cdf;
    box-shadow: 0 0 12px rgba(45,108,223,0.3);
    animation: fadeInHighlight 1.2s ease;
}

/* Animation überblendung Farbe */
@keyframes fadeInHighlight {
    from { background-color: #e8f1ff; }
    to   { background-color: #ffffff; }
}


.navigation-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;   /* Abstand zwischen den drei Elementen */
    margin-bottom: 20px;
}

/* A 14.06.2026 Upload-Box  */
.upload-wrapper {
    display: flex;
    gap: 20px;
    margin: 0;
}

/* Upload bleibt kompakt */
.upload-container {
    flex: 1;
    min-width: 0;
    padding: 5px;
    margin: 5px;
    border: 3px solid #641010;
    border-radius: 8px;
    background: #fff;
}

.upload-container h3 {
    margin: 0 0 8px 0;
    font-size: 14px;
}

/* eine Zeile */
.row-inline {
    display: flex;
    gap: 4px;
    font-size: 12px;
    margin-bottom: 3px;
    align-items: center;
}

/* Inputs gleich hoch */
.row-inline input,
.row-inline select {
    height: 24px;
    font-size: 12px;
    padding: 1px 4px;
    border: 1px solid #ccc;
    border-radius: 5px;
    flex: 1;
}

/* Datei etwas breiter */
.row-inline input[type="file"] {
    flex: 2;
}

/* Button klein */
.row-inline button {
    font-size: 12px;
    height: 24px;
    padding: 0 8px;
    border: none;
    border-radius: 5px;
    background: #2d6cdf;
    color: white;
    cursor: pointer;
}

.row-inline button:hover {
    background: #1f56b8;
}

/* E 14.06.2026 Upload-Box  */

/* A 14.06.2026 Anzeigen des Bildes aus dem aktiven Datensatz  */

.image-preview {
    position: fixed;
    right: 10px;
    bottom: 10px;

    width: 220px;
    height: auto;

    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 8px;

    box-shadow: 0 2px 10px rgba(0,0,0,0.15);
    z-index: 9999;
}

.image-preview img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 6px;
}
/* E 14.06.2026 Anzeigen des Bildes aus dem aktiven Datensatz  */
/* E 14.06.2026 bilder_bearbeiten_einzelsatz.php */

/* A 14.06.2026 bilder_bearbeiten.php */
/* A Scrollen horizontal und vertikal mit Header in Tabelle fixiert  */

/* style wie upload-container auf selben Seite */
.tabelle {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    min-width: 5px;
    padding: 5px;
    margin: 5px;
    border: 3px solid #250d0d;
    border-radius: 8px;
    background: whitesmoke;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.tabelle h3 {
    margin: 0 0 8px 0;
    font-size: 14px;
}

/* wirkt nur für diese Seite über <body class=page-tablr>*/
.page-table {
    height: 100vh;
    margin: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden; /* verhindert doppeltes Scrollen */
}

/* oberer Bereich 2 button und Datei hochladen, bleibt fix */
.topbar-table {
    flex: 0 0 auto;
}

/* Datenbereich der scrollbaren Tabelle füllt den Rest */
.table-scroll {
    flex: 1;              /* <<< das ist der Trick */
    height: 100vh;
    overflow: auto;
    font-size: 12px;
    border: 1px solid #ccc;
}
/* Tabellenlinien */
table {
    border-collapse: collapse;
    width: 100%;
}

thead th {
    position: sticky;
    top: 0;
    background: #bc9ae7;
    z-index: 1000;
    /*border: 1px solid #000;*/
    box-shadow: 0 2px 0 #000; /* optional für „dicke Linie“, stabiler als border */
}

tbody td {
    border: 1px solid #ccc;
}

th,
td {
    padding: 4px 6px;
    border-right: 1px solid #ccc;
    border-bottom: 1px solid #ccc;
}

/* Breite der Aktionsspalte für Kopf und Daten für 3 button*/
.Aktion-Breite {
    width: 70px;
    min-width: 70px;
}
/* E Scrollen horizontal und vertikal mit Header in Tabelle fixiert  */
/* E 14.06.2026 bilder_bearbeiten.php */