/* Base Styles */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 1rem;
}

#map {
    height: 60vh;
    width: 99%;
    margin-bottom: 1rem;
}

input[type="text"],
input[type="file"],
input[type="date"],
button {
    font-size: 1rem;
    padding: 0.5rem;
    box-sizing: border-box;
    width: 100%;
    margin-bottom: 0.75rem;
}

input[type="file"] {
    margin-top: 0.5rem;
}

img.thumb {
    max-width: 100px;
    cursor: pointer;
    border-radius: 5px;
}

#preview img {
    max-width: 200px;
    margin: 5px;
}

/* Header */
header {
    background-color: #5cb85c;
    color: white;
    padding: 0.5rem 1rem;
    text-align: center;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    position: relative;
    flex-wrap: wrap;
}

.logo {
    height: 80px;
}

.header-content h1 {
    margin: 0 auto;
    text-align: center;
    font-size: clamp(1.5rem, 4vw, 2rem);
    flex: 1;
}

/* Buttons */
.header-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.add-button,
.storie-button {
    font-size: 1.8rem;
    cursor: pointer;
    color: #fff;
    transition: transform 0.2s;
    text-align: right;
}

.add-button:hover,
.storie-button:hover {
    transform: scale(1.1);
}

/* Footer */
footer {
    background-color: #f2f2f2;
    color: #333;
    padding: 1rem;
    text-align: center;
    position: relative;
    bottom: 0;
    width: 100%;
}

/* Modal Overlay */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

/* Modal Content */
.modal-content {
    position: relative;
    background-color: #fff;
    width: 90%;
    max-width: 400px;
    max-height: 600px;
    padding: 2rem 1rem 1rem 1rem; /* Platz oben für Close-Button */
    border-radius: 8px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
    overflow-y: auto;
    box-sizing: border-box;
}

/* Close-Button */
.close-button {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    font-size: 1.5rem;
    background: none;
    border: none;
    cursor: pointer;
    color: #555;
    z-index: 10;
}

.close-button:hover {
    color: #000;
    transform: scale(1.1);
}

/* Modal Footer */
.modal-footer {
    margin-top: 1rem;
    text-align: center;
}

.modal-footer button {
    padding: 0.5rem 1rem;
    font-size: 1rem;
    cursor: pointer;
}

/* Lightbox */
#lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

#lightboxContent {
    max-width: 90%;
    max-height: 90%;
    overflow: auto;
    background: #fff;
    padding: 1rem;
    border-radius: 8px;
}

#lightboxContent button {
    float: right;
    font-size: 1.25rem;
    background: none;
    border: none;
    cursor: pointer;
}

/* Upload */
#uploadStatus {
    display: none;
    padding: 1rem;
}

#uploadProgress {
    width: 100%;
}

#markerForm{
    padding-top: 2rem;
    padding-right: 1rem;
    padding-bottom: 1rem;
    padding-left: 1rem;
}

/* Marker Gallery */
#markerGallery {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .header-content h1 {
        font-size: 1.3rem;
    }

    .header-buttons {
        gap: 0.5rem;
    }

    .add-button,
    .storie-button {
        font-size: 1.5rem;
        margin-left: 0;
        margin-top: 0.5rem;
        align-self: center;
    }

    #map {
        height: 50vh;
    }

    img.thumb {
        max-width: 80px;
    }
}
