
::-webkit-scrollbar {
    display: none;
}

body {
    overflow: hidden;
}


.map-page {
    height: calc(100vh - 72px);
    overflow: hidden; 
}

.map-screen-container {
    position: relative;
    width: 100%;
    height: 99%;
    overflow: hidden;
}


cp-map {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    background-color: var(--search-bg);
    overflow: hidden;
}


.leaflet-control-zoom {
    display: none !important;
}


cp-map-content-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 900;
    pointer-events: none;
    
    display: flex;
    justify-content: space-between;
    padding: 24px;
    box-sizing: border-box;
}


cp-map-sidebar, cp-map-controls {
    pointer-events: auto; 
}


.map-sidebar {
    width: 400px;
    height: 100%;
    background: var(--card-bg);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.map-sidebar-content {
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

.map-sidebar-header {
    padding: 20px 24px 16px;
    border-bottom: 1px solid var(--border);
    background: var(--card-bg);
    z-index: 2;
}

.sidebar-header-content {
    display: flex;
    gap: 40px;
    flex-direction: column;
}

.sidebar-header-text {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.map-sidebar-heading {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-main, #1a1a1a);
}

.map-sidebar-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    background: var(--border);
    color: var(--text-main);
    padding: 12px;
    transition: color 0.2s;
    border-radius: 999px;
}

.map-sidebar-btn svg {
    transition: all 0.35s ease;
    height: 17px;
    width: 17px;
}

.map-sidebar-btn:hover svg {
    transform: scale(1.1);
}

.sidebar-ferratas-count {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.ferratas-count-number {
    font-weight: 700;
    color: var(--text-main);
}

.map-sidebar-ferratas {
    flex: 1;
    overflow-y: auto;
    padding: 20px 24px;
    background: var(--card-bg);
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.map-sidebar-ferratas::-webkit-scrollbar {
    display: none;
}

.map-sidebar-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 140px;
    pointer-events: none;

    background: var(--map-sidebar-overlay);
}


.map-sidebar-list-scroll {
    display: flex;
    flex-direction: column;
    gap: 28px;
}


.map-controls-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.map-controls-main {
    display: flex;
    flex-direction: column;
    background: var(--card-bg,);
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.map-control-btn {
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border);
    width: 55px;
    height: 55px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    color: var(--text-main);
}

.map-control-btn:last-child {
    border-bottom: none;
}

.map-control-btn svg {
    transition: all 0.35s ease;
    height: 20px;
    width: 20px;
}

.map-control-btn:hover svg {
    transform: scale(1.2);
}


@media (max-width: 900px) {
   
    cp-map-content-overlay {
        flex-direction: column-reverse;
        padding: 16px;
        gap: 16px;
    }
    
    .map-sidebar {
        width: 100%;
        height: 40vh;
        border-radius: 16px 16px 0 0;
    }
    
    cp-map-controls {
        align-self: flex-end;
    }
}

cp-map-sidebar {
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s ease;
}
cp-map-sidebar.is-collapsed {
    transform: translateX(-120%);
    opacity: 0;
    pointer-events: none;
}


.cp-reopen-sidebar-btn {
    position: absolute;
    top: 24px;
    left: 24px;
    z-index: 899;
    background: var(--action-btn-sm-bg);
    border: 1px solid var(--border);
    border-radius: 14px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(0,0,0,0.12);
    cursor: pointer;
    color: var(--text-main);
    opacity: 0;
    pointer-events: none;
    transform: translateX(-30px);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.cp-reopen-sidebar-btn:hover {
    background: var(--action-btn-sm-bg-hover);
    transform: translateX(0) scale(1.05);
}
.cp-reopen-sidebar-btn.is-visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0);
}


.cp-mobile-bottom-bar {
    position: absolute;
    bottom: 24px;
    left: 16px;
    right: 16px;
    background: #FFFFFF;
    border-radius: 22px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25);
    z-index: 1000;
    display: flex;
    flex-direction: row;
    height: 120px;
    font-family: 'Nunito', sans-serif;
    transform: translateY(150%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s ease;
}
.cp-mobile-bottom-bar.is-visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.cp-mbb-image {
    width: 100px;
    min-width: 100px;
    height: 100%;
    object-fit: cover;
    border-radius: 22px 0 0 22px;
    cursor: pointer;
}
.cp-mbb-content {
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
    flex: 1;
    position: relative;
    cursor: pointer;
}
.cp-mbb-close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #f1f5f9;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    z-index: 2;
}
.cp-mbb-title {
    margin: 0 0 3px 0;
    font-size: 16px;
    font-weight: 800;
    color: #18181b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 24px;
}
.cp-mbb-region {
    font-size: 13px;
    color: #71717a;
    font-weight: 600;
    margin-bottom: 8px;
}
.cp-mbb-diff {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 700;
    color: #3f3f46;
    margin-bottom: 4px;
}
.cp-mbb-footer {
    font-size: 13px;
    font-weight: 700;
    color: #71717a;
    display: flex;
    align-items: center;
    gap: 6px;
}

@media (max-width: 900px) {
    cp-map-sidebar, .cp-reopen-sidebar-btn { display: none !important; }
    cp-map-content-overlay { padding: 16px; flex-direction: column; justify-content: flex-end; }
    cp-map-controls { align-self: flex-end; margin-bottom: 145px; }
    .cp-map-popup { display: none !important; }
}