.locrating-map-section .area-guide-map-layout {
    align-items: stretch;
}

.locrating-map-section .map-wrapper {
    position: relative;
}

.locrating-map-section #map {
    width: 100%;
    height: 560px;
    min-height: 420px;
    z-index: 1;
    border-radius: 4px;
    overflow: hidden;
    background: #e8eef3;
}

.locrating-map-section #map.locrating-embed-fallback iframe {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 420px;
    border: 0;
}

.locrating-map-section .leaflet-container {
    font-family: inherit;
    background: #e8eef3;
    height: 100%;
    width: 100%;
}

.locrating-map-section .leaflet-control-attribution {
    font-size: 10px;
    background: rgba(255, 255, 255, 0.85);
    max-width: 70%;
}

.locrating-map-section .map-controls {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 500;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.locrating-map-section .btn-recenter,
.locrating-map-section .btn-reset-map {
    padding: 8px 14px;
    background: #003366;
    color: #fff;
    border: none;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.locrating-map-section .btn-reset-map {
    background: #fff;
    color: #003366;
    border: 1px solid rgba(0, 51, 102, 0.35);
}

.locrating-map-section .sidebar {
    width: 100%;
    height: 560px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.locrating-map-section .filtered {
    padding: 12px 12px 10px 16px;
    border-bottom: 1px solid #e5e7eb;
    background: #e3e3e35c;
}

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

.locrating-map-section .filter-label {
    font-size: 14px;
    font-weight: 500;
    color: #4b5563;
    margin: 0;
}

.locrating-map-section .filter-select {
    padding: 5px 24px 5px 8px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 14px;
    appearance: none;
    cursor: pointer;
    outline: none;
    background-color: #fff;
    color: #111;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 20 20'%3E%3Cpath fill='%23666' d='M5 7l5 5 5-5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
}

.locrating-map-section .header-actions {
    margin-left: auto;
}

.locrating-map-section .settings-dropdown {
    position: relative;
}

.locrating-map-section .btn-settings {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid #e5e7eb;
    background: #052c65;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.locrating-map-section .settings-menu {
    position: absolute;
    top: 110%;
    right: 0;
    background: #fff;
    border-radius: 12px;
    min-width: 170px;
    display: none;
    z-index: 1000;
    padding: 6px;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}

.locrating-map-section .settings-menu.open {
    display: block;
}

.locrating-map-section .settings-option {
    width: 100%;
    padding: 10px 14px;
    border: none;
    background: transparent;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 10px;
    border-radius: 8px;
}

.locrating-map-section .settings-option.active {
    background: #e6f2ff;
    color: #1d4ed8;
    font-weight: 600;
}

.locrating-map-section .category-tabs {
    padding: 8px 10px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    gap: 6px;
}

.locrating-map-section .tab {
    padding: 8px 10px;
    border: 1.5px solid #e5e7eb;
    border-radius: 8px;
    background: #dfdfdf;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    flex: 1;
    text-align: center;
}

.locrating-map-section .tab.active {
    background: #003366;
    color: #fff;
    border-color: #003366;
}

.locrating-map-section .type-chips {
    padding: 8px 12px 10px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.locrating-map-section .type-chips[hidden] {
    display: none !important;
}

.locrating-map-section .type-chips.is-icons {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.locrating-map-section .type-chip {
    border: 1.5px solid #e5e7eb;
    background: #fff;
    border-radius: 20px;
    padding: 5px 10px;
    font-size: 11px;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
}

.locrating-map-section .type-chip.active {
    background: #003366;
    color: #fff;
    border-color: #003366;
}

.locrating-map-section .type-chip.is-icon {
    border-radius: 10px;
    padding: 8px 4px 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-size: 10px;
}

.locrating-map-section .chip-icon,
.locrating-map-section .place-icon {
    border-radius: 50%;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.locrating-map-section .chip-icon {
    width: 28px;
    height: 28px;
}

.locrating-map-section .chip-icon svg,
.locrating-map-section .place-icon svg {
    width: 16px;
    height: 16px;
}

.locrating-map-section .places-list {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.locrating-map-section .place-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 10px;
    margin-bottom: 8px;
    cursor: pointer;
}

.locrating-map-section .place-card.is-active {
    border-color: #003366;
    background: #f4f7fb;
}

.locrating-map-section .place-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.locrating-map-section .place-icon {
    width: 40px;
    height: 40px;
}

.locrating-map-section .place-info {
    flex: 1;
    min-width: 0;
}

.locrating-map-section .place-name-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
}

.locrating-map-section .place-name {
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
}

.locrating-map-section .place-nearest {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    background: #003366;
    color: #fff;
    border-radius: 4px;
    padding: 2px 6px;
    flex-shrink: 0;
}

.locrating-map-section .place-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
}

.locrating-map-section .place-pill {
    font-size: 11px;
    font-weight: 600;
    background: #eef2f6;
    color: #374151;
    border-radius: 999px;
    padding: 2px 8px;
}

.locrating-map-section .place-distance {
    font-size: 12px;
    color: #9ca3af;
}

.locrating-map-section .no-results {
    text-align: center;
    padding: 40px 20px;
    color: #9ca3af;
    font-size: 14px;
}

.locrating-map-section .loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255, 255, 255, 0.95);
    padding: 16px 24px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    z-index: 500;
    display: none;
}

.locrating-map-section .loading.show {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: #4b5563;
}

.locrating-map-section .loading-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid #f3f4f6;
    border-top-color: #003366;
    border-radius: 50%;
    animation: locrating-spin 0.8s linear infinite;
}

@keyframes locrating-spin {
    to { transform: rotate(360deg); }
}

@media (max-width: 768px) {
    .locrating-map-section #map,
    .locrating-map-section .sidebar {
        height: 380px;
    }

    .locrating-map-section .sidebar {
        margin-top: 12px;
        max-height: 55vh;
        height: auto;
    }

    .locrating-map-section .places-list {
        max-height: 280px;
    }
}
