.pmp-wrapper {
    position: relative;
    width: 100%;
    min-height: 700px;
    border-radius: 8px;
    overflow: hidden;
    background: #f3f3f3;
    font-family: "Lausanne", sans-serif;
}

.pmp-wrapper,
.pmp-wrapper button,
.pmp-wrapper input,
.pmp-wrapper select,
.pmp-wrapper textarea {
    font-family: "Lausanne", sans-serif;
}

.pmp-map-canvas {
    width: 100%;
    height: 700px;
}

.pmp-panel {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 20;
    width: 320px;
    max-width: calc(100% - 40px);
    background: #f6f4ea;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    max-height: calc(100vh - 60px);
    overflow-y: auto;
    box-sizing: border-box;
}

/* When the panel is inside a Google Maps control, reset absolute positioning */
.gm-style .pmp-panel {
    position: relative;
    top: 0;
    left: 0;
    margin: 10px;
    max-height: calc(100vh - 80px);
}

.pmp-panel h3 {
    margin: 0 0 20px;
    font-size: 28px;
    line-height: 1.2;
}

.pmp-field {
    margin-bottom: 16px;
}

.pmp-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
    font-size: 15px;
}

.pmp-field select {
    width: 100%;
    height: 46px;
    border: 1px solid #d8d8d8;
    border-radius: 6px;
    background: #fff;
    padding: 0 12px;
    font-size: 15px;
}

/* Custom multiselect */
.pmp-multiselect {
    position: relative;
}

.pmp-multiselect-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 46px;
    border: 1px solid #d8d8d8;
    border-radius: 6px;
    background: #fff;
    padding: 8px 12px;
    font-size: 15px;
    cursor: pointer;
    user-select: none;
    box-sizing: border-box;
}

.pmp-multiselect-trigger:focus {
    outline: 2px solid #7f9872;
    outline-offset: 1px;
}

.pmp-multiselect-arrow {
    font-size: 12px;
    margin-left: 8px;
    flex-shrink: 0;
    transition: transform 0.15s ease;
}

.pmp-multiselect.pmp-open .pmp-multiselect-arrow {
    transform: rotate(180deg);
}

.pmp-multiselect-label {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pmp-multiselect-dropdown {
    display: none;
    margin-top: 4px;
    border: 1px solid #d8d8d8;
    border-radius: 6px;
    background: #fff;
    max-height: 180px;
    overflow-y: auto;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.pmp-multiselect.pmp-open .pmp-multiselect-dropdown {
    display: block;
}

.pmp-multiselect-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    font-size: 14px;
    cursor: pointer;
    user-select: none;
    transition: background 0.1s;
}

.pmp-multiselect-option:hover {
    background: #f0f4ee;
}

.pmp-multiselect-option input[type="checkbox"] {
    flex-shrink: 0;
    width: 16px;
    height: 16px;
    accent-color: #7f9872;
    cursor: pointer;
    margin-right: 5px;
}

.pmp-option-label {
    flex: 1;
}

.pmp-option-count {
    flex-shrink: 0;
    color: #657b59;
    font-weight: 600;
    font-size: 13px;
}

.pmp-option-all {
    border-bottom: 1px solid #eee;
    font-weight: 600;
}

/* Energielabel range display */
.pmp-energielabel-range {
    margin-top: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #4b5f41;
    padding: 4px 8px;
    background: #f0f4ee;
    border-radius: 4px;
}

.pmp-field input[type="number"] {
    width: 100%;
    height: 46px;
    border: 1px solid #d8d8d8;
    border-radius: 6px;
    background: #fff;
    padding: 0 12px;
    font-size: 15px;
}

.pmp-submit {
    width: 100%;
    height: 48px;
    border: 0;
    border-radius: 6px;
    background: #7f9872;
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
}

.pmp-reset-filters {
    width: 100%;
    margin-top: 10px;
    height: 44px;
    border: 1px solid #7f9872;
    border-radius: 6px;
    background: #fff;
    color: #4b5f41;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
}

.pmp-submit:hover,
.pmp-reset-filters:hover {
    opacity: 0.95;
}

.pmp-submit:disabled {
    opacity: 0.7;
    cursor: default;
}

.pmp-result-count {
    margin-top: 12px;
    font-size: 14px;
    color: #444;
}

.pmp-modal-overlay {
    position: absolute;
    inset: 0;
    z-index: 30;
    background: rgba(25, 25, 25, 0.28);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease;
}

.pmp-project-modal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -45%);
    z-index: 40;
    width: min(720px, calc(100% - 40px));
    max-height: calc(100% - 60px);
    overflow-y: auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.pmp-modal-open .pmp-map-canvas {
    filter: blur(3px);
}

.pmp-modal-open .pmp-modal-overlay,
.pmp-modal-open .pmp-project-modal {
    opacity: 1;
    visibility: visible;
}

.pmp-modal-open .pmp-project-modal {
    transform: translate(-50%, -50%);
}

/* Custom fullscreen button */
.pmp-fullscreen-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin: 10px 10px 0 0;
    border: 0;
    border-radius: 4px;
    background: #fff;
    color: #555;
    cursor: pointer;
    box-shadow: 0 1px 4px rgba(0,0,0,0.3);
    transition: background 0.15s;
}

.pmp-fullscreen-btn:hover {
    background: #f5f5f5;
    color: #222;
}

/* When the wrapper itself is fullscreen it needs to fill the screen */
.pmp-wrapper:fullscreen,
.pmp-wrapper:-webkit-full-screen {
    width: 100%;
    height: 100%;
    min-height: 100vh;
    border-radius: 0;
    overflow: hidden;
}

.pmp-wrapper:fullscreen .pmp-map-canvas,
.pmp-wrapper:-webkit-full-screen .pmp-map-canvas {
    height: 100vh;
}

.pmp-modal-close {
    position: sticky;
    top: 0;
    float: right;
    width: 42px;
    height: 42px;
    border: 0;
    background: #fff;
    color: #2f2f2f;
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
}

.pmp-modal-content {
    padding: 16px 28px 28px;
}

.pmp-modal-loading {
    padding: 40px;
    text-align: center;
    color: #666;
    font-size: 15px;
}

.pmp-project-content h3 {
    margin: 0 0 16px;
    font-size: 28px;
    line-height: 1.2;
}

.pmp-project-content p:first-of-type {
    margin-top: 0;
}

button.pmp-modal-close {
    background: #ffffff00!important;
}

button.pmp-modal-close:hover {
    color: red!important;
}

button.pmp-submit:hover, button.pmp-reset-filters:hover {
    background: #4f4f24;
}

.pmp-project-content h3 {
    text-align: center;
}

@media (max-width: 767px) {
    .pmp-wrapper {
        min-height: 900px;
    }

    .pmp-map-canvas {
        height: 900px;
    }

    .pmp-panel {
        position: relative;
        top: 0;
        left: 0;
        width: 100%;
        max-width: 100%;
        border-radius: 0;
        box-shadow: none;
    }

    .pmp-project-modal {
        width: calc(100% - 24px);
        max-height: calc(100% - 24px);
    }

    .pmp-modal-content {
        padding: 10px 16px 16px;
    }
}

/* Map legend */
.pmp-legend {
    position: absolute;
    top: 0px !important;
    right: 0px !important;
    right: 20px;
    margin: 10px;
    z-index: 20;
    background: #f6f4ea;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    max-height: calc(100vh - 60px);
    overflow-y: auto;
    box-sizing: border-box;
}

.pmp-legend-title {
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 8px;
    color: #2f2f2f;
}

.pmp-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.pmp-legend-item:last-child {
    margin-bottom: 0;
}

.pmp-legend-icon {
    display: block;
    flex-shrink: 0;
}

.pmp-legend-icon-default {
    width: 28px;
    height: 28px;
}

.pmp-legend-icon-new {
    width: 28px;
    height: 49px;
}

.pmp-legend-help {
    margin-top: 10px;
    font-size: 13px;
    color: #4b5f41;
}