/**
 * Frontend CSS for MAP Locations Map
 * Typography en kleuren erven over van het actieve template/thema.
 * Ondersteunt: Kadence (--global-palette1), WordPress Block Theme (--wp--preset--color--primary).
 */

/* Modal Animation */
@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

/* Theme primary: Kadence (--global-palette1), WP Block Theme, of donkergroen fallback */
.map-locations-container {
    --map-primary: var(--global-palette1, var(--global-palette-1, var(--wp--preset--color--primary, #1a5f4a)));
    --map-primary-foreground: var(--global-palette9, var(--global-palette-9, var(--wp--preset--color--background, #fff)));
    --map-surface: var(--global-palette9, var(--global-palette-9, var(--wp--preset--color--background, #fff)));
    --map-surface-alt: var(--global-palette8, var(--global-palette-8, var(--wp--preset--color--neutral, rgba(0,0,0,0.035))));
    --map-text: var(--global-palette4, var(--global-palette-4, var(--wp--preset--color--foreground, inherit)));
    --map-muted: var(--global-palette5, var(--global-palette-5, currentColor));
    --map-border: var(--global-palette7, var(--global-palette-7, rgba(0,0,0,0.08)));
    --map-accent: var(--global-palette2, var(--global-palette-2, var(--map-primary)));
    --map-accent-soft: color-mix(in srgb, var(--map-accent) 12%, var(--map-surface));
    --map-primary-soft: color-mix(in srgb, var(--map-primary) 10%, var(--map-surface));
    /* Kadence “kaart”-kaders: lichte vlakken + palette 3 voor koppen */
    --map-card-bg: var(--global-palette8, var(--global-palette-8, color-mix(in srgb, var(--map-text) 5.5%, var(--map-surface))));
    --map-heading-color: var(--global-palette3, var(--global-palette-3, var(--map-text)));
    max-width: 100%;
    margin: 20px 0;
    font-family: inherit;
    color: inherit;
}

.map-message {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.map-message.map-success {
    background-color: rgba(70, 180, 80, 0.15);
    color: inherit;
    border: 1px solid rgba(70, 180, 80, 0.3);
}

.map-filters {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    padding: 15px;
    background: var(--wp--preset--color--neutral, rgba(0,0,0,0.04));
    border-radius: 4px;
    flex-wrap: wrap;
    color: inherit;
    font-family: inherit;
}

.map-filter-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.map-filter-group label {
    font-weight: 600;
    font-family: inherit;
    color: inherit;
}

.map-filter-group select {
    padding: 8px 12px;
    border: 1px solid rgba(0,0,0,0.15);
    border-radius: 4px;
    font-size: inherit;
    font-family: inherit;
    color: inherit;
    background-color: var(--wp--preset--color--background, #fff);
}

.map-filter-group select option:disabled {
    color: #999;
    background-color: #f5f5f5;
    font-style: italic;
}

#map-map {
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 20px;
    /* Touch-friendly on mobile */
    touch-action: pan-x pan-y;
    position: relative;
    background: rgba(0,0,0,0.03);
}

/* Lazy-load placeholder */
.map-map-loading {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 500;
    pointer-events: none;
    background: rgba(255,255,255,0.8);
    backdrop-filter: blur(2px);
}
.map-map-loading-inner {
    padding: 10px 14px;
    border-radius: 8px;
    background: rgba(0,0,0,0.65);
    color: #fff;
    font-weight: 600;
    font-size: 14px;
}

.map-verification-section {
    padding: 20px;
    background: var(--wp--preset--color--neutral, rgba(0,0,0,0.02));
    border-radius: 4px;
    text-align: center;
    margin-top: 20px;
    font-family: inherit;
    color: inherit;
}

.map-verification-section h3 {
    margin-top: 0;
    font-family: inherit;
    color: inherit;
}

.map-verification-section form {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 15px;
    flex-wrap: wrap;
}

.map-verification-section input[type="email"] {
    padding: 10px 15px;
    border: 1px solid rgba(0,0,0,0.15);
    border-radius: 4px;
    font-size: inherit;
    font-family: inherit;
    color: inherit;
    background-color: var(--wp--preset--color--background, #fff);
    min-width: 320px;
}

.map-verification-section .button {
    padding: 10px 20px;
    font-size: inherit;
    font-family: inherit;
}

#map-verification-message {
    margin-top: 15px;
    min-height: 30px;
}

.map-verified-notice {
    padding: 15px;
    background: var(--wp--preset--color--success, rgba(70, 180, 80, 0.2));
    color: inherit;
    border-radius: 4px;
    text-align: center;
    margin-top: 20px;
    font-family: inherit;
}

.map-admin-warning {
    margin: 10px 0;
    padding: 10px 12px;
    border-left: 4px solid #b45309;
    background: #fff7ed;
    color: #9a3412;
    border-radius: 6px;
    font-size: 0.92em;
    line-height: 1.45;
}

.map-inactive-marker-wrapper {
    background: transparent;
    border: none;
}

.map-inactive-marker-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #f97316;
    color: #fff;
    font-weight: 700;
    font-size: 16px;
    line-height: 28px;
    text-align: center;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.28);
}

/* Modern Leaflet Popup Styling */
.leaflet-popup-content-wrapper {
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    padding: 0;
    overflow: hidden;
}

.leaflet-popup-content {
    margin: 0;
    padding: 0;
    min-width: 360px;
    max-width: 420px;
    max-height: none; /* desktop: no limit */
}

.map-popup {
    padding: 26px 28px;
    background: var(--wp--preset--color--background, #fff);
    font-family: inherit;
    color: inherit;
}

.map-popup-header {
    margin-bottom: 16px;
    border-bottom: 2px solid rgba(0,0,0,0.08);
    padding-bottom: 14px;
}

.map-popup-header h3 {
    margin: 0;
    font-size: 2.0em; /* van te groot (H1-achtig) naar H2-achtig */
    font-weight: 700;
    font-family: inherit;
    color: inherit;
    line-height: 1.25;
}

.map-popup-footer {
    margin-top: 16px;
    text-align: right;
}

.map-popup .map-view-detail {
    width: auto;
    margin: 0;
    padding: 12px 18px;
    font-size: 1.59em; /* +50% t.o.v. 1.06em */
    font-weight: 700;
    border-radius: 10px;
}


.map-popup p {
    margin: 12px 0;
    font-size: 1.77em; /* +50% t.o.v. 1.18em */
    line-height: 1.7;
    font-family: inherit;
    color: inherit;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.map-popup p strong {
    color: inherit;
    font-weight: 700;
    min-width: 122px;
    display: inline-block;
}

/* Badge styling voor type – gebruikt thema-kleuren */
.map-popup-type-badge {
    display: inline-block;
    padding: 4px 10px;
    background: var(--map-primary, #1a5f4a);
    color: var(--map-primary-foreground, white);
    border-radius: 12px;
    font-size: 1.125em; /* +50% t.o.v. 0.75em */
    font-weight: 600;
    font-family: inherit;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-left: 8px;
}

/* Badge styling voor aantal personen */
.map-popup-persons-badge {
    display: inline-block;
    padding: 4px 10px;
    background: var(--map-primary, #1a5f4a);
    color: white;
    border-radius: 12px;
    font-size: 1.125em; /* +50% t.o.v. 0.75em */
    font-weight: 600;
    font-family: inherit;
    margin-left: 8px;
}

/* Aanbiedingen styling */
.map-popup-offers {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
}

.map-popup-offer-badge {
    display: inline-block;
    padding: 4px 10px;
    background: var(--map-primary, #1a5f4a);
    color: white;
    border-radius: 8px;
    font-size: 1.05em; /* +50% t.o.v. 0.70em */
    font-weight: 600;
    font-family: inherit;
}

.map-view-detail {
    margin-top: 0;
    padding: 8px 14px;
    background: var(--map-primary, #1a5f4a);
    color: var(--map-primary-foreground, white);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9em;
    font-weight: 600;
    font-family: inherit;
    width: auto;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    letter-spacing: 0.3px;
    flex-shrink: 0;
}

.map-view-detail:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.15);
    opacity: 0.9;
}

.map-view-detail:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
}

/* Leaflet popup tip styling */
.leaflet-popup-tip {
    background: white;
    box-shadow: 0 3px 14px rgba(0, 0, 0, 0.15);
}

/* Close button in popup */
.leaflet-popup-close-button {
    width: 28px;
    height: 28px;
    line-height: 28px;
    text-align: center;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.1);
    color: #666;
    font-size: 18px;
    font-weight: bold;
    transition: all 0.2s ease;
    margin: 8px 8px 0 0;
}

.leaflet-popup-close-button:hover {
    background: rgba(220, 50, 50, 0.9);
    color: white;
    transform: rotate(90deg);
}

.map-summary-marker,
.map-total-marker {
    background: transparent !important;
    border: none !important;
}

.map-summary-badge,
.map-total-badge {
    background: var(--map-primary, #1a5f4a);
    color: white;
    padding: 10px 15px;
    border-radius: 6px;
    font-weight: 600;
    font-family: inherit;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    white-space: nowrap;
}

.map-public-summary-marker {
    background: transparent !important;
    border: none !important;
    pointer-events: auto !important;
}

.map-public-summary-panel {
    width: min(360px, calc(100vw - 48px));
    max-height: 260px;
    overflow: auto;
    padding: 18px 20px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.96);
    color: inherit;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
    border: 1px solid rgba(0, 0, 0, 0.08);
    font-family: inherit;
    line-height: 1.45;
    pointer-events: auto;
    overscroll-behavior: contain;
}

.map-public-summary-panel h3,
.map-public-summary-panel h4 {
    margin: 0 0 8px;
    font-family: inherit;
    color: inherit;
}

.map-public-summary-panel h3 {
    font-size: 18px;
}

.map-public-summary-panel h4 {
    font-size: 14px;
}

.map-public-summary-panel p {
    margin: 0 0 12px;
    font-size: 13px;
}

.map-public-summary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.map-public-summary-panel ul {
    margin: 0;
    padding-left: 18px;
    font-size: 13px;
}

.map-public-summary-panel li {
    margin: 0 0 4px;
}

.map-public-summary-panel li span {
    opacity: 0.75;
}

.map-total-badge {
    background: var(--wp--preset--color--success, #46b450);
}

/* Modal overlay */
.map-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 10000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.map-modal-overlay.active {
    display: block;
    opacity: 1;
}

.map-location-detail {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    width: 90%;
    max-width: 900px;
    max-height: 90vh;
    animation: modalSlideIn 0.3s ease forwards;
    background: var(--map-card-bg, var(--wp--preset--color--background, #f7f7f7));
    border-radius: 16px;
    border: 1px solid var(--map-border, rgba(0, 0, 0, 0.08));
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
    overflow: hidden;
    z-index: 10001;
    overflow-y: auto;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    font-family: inherit;
    color: var(--map-text, inherit);
}

.map-location-detail.active {
    display: block;
    opacity: 1;
}

#map-detail-content {
    padding: 0;
    position: relative;
    overflow-y: auto;
    max-height: 90vh;
}

.map-detail-header {
    margin: 0;
    padding: 36px 40px 28px 40px;
    background: transparent;
    color: var(--map-text, inherit);
    border-bottom: 1px solid var(--map-border, rgba(0, 0, 0, 0.08));
    position: relative;
}

.map-detail-header h2 {
    margin: 0 0 12px 0;
    font-size: 32px;
    font-weight: 700;
    color: var(--map-heading-color, var(--map-text, inherit));
    text-shadow: none;
    letter-spacing: -0.02em;
}

.map-detail-type {
    color: var(--map-muted, inherit);
    margin: 8px 0 0 0;
    font-size: 16px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.map-detail-type::before {
    content: '📍';
    font-size: 18px;
}

.map-detail-address {
    color: var(--map-text, inherit);
    margin: 12px 0 0 0;
    font-size: 15px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.map-detail-address strong {
    color: var(--map-heading-color, var(--map-text, inherit));
    font-weight: 600;
}

.map-detail-phone {
    margin: 16px 0 0 0;
}

.map-call-button {
    display: inline-block;
    padding: 14px 24px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    text-align: center;
    background: var(--map-primary, #1a5f4a);
    color: var(--map-primary-foreground, #fff);
    font-weight: 700;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-radius: 6px;
    border: none;
    transition: opacity 0.2s, transform 0.2s;
}

.map-call-button:hover {
    opacity: 0.92;
    transform: translateY(-1px);
}

.map-detail-activity-links-box {
    margin: 20px 0 0 0;
    padding: 18px 20px;
    background: var(--map-surface, #fff);
    border-radius: 12px;
    border: 1px solid var(--map-border, rgba(0, 0, 0, 0.08));
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.map-detail-activity-links-title {
    margin: 0 0 12px 0;
    font-size: 1.1em;
    font-weight: 700;
    color: var(--map-heading-color, var(--map-text, inherit));
}

.map-detail-activity-links {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    gap: 10px;
}

.map-activity-link-button {
    display: block;
    padding: 12px 18px;
    width: 100%;
    text-align: center;
    box-sizing: border-box;
    background: var(--map-primary, #1a5f4a);
    color: var(--map-primary-foreground, #fff);
    font-weight: 700;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border-radius: 6px;
    border: none;
    transition: opacity 0.2s, transform 0.2s;
}

.map-activity-link-button::before {
    content: '➜';
    display: inline-block;
    margin-right: 6px;
    font-size: 0.9em;
}

.map-activity-link-button:hover {
    opacity: 0.92;
    transform: translateY(-1px);
}

.map-detail-persons {
    margin: 12px 0 0 0;
    padding: 8px 16px;
    background: color-mix(in srgb, var(--map-primary, #1a5f4a) 12%, var(--map-surface, #fff));
    border-radius: 20px;
    display: inline-block;
    font-size: 14px;
    font-weight: 600;
    color: var(--map-text, inherit);
}

.map-detail-photos {
    margin: 0;
    padding: 30px 40px;
    background: var(--wp--preset--color--background, #fff);
}

.map-detail-photos h3 {
    margin: 0 0 20px 0;
    font-size: 1.4em;
    font-weight: 700;
    font-family: inherit;
    color: inherit;
}

/* Photo Carousel */
.map-photo-carousel {
    position: relative;
    width: 100%;
    margin: 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    background: #000;
}

.map-carousel-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    min-height: 400px;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.map-carousel-slide {
    display: none !important;
    width: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
    visibility: hidden;
}

.map-carousel-slide.active {
    display: block !important;
    opacity: 1;
    visibility: visible;
}

.map-carousel-slide img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    min-height: 400px;
    max-height: 500px;
}

.map-carousel-prev,
.map-carousel-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    color: #2d3748;
    border: none;
    padding: 12px 16px;
    cursor: pointer;
    font-size: 20px;
    font-weight: bold;
    z-index: 10;
    transition: all 0.3s ease;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.map-carousel-prev:hover,
.map-carousel-next:hover {
    background: rgba(255, 255, 255, 1);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
}

.map-carousel-prev {
    left: 20px;
}

.map-carousel-next {
    right: 20px;
}

.map-carousel-indicators {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    padding: 15px;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
}

.map-carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.map-carousel-dot.active {
    background: white;
    width: 30px;
    border-radius: 5px;
    border-color: rgba(255, 255, 255, 0.8);
}

.map-carousel-dot:hover {
    background: rgba(255, 255, 255, 0.7);
    transform: scale(1.2);
}

.map-detail-description {
    margin: 0;
    padding: 30px 40px;
    background: var(--wp--preset--color--neutral, rgba(0,0,0,0.02));
    line-height: 1.7;
    font-family: inherit;
    color: inherit;
}

.map-detail-description h3 {
    margin: 0 0 15px 0;
    font-size: 1.4em;
    font-weight: 700;
    font-family: inherit;
    color: inherit;
}

.map-detail-description div {
    color: inherit;
    font-size: 1em;
    line-height: 1.7;
}

.map-detail-offers {
    margin: 0;
    padding: 30px 40px;
    background: var(--wp--preset--color--background, #fff);
    border-radius: 0;
}

.map-detail-offers h3 {
    margin: 0 0 20px 0;
    font-size: 1.4em;
    font-weight: 700;
    font-family: inherit;
    color: inherit;
}

.map-detail-offers ul {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
}

.map-detail-offers li {
    padding: 12px 0;
    font-size: 1em;
    font-family: inherit;
    color: inherit;
    display: flex;
    align-items: center;
    gap: 10px;
}

.map-detail-offers li::before {
    content: '✓';
    color: #48bb78;
    font-weight: bold;
    font-size: 18px;
}

.map-booking-notice {
    margin-top: 20px;
    padding: 20px;
    background: linear-gradient(135deg, #fff5e6 0%, #ffe8cc 100%);
    border-left: 5px solid #f6ad55;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(246, 173, 85, 0.15);
}

.map-booking-notice p {
    margin: 8px 0;
    color: #744210;
    font-size: 15px;
    line-height: 1.6;
}

.map-booking-notice strong {
    color: #744210;
    font-weight: 700;
}

/* Close Button — neutraal, past bij lichte kaart-modal */
.map-close-detail {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 40px;
    height: 40px;
    background: var(--map-surface, #fff);
    border: 1px solid var(--map-border, rgba(0, 0, 0, 0.12));
    border-radius: 50%;
    color: var(--map-text, #333);
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
    z-index: 10;
    line-height: 1;
    padding: 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.map-close-detail:hover {
    background: var(--map-surface-alt, rgba(0, 0, 0, 0.04));
    border-color: var(--map-muted, rgba(0, 0, 0, 0.2));
    transform: rotate(90deg) scale(1.05);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.map-booking-notice p {
    margin: 5px 0;
}

.map-detail-menu-offers {
    margin: 0;
    padding: 30px 40px;
    background: var(--wp--preset--color--neutral, rgba(0,0,0,0.02));
}

.map-detail-menu-offers h3 {
    margin: 0 0 20px 0;
    font-size: 1.4em;
    font-weight: 700;
    font-family: inherit;
    color: inherit;
}

.map-offer-item {
    padding: 20px;
    margin-bottom: 15px;
    background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.map-offer-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.map-offer-item h4 {
    margin: 0 0 12px 0;
    font-size: 1.25em;
    font-weight: 700;
    font-family: inherit;
    color: inherit;
}

.map-offer-item p {
    margin: 8px 0;
    font-family: inherit;
    color: inherit;
    font-size: 1em;
    line-height: 1.6;
}

.map-price {
    font-size: 1.1em !important;
    font-weight: 700 !important;
    color: var(--map-primary, inherit) !important;
    margin-top: 12px !important;
}

.map-contact {
    margin-top: 12px !important;
    padding-top: 12px;
    border-top: 1px solid rgba(0,0,0,0.08);
    color: inherit !important;
    font-size: 0.9em !important;
}

.map-error {
    color: #dc3232;
    padding: 10px;
    background: #ffeaea;
    border-radius: 4px;
}

.map-success {
    color: #46b450;
    padding: 10px;
    background: #eafaea;
    border-radius: 4px;
}

.map-loading {
    color: #0073aa;
    padding: 10px;
}

/* Detail modal: zelfde basis als Kadence-info kaarten (licht vlak, witte secties, palette-knoppen) */
.map-location-detail {
    background: var(--map-card-bg);
    color: var(--map-text);
}

.map-detail-photos,
.map-detail-offers {
    background: var(--map-surface);
}

.map-detail-description,
.map-detail-menu-offers {
    background: var(--map-surface-alt);
}

.map-offer-item {
    background: var(--map-surface);
    border-color: var(--map-border);
}

.map-detail-offers li::before,
.map-price {
    color: var(--map-accent) !important;
}

.map-booking-notice {
    background: var(--map-primary-soft);
    border-left-color: var(--map-accent);
    box-shadow: none;
}

.map-booking-notice p,
.map-booking-notice strong {
    color: var(--map-text);
}

.map-error {
    color: var(--map-text);
    background: color-mix(in srgb, #dc3232 12%, var(--map-surface));
}

.map-success {
    color: var(--map-text);
    background: color-mix(in srgb, var(--map-accent) 14%, var(--map-surface));
}

.map-loading {
    color: var(--map-primary);
}

/* Responsive */
@media (max-width: 768px) {
    .map-locations-container {
        margin: 10px 0;
    }
    
    #map-map {
        height: 400px !important; /* Betere hoogte voor mobiel */
        margin-bottom: 15px;
    }
    
    .map-filters {
        flex-direction: column;
        gap: 15px;
        padding: 12px;
    }
    
    .map-filter-group {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
        gap: 8px;
    }
    
    .map-filter-group select {
        width: 100%;
        font-size: 16px; /* Voorkomt zoom op iOS */
    }
    
    .map-filter-group select option:disabled {
        color: #999;
        background-color: #f5f5f5;
        font-style: italic;
    }
    
    .map-verification-section {
        padding: 15px;
        margin-top: 15px;
    }
    
    .map-verification-section h3 {
        font-size: 18px;
    }
    
    .map-verification-section form {
        flex-direction: column;
        gap: 12px;
    }
    
    .map-verification-section input[type="email"] {
        width: 100%;
        min-width: auto;
        font-size: 16px; /* Voorkomt zoom op iOS */
        box-sizing: border-box;
    }
    
    .map-verification-section .button {
        width: 100%;
        font-size: 16px;
    }
    
    .map-location-detail {
        width: 95%;
        max-width: 95%;
        max-height: 95vh;
    }
    
    #map-detail-content {
        padding: 20px;
    }
    
    .map-carousel-container {
        min-height: 200px;
    }
    
    .map-carousel-prev,
    .map-carousel-next {
        width: 35px;
        height: 35px;
        font-size: 18px;
    }
    
    .map-carousel-prev {
        left: 10px;
    }
    
    .map-carousel-next {
        right: 10px;
    }
    
    /* Popup: hoger + compacte regels zodat hele inhoud (tot en met Meer info) zichtbaar is */
    .leaflet-popup-content-wrapper {
        max-height: min(85vh, 480px);
    }
    .leaflet-popup-content {
        max-height: min(85vh, 480px);
        overflow: hidden;
        min-width: 0;
        padding-right: 40px; /* ruimte voor Leaflet close-button (×) */
    }
    .map-popup {
        min-width: 0;
        max-width: 100%;
        padding: 8px 10px 8px 10px;
        display: flex;
        flex-direction: column;
        min-height: 0;
        max-height: min(85vh, 480px);
    }
    .map-popup-header {
        flex-shrink: 0;
        margin-bottom: 6px;
        padding-bottom: 6px;
    }
    .map-popup-body {
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
    .map-popup-footer {
        flex-shrink: 0;
        margin-top: 8px;
        text-align: right;
    }
    
    /* Titel: compact + ellipsis bij lange namen */
    .map-popup-header h3 {
        font-size: 1.2rem; /* H2-achtig op mobiel/tablet */
        margin: 0;
        padding-bottom: 0;
        line-height: 1.2;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    
    /* Compacte regels: minder afstand tussen regels zodat alles past */
    .map-popup-body p {
        font-size: 16.5px; /* +50% t.o.v. 11px */
        margin: 2px 0;
        line-height: 1.25;
        gap: 4px;
    }
    
    .map-popup-body p strong {
        min-width: 68px;
        font-size: 15px; /* +50% t.o.v. 10px */
    }
    
    .map-popup-type-badge,
    .map-popup-persons-badge {
        font-size: 13.5px; /* +50% t.o.v. 9px */
        padding: 2px 5px;
    }
    
    .map-popup-offers {
        gap: 3px;
        margin-top: 1px;
    }
    
    .map-popup-offer-badge {
        font-size: 12px; /* +50% t.o.v. 8px */
        padding: 2px 5px;
    }
    
    .map-popup .map-view-detail {
        font-size: 16.5px; /* +50% t.o.v. 11px */
        padding: 6px 10px;
    }
    
    #map-detail-content {
        padding: 15px;
    }
    
    .map-detail-header h2 {
        font-size: 20px;
    }
    
    .map-detail-offers,
    .map-detail-menu-offers {
        margin: 15px 0;
        padding: 12px;
    }
    
    .map-booking-notice {
        padding: 12px;
        font-size: 14px;
    }
}

/* Extra kleine schermen */
@media (max-width: 480px) {
    .map-filters {
        padding: 10px;
    }
    
    .map-verification-section {
        padding: 12px;
    }
    
    .map-verification-section h3 {
        font-size: 16px;
    }
    
    .map-popup {
        min-width: 0;
        padding: 8px 10px;
    }
    .map-popup-header h3 {
        font-size: 1.1rem; /* H2-achtig op extra klein */
    }
    .map-popup-body p {
        font-size: 15px; /* +50% t.o.v. 10px */
        margin: 1px 0;
        line-height: 1.2;
    }
    
    .map-summary-badge,
    .map-total-badge {
        padding: 8px 12px;
        font-size: 14px;
    }
}
