*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 14px;
    color: #222;
}

.app {
    display: flex;
    height: 100vh;
}

.sidebar {
    width: 360px;
    min-width: 360px;
    display: flex;
    flex-direction: column;
    background: #f8f9fa;
    border-right: 1px solid #dee2e6;
}

.sidebar__header {
    padding: 16px 20px;
    background: #fff;
    border-bottom: 1px solid #dee2e6;
}

.sidebar__header h1 {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a2e;
}

.sidebar__subtitle {
    font-size: 12px;
    color: #6c757d;
    margin-top: 2px;
}

.filters {
    padding: 12px 20px;
    background: #fff;
    border-bottom: 1px solid #dee2e6;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filters__select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 14px;
    background: #fff;
}

.filters__checkbox {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    cursor: pointer;
}

.filters__checkbox input {
    width: 16px;
    height: 16px;
}

.list {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
}

.list__placeholder {
    text-align: center;
    color: #6c757d;
    padding: 40px 20px;
}

.place-item {
    padding: 12px;
    margin-bottom: 6px;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    cursor: pointer;
    transition: box-shadow 0.15s, border-color 0.15s;
}

.place-item:hover {
    border-color: #3399ff;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.place-item--active {
    border-color: #3399ff;
    background: #f0f7ff;
}

.place-item__name {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 4px;
}

.place-item__meta {
    font-size: 12px;
    color: #6c757d;
    display: flex;
    gap: 12px;
}

.place-item__distance {
    color: #3399ff;
    font-weight: 500;
}

.map-container {
    flex: 1;
    position: relative;
}

#map {
    width: 100%;
    height: 100%;
}

.sidebar__add-btn {
    display: block;
    text-align: center;
    padding: 12px;
    margin: 8px;
    background: #3399ff;
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    transition: background 0.15s;
}

.sidebar__add-btn:hover {
    background: #2a7fcf;
}

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        min-width: auto;
        height: 50vh;
        border-right: none;
        border-bottom: 1px solid #dee2e6;
    }

    .app {
        flex-direction: column-reverse;
    }

    .map-container {
        height: 50vh;
    }
}
