/* Map of all investments (/mapa-inwestycji/), values of the old theme (main.css, .page-template-page-mapa-inwestycji). */

.page-map .site-header {
    z-index: 1100;
}

/* The map reaches the footer: no gap above it (the old theme removed the margin on this template too). */
.page-map .site-footer {
    margin-top: 0;
}

.map-page {
    position: relative;
    height: calc(100vh - 76px);
    height: calc(100dvh - 76px);
}

.map-page__canvas {
    width: 100%;
    height: 100%;
}

.map-page__toggle {
    position: absolute;
    top: 10px;
    left: 60px;
    z-index: 999;
    padding: 6px 14px;
    border: solid var(--line) 2px;
    border-radius: var(--radius);
    background: var(--paper);
    font-size: 0.8rem;
    cursor: pointer;
}

.map-filters {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1002;
    width: 300px;
    padding: 20px;
    border-right: 1px solid var(--line);
    background: var(--paper);
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.2);
    transform: translateX(-100%);
    transition: transform 0.3s;
}

.map-filters.is-open {
    transform: translateX(0);
}

.map-filters__group {
    margin-bottom: 20px;
}

.map-filters__group p {
    margin-bottom: 10px;
    font-weight: 700;
}

.map-filters__buttons {
    display: flex;
    gap: 10px;
}

.map-filters__button {
    padding: 10px 20px;
    border: solid var(--red) 2px;
    border-radius: var(--radius);
    background-color: var(--paper);
    cursor: pointer;
    transition: background-color 0.2s;
}

.map-filters__button.is-active {
    border-color: #e8132f;
    background-color: #e8132f;
    color: white;
}

.map-filters__button:hover {
    background-color: rgba(232, 19, 47, 0.1);
    color: #000;
}

.map-filters__close {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 10px;
    border: none;
    border-radius: var(--radius);
    background: var(--red);
    color: #fff;
    font-size: 0.9rem;
    cursor: pointer;
}

.page-map .map-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border: 2px solid red;
    border-bottom-width: 4px;
    border-radius: 50%;
    background: white;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.page-map .map-marker svg {
    width: 16px;
    height: 16px;
}

@media (max-width: 993px) {
    .page-map .leaflet-top {
        top: 20px;
        z-index: 999;
    }

    .map-page__toggle {
        top: 30px;
    }

    .map-filters {
        top: 15px;
    }
}
