/* General Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

header {
    text-align: center;
    padding: 4rem 0 2rem;
    background-color: #800040;
    color: white;
    margin-bottom: 2rem;
}

header h1 {
    font-size: 2.5rem;
}

main {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 1rem 4rem;
}

/* Menu Styles */
.menu-btn {
    position: fixed;
    top: 15px;
    left: 15px;
    z-index: 1001;
    padding: 10px 20px;
    background: #800040;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}

.list-container {
    position: fixed;
    top: 60px;
    left: 15px;
    background: white;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-radius: 8px;
    z-index: 1000;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.list-container.show {
    max-height: 500px;
}

.menu-btn:hover {
    background-color: #a00050;
}

.list-container ul {
    list-style: none;
    padding: 1rem;
}

.list-container li {
    padding: 0.5rem 0;
}

.list-container a {
    text-decoration: none;
    color: #333;
    display: block;
    padding: 0.3rem 0.5rem;
    transition: background 0.2s, color 0.2s;
}

.list-container a:hover {
    background-color: #f0f0f0;
    color: #800040;
}

/* Section Styles */
.apartment-section {
    margin-bottom: 4rem;
    padding: 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.apartment-section h3 {
    color: #800040;
    margin-bottom: 1rem;
    font-size: 1.8rem;
}

.apartment-section h4 {
    margin-bottom: 1.5rem;
    color: #666;
}

.main-hero-img {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    margin-bottom: 2rem;
}

footer {
    text-align: center;
    padding: 2rem;
    background: #333;
    color: white;
}

/* Slider Layout */
.slider-container {
    position: relative;
    width: 100%;
    max-width: 500px;
    margin: 2rem auto;
    aspect-ratio: 3 / 4; /* Portrait card aspect ratio */


    background-color: #fff;
    overflow: hidden;
    user-select: none;
    touch-action: pan-y;
}

.slider-wrapper {
    width: 100%;
    height: 100%;
    position: relative;
}

.slider-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out, transform 0.5s ease;
    cursor: pointer;
}

.slider-item.active {
    opacity: 1;
    visibility: visible;
}

.slider-img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Always show image complete */
    display: block;
    background: #fff;
    padding: 5px; /* Slight padding to show border clearly */
}

/* Navigation Buttons */
.nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.8);
    color: #800040;
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.nav-btn:hover {
    background: #fff;
    transform: translateY(-50%) scale(1.1);
}

.nav-btn.prev {
    left: 10px;
}

.nav-btn.next {
    right: 10px;
}

.discovery-section {
    padding: 4rem 1rem;
    background-color: #fff;
    margin-top: 2rem;
}

.discovery-grid {
    display: grid;
    gap: 30px;
    padding: 20px 0;
}

/* Responsive columns for portrait cards */
@media (min-width: 1024px) {
    .discovery-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1023px) and (min-width: 600px) {
    .discovery-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 599px) {
    .discovery-grid { grid-template-columns: 1fr; }
}

.discovery-card {
    background: #fff;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    border: 2px solid #fff;
}

.discovery-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.2);
}

.card-image-container {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-bottom: 1px solid #eee;
}

.card-img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Always show image complete */
    background: #fff;
    transition: transform 0.5s ease;
}

.card-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.tag-container {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.category-tag, .location-tag {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
    text-transform: uppercase;
}

.category-tag {
    background: #e9ecef;
    color: #495057;
}

.location-tag {
    background: #80004015;
    color: #800040;
}

.card-content h3 {
    font-size: 1.25rem;
    color: #212529;
    margin: 0;
}

.card-details {
    font-size: 0.9rem;
    color: #6c757d;
}

.card-details p {
    margin-bottom: 0.5rem;
}

.description {
    line-height: 1.5;
    margin-bottom: 10px;
}

.extra-info {
    display: none;
    font-size: 0.85rem;
    color: #495057;
    border-top: 1px solid #eee;
    padding-top: 10px;
    margin-top: 10px;
}

.discovery-card.expanded .extra-info {
    display: block;
}

.card-actions {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding-top: 1rem;
}

.btn {
    text-align: center;
    padding: 10px 16px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.2s;
    border: none;
}

.btn-primary {
    background: #800040;
    color: white;
}

.btn-primary:hover {
    background: #a00050;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-info-toggle {
    background: transparent;
    border: 1px solid #dee2e6;
    color: #495057;
}

.btn-info-toggle:hover {
    background: #f8f9fa;
}

.no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    color: #6c757d;
    font-style: italic;
}

@media (max-width: 600px) {
    .filter-group {
        flex-direction: column;
    }
    .filter-group select {
        width: 100%;
    }

}

/* Fullscreen Overlay */
.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: auto;
    height: auto;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.overlay.active {
    display: flex;
    opacity: 1;
}

.overlay-content {
    max-width: 95%;
    max-height: 95%;
    transform: scale(0.8);
    transition: transform 0.4s ease;
}

.overlay.active .overlay-content {
    transform: scale(1);
}

#fullscreenImg {
    width: 100vw;
    height: 100vh;
    object-fit: contain;
}

.close-btn {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    color: #fff;
    cursor: pointer;
    z-index: 1010;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-btn {
        padding: 1rem 0.6rem;
        font-size: 1.2rem;
    }
    
    .dot {
        width: 10px;
        height: 10px;
    }
}

/* Booking & Calendar Styles */
.booking-container {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #eee;
}

.booking-btn {
    display: block;
    width: 100%;
    padding: 1rem;
    background-color: #800040;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.2s;
    margin-top: 1.5rem;
}

.booking-btn:hover {
    background-color: #a00050;
}

.calendar-wrapper {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 1rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.cal-nav {
    background: none;
    border: 1px solid #ddd;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.cal-nav:hover {
    background: #f0f0f0;
    border-color: #800040;
    color: #800040;
}

.current-month-year {
    font-weight: bold;
    font-size: 1.1rem;
    color: #800040;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

.day-name {
    text-align: center;
    font-size: 0.8rem;
    font-weight: bold;
    color: #666;
    padding-bottom: 5px;
}

.day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: default;
    background: #f8f9fa;
    transition: transform 0.2s;
}

.day.past {
    color: #ccc;
    text-decoration: line-through;
}

.day.available {
    background-color: #d4edda;
    color: #155724;
}

.day.pending {
    background-color: #fff3cd;
    color: #856404;
}

.day.confirmed {
    background-color: #f8d7da;
    color: #721c24;
}

.day.blocked {
    background-color: #e2e3e5;
    color: #383d41;
}

.legend {
    display: flex;
    gap: 15px;
    margin-top: 1.5rem;
    font-size: 0.85rem;
    justify-content: center;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 3px;
}

.legend-color.available { background: #d4edda; }
.legend-color.pending { background: #fff3cd; }
.legend-color.confirmed { background: #f8d7da; }

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    padding: 1rem;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    padding: 2.5rem;
    border-radius: 15px;
    max-width: 550px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.form-group {
    margin-bottom: 1.2rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
}

.form-group input, 
.form-group select, 
.form-group textarea {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
}

.form-group input:focus {
    outline: none;
    border-color: #800040;
}

/* Admin Section Styles */
.admin-container {
    max-width: 1000px;
    margin: 2rem auto;
    padding: 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.admin-section h2 {
    color: #800040;
    margin-bottom: 1.5rem;
}

.table-responsive {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.admin-table th, .admin-table td {
    padding: 12px;
    text-align: center;
    border-bottom: 1px solid #eee;
}

.admin-table th {
    background-color: #f8f9fa;
    font-weight: bold;
    color: #666;
}

.status-badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: bold;
}

.status-ausstehend { background: #fff3cd; color: #856404; }
.status-bestätigt { background: #d4edda; color: #155724; }
.status-abgelehnt { background: #f8d7da; color: #721c24; }

.action-btns {
    display: flex;
    gap: 5px;
}

.btn-small {
    padding: 4px 8px;
    font-size: 0.8rem;
    cursor: pointer;
    border: none;
    border-radius: 4px;
    transition: background 0.2s;
}

.btn-confirm { background: #28a745; color: white; }
.btn-confirm:hover { background: #218838; }
.btn-reject { background: #dc3545; color: white; }
.btn-reject:hover { background: #c82333; }
.btn-delete { background: #6c757d; color: white; }
.btn-delete:hover { background: #5a6268; }

#loginForm {
    max-width: 400px;
    margin: 0 auto;
}
p{
    text-align: center;
}
h4{
    text-align: center;
    size: 1.4rem;
}
h3{
    text-align: center;
}
h5{
    text-align: center;
    text-decoraition: bold;
    size: 1.5rem;
}
h2{
    color:#f8f8ff;
    size: 0.8rem;
}