body {
    margin: 0;
    padding: 0;
    background-color: #000;
    color: #fff;
    font-family: Arial, sans-serif;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    text-align: center;
}

.intro {
    margin-bottom: 40px;
}

.intro h1 {
    font-size: 2.5em;
    margin: 0;
}

.intro p {
    font-size: 1.2em;
}

.gallery {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 80vh;
    position: relative;
    flex-direction: column; /* Für Titel unter dem Bild */
}


.image-container {
    max-width: 90%;
    max-height: 70vh;
    padding: 20px; /* Keep padding for the border/frame effect */

    /* --- Changes for Matte Paper Look --- */
    background-color: #f8f8f8; /* A very light off-white, like natural paper */
    border: 1px solid #e0e0e0; /* A very subtle light grey border for definition */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2), /* Softer, slightly larger shadow for depth */
                0 0 0 10px rgba(255, 255, 255, 0.1) inset; /* Optional: A very subtle inner shadow to mimic thickness */
    /* You had: box-shadow: 0 0 20px rgba(255, 255, 255, 0.1); */

    /* Optional: Slight rotation for a less perfect, more 'real' feel */
    /* transform: rotate(-0.5deg); */ /* Uncomment and adjust if you like a subtle tilt */

    /* --- Existing properties (ensure these are present) --- */
    display: flex;
    flex-direction: column;
    align-items: center;
}
/*
.image-container {
    max-width: 90%;
    max-height: 70vh; /* Etwas weniger, um Platz für den Titel zu lassen */ /*
    padding: 20px;
    background: #fff;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column; /* Bild und Titel untereinander */ /*
    align-items: center;
}
*/

#gallery-image {
    max-width: 100%;
    max-height: 60vh; /* Angepasst, um den Titel nicht zu überschneiden */
    object-fit: contain;
    margin-bottom: 10px; /* Abstand zum Titel */
}
#gallery-image-title { /* Nutze die ID für höchste Spezifität */
    color: #000 !important; /* Schwarz für Sichtbarkeit auf weißem Hintergrund - Hinzugefügt !important als letzte Maßnahme */
    font-size: 1.2em;
    /* font-weight: bold; */ /* Hier ist es auskommentiert, wie in deinem Beispiel */
    margin-top: 0;
}

.nav-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 2em;
    cursor: pointer;
    padding: 10px;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
}

#prev-btn {
    left: 10px;
}

#next-btn {
    right: 10px;
}

.nav-btn:hover {
    color: #ccc;
}

/* Mobile Swipe Optimierung */
@media (max-width: 768px) {
    .image-container {
        max-width: 95%;
        padding: 10px;
    }

    #gallery-image {
        max-height: 50vh; /* Weiter angepasst für Mobilgeräte */
    }

    .nav-btn {
        font-size: 1.5em;
    }
}

/* ADMIN-SEITEN SPEZIFISCHE STYLES */
.admin-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 30px;
    /* NEU: Ermöglicht Drag-and-Drop */
    min-height: 200px; /* Mindesthöhe für Drag-and-Drop-Bereich */
    border: 2px dashed #444; /* Visueller Hinweis auf Drag-and-Drop-Bereich */
    padding: 10px;
    position: relative; /* Für Sortable.js Ghost-Effekt */
}
.admin-gallery-item {
    background: #222;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    cursor: grab; /* Zeigt an, dass es verschiebbar ist */
    position: relative; /* Für das Sortable.js Ghost-Element */
}
.admin-gallery-item.sortable-ghost {
    opacity: 0.2;
    background-color: #555;
    border: 2px dashed #888;
}
.admin-gallery-item img {
    max-width: 100%;
    height: auto;
    margin-bottom: 10px;
    border: 1px solid #444;
}
.admin-gallery-item input[type="text"] {
    width: calc(100% - 20px);
    padding: 8px;
    margin-bottom: 10px;
    border: 1px solid #555;
    background: #333;
    color: #eee;
    border-radius: 4px;
}
.admin-gallery-item button {
    background-color: #007bff;
    color: white;
    padding: 8px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-right: 5px;
    margin-top: 5px; /* Abstand zwischen den Buttons */
}
.admin-gallery-item button.delete {
    background-color: #dc3545;
}
.admin-gallery-item button:hover {
    opacity: 0.9;
}
.admin-actions {
    margin-top: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; /* Für kleinere Bildschirme */
}
.admin-actions p, .admin-actions form {
    margin-bottom: 10px;
}
/* NEU: Stil für den "Reihenfolge speichern"-Button */
#save-order-btn {
    background-color: #28a745; /* Grüne Farbe */
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    font-size: 1.1em;
    cursor: pointer;
    margin-top: 20px; /* Abstand nach oben */
    transition: background-color 0.3s ease;
}
#save-order-btn:hover {
    background-color: #218838; /* Dunkleres Grün beim Hover */
}