﻿body {
    overscroll-behavior: none;
}

#map {
    height: 60vh;
    min-height: 400px;
    z-index: 1;
}

@media (min-width: 1024px) {
    #map {
        height: 600px;
    }
}

/* Custom Styles */
.loader {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #4f46e5;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.map-drawing-mode {
    cursor: crosshair !important;
    border: 4px solid #ef4444;
    touch-action: none;
}

.map-measuring-mode {
    cursor: crosshair !important;
}

.leaflet-popup-content-wrapper {
    border-radius: 12px;
    padding: 0;
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1);
}

.leaflet-popup-content {
    margin: 0 !important;
    width: 260px !important;
}

.leaflet-popup-tip-container {
    display: none;
}

/* Menu Animations */
#side-menu {
    transition: transform 0.3s ease-in-out;
}

.menu-open {
    transform: translateX(0) !important;
}

.menu-closed {
    transform: translateX(100%) !important;
}

/* Range Slider */
.range-slider {
    position: relative;
    width: 100%;
    height: 20px;
    margin-top: 10px;
    touch-action: none;
}

    .range-slider input[type=range] {
        position: absolute;
        left: 0;
        bottom: 0;
        width: 100%;
        height: 100%;
        -webkit-appearance: none;
        pointer-events: none;
        background: none;
        z-index: 10;
    }

        .range-slider input[type=range]::-webkit-slider-thumb {
            pointer-events: auto;
            -webkit-appearance: none;
            width: 28px;
            height: 28px;
            border-radius: 50%;
            cursor: pointer;
            opacity: 0;
        }

.slider-track {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    height: 6px;
    background: #e5e7eb;
    border-radius: 3px;
    z-index: 1;
}

.slider-range {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    height: 6px;
    background: #4f46e5;
    z-index: 2;
    border-radius: 3px;
}

.slider-thumb {
    position: absolute;
    top: 50%;
    left: 0;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    background: #fff;
    border: 2px solid #4f46e5;
    border-radius: 50%;
    z-index: 3;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
    pointer-events: none;
}

/* Amenity Toggles */
.amenity-active {
    background-color: #e0e7ff !important;
    border-color: #6366f1 !important;
    color: #4338ca !important;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

.custom-amenity-icon div {
    transition: transform 0.2s;
}

    .custom-amenity-icon div:hover {
        transform: scale(1.2);
    }

/* Markdown Styles for AI Content */
.markdown-body h1 {
    font-size: 1.5em;
    font-weight: 800;
    margin-bottom: 0.5em;
    color: #1f2937;
}

.markdown-body h2 {
    font-size: 1.25em;
    font-weight: 700;
    margin-top: 1em;
    margin-bottom: 0.5em;
    color: #3730a3;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 4px;
}

.markdown-body h3 {
    font-size: 1.1em;
    font-weight: 700;
    margin-top: 1em;
    margin-bottom: 0.25em;
    color: #4b5563;
}

.markdown-body p {
    margin-bottom: 0.8em;
    line-height: 1.6;
    color: #4b5563;
}

.markdown-body ul {
    list-style-type: disc;
    padding-left: 1.5em;
    margin-bottom: 1em;
}

.markdown-body li {
    margin-bottom: 0.25em;
    color: #4b5563;
}

.markdown-body strong {
    font-weight: 700;
    color: #111827;
}

.markdown-body blockquote {
    border-left: 4px solid #6366f1;
    padding-left: 1em;
    font-style: italic;
    background: #eff6ff;
    padding: 0.5em 1em;
    border-radius: 0 4px 4px 0;
}

/* Modal Scrollbar */
#modal-content::-webkit-scrollbar {
    width: 8px;
}

#modal-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

#modal-content::-webkit-scrollbar-thumb {
    background: #c7c7c7;
    border-radius: 4px;
}

    #modal-content::-webkit-scrollbar-thumb:hover {
        background: #a8a8a8;
    }
