/* MAP STYLES */
.map .ol-overviewmap { bottom: 3.5rem; }

.follow-control { left: 0.5em; top: 5em; background: #ffffffaa; }

.full-map {
    width: 100%;
    height: calc(100vh - 120px);
    max-height: none;
}

/* MAP ICONS */
.ol-download-map {
    right: 0.5em; 
    top: 2.5em;
}

.ol-windy-map {
    right: 0.5em; 
    top: 4.5em;
}

.ol-layer-switcher {
    right: 0.5em; 
    top: 6.5em;
}

.ol-layer-switcher button {
    font-size: 1.2rem;
    line-height: 1.2rem;
}

.ol-ruler-map {
    right: 0.5em; 
    bottom: 2.5em;
}

/* MEASUREMENT DIALOG STYLES */
.measurement-dialog {
    position: fixed;
    bottom: 3em;
    left: calc(50% - 64px);
    background: white;
    border: 2px solid #ccc;
    border-radius: 8px;
    padding: 24px 16px 16px 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    font-family: Arial, sans-serif;
    font-size: 12px;
    z-index: 10000;
    min-width: 128px;
}

.measurement-dialog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 8px auto;
    font-weight: bold;
    color: #333;
}

.measurement-dialog-close {
    position: absolute;
    top: 4px;
    right: 4px;
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.measurement-distance-display {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 15px;
    text-align: left;
}

.measurement-dialog-clear {
    background: #dc3545;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    width: 100%;
}

/* MEDIA QUERIES */
@media screen and (max-width: 600px) {
    .map {
        width: 100%;
        height: 45vh;
        margin-bottom: 2vh;
    }
    
    .ol-touch .ol-control button {
        font-size: 1.25em !important;
    }

    .ol-attribution {
        max-width: 50vw !important;
    }
    
    .full-map {
        width: 100%;
        height: calc(100vh - 120px);
        max-height: none;
        margin-bottom: 0;
    }

    .measurement-dialog,
    .measurement-distance-display {
        font-size: 12px;
    }
}

@media screen and (min-width: 800px) {
    .definition-map-container .map {
        width: 100%;
        height: 100%;
        min-height: 70vh;
    }

    .map {
        width: 100%;
        height: 70vh;
        max-height: 78vh;
    }
    
    #plot_creation_map {
        height: 75vh;
    }
    
    .full-map {
        width: 100%;
        height: calc(100vh - 120px);
        max-height: none;
    }
}