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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-align: center;
    padding: 2rem 1rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

header p {
    font-size: 1.2rem;
    opacity: 0.95;
}

main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 2rem;
    align-items: start;
}

.map-section {
    grid-column: 1 / -1;
    grid-row: 1;
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.filters {
    grid-column: 1;
    grid-row: 2;
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    height: fit-content;
    position: sticky;
    top: 1rem;
}

.filters h2 {
    margin-bottom: 1rem;
    color: #667eea;
}

.filter-group {
    margin-bottom: 1.2rem;
}

.filter-group label {
    display: block;
    margin-bottom: 0.4rem;
    font-weight: 600;
    color: #555;
}

.filter-group select,
.filter-group input {
    width: 100%;
    padding: 0.7rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.filter-group select:focus,
.filter-group input:focus {
    outline: none;
    border-color: #667eea;
}

.budget-calc {
    background: #f0f4ff;
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.budget-calc h3 {
    margin-bottom: 0.8rem;
    color: #667eea;
    font-size: 1.1rem;
}

button {
    width: 100%;
    padding: 0.9rem;
    margin-bottom: 0.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

#filter-btn {
    background: #667eea;
    color: white;
}

#reset-btn {
    background: #e0e0e0;
    color: #555;
}

.results {
    grid-column: 2;
}

.results h2 {
    margin-bottom: 1rem;
    color: #667eea;
}

#result-count {
    margin-bottom: 1rem;
    color: #666;
    font-style: italic;
}

.place-card {
    background: white;
    padding: 1.2rem;
    margin-bottom: 1rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    border-left: 4px solid #667eea;
    transition: transform 0.2s;
}

.place-card:hover {
    transform: translateX(5px);
}

.place-card h3 {
    color: #333;
    margin-bottom: 0.5rem;
}

.place-card .price {
    display: inline-block;
    background: #667eea;
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.place-card .price.free {
    background: #28a745;
}

.place-card .type-badge {
    display: inline-block;
    background: #f0f0f0;
    color: #666;
    padding: 0.2rem 0.6rem;
    border-radius: 15px;
    font-size: 0.8rem;
    margin-right: 0.3rem;
    margin-bottom: 0.5rem;
}

.place-card p {
    color: #666;
    margin-bottom: 0.5rem;
}

.place-card a {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
}

.place-card a:hover {
    text-decoration: underline;
}

.place-tags {
    margin-top: 0.8rem;
}

.tag-link {
    display: inline-block;
    background: #e0e7ff;
    color: #667eea;
    padding: 0.2rem 0.6rem;
    border-radius: 15px;
    font-size: 0.85rem;
    margin-right: 0.3rem;
    margin-bottom: 0.3rem;
    text-decoration: none;
}

.tag-link:hover {
    background: #667eea;
    color: white;
    text-decoration: none;
}

.results {
    grid-column: 2;
    grid-row: 2;
}

.map-section h2 {
    margin-bottom: 1rem;
    color: #667eea;
}

.pagination {
    margin-top: 2rem;
    padding: 1.5rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    text-align: center;
}

.pagination-info {
    margin-bottom: 1rem;
    color: #666;
    font-weight: 600;
}

.pagination-buttons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.pagination .btn {
    min-width: 40px;
}

.pagination .current-page {
    background: #667eea;
    color: white;
}

.pagination .disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

#map {
    height: 500px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

footer {
    text-align: center;
    padding: 2rem;
    background: #333;
    color: white;
    margin-top: 2rem;
}

@media (max-width: 900px) {
    main {
        grid-template-columns: 1fr;
    }
    
    .map-section,
    .filters,
    .results {
        grid-column: 1;
        grid-row: auto;
    }
    
    .filters {
        position: static;
    }
}

@media (max-width: 600px) {
    header h1 {
        font-size: 1.8rem;
    }
    
    #map {
        height: 350px;
    }
}
