html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    scroll-snap-type: y mandatory;
    overflow-y: scroll;
    height: 100vh;
}

/* Landing Page Styles */
.landing {
    min-height: 100vh;
    background: linear-gradient(135deg, #6e8efb, #a777e3);
    color: white;
    position: relative;
    scroll-snap-align: start;
    scroll-snap-stop: always;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 50px;
    background: rgba(255, 255, 255, 0.1);
}

.logo {
    font-size: 24px;
    font-weight: bold;
}

.cta-button {
    background: white;
    color: #6e8efb;
    padding: 10px 25px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    transition: transform 0.2s;
}

.cta-button:hover {
    transform: translateY(-2px);
}

.hero {
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 20px;
    text-align: center;
}

.hero h1 {
    font-size: 48px;
    margin-bottom: 20px;
}

.subtitle {
    font-size: 20px;
    margin-bottom: 60px;
    opacity: 0.9;
}

.features {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin: 60px 0;
}

.feature {
    flex: 1;
    max-width: 300px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.feature-icon {
    font-size: 40px;
    margin-bottom: 20px;
}

.feature h3 {
    margin-bottom: 10px;
}

.feature p {
    opacity: 0.9;
    line-height: 1.6;
}

.scroll-down {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.arrow {
    font-size: 24px;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* Map Section Styles */
.map-container {
    height: 100vh;
    background: #f5f5f5;
    scroll-snap-align: start;
    position: relative;
    overflow: hidden;
}

.container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
}

#map {
    flex: 0 0 70%;
    height: 100%;
    position: relative;
}

#reviews-sidebar {
    flex: 0 0 30%;
    height: 100%;
    background: white;
    padding: 20px;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
    overflow-y: auto;
}

#recent-reviews {
    padding: 16px;
}

.review-item {
    background: white;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 16px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.review-location {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    line-height: 1.4;
    flex: 1;
    margin-right: 12px;
}

.review-rating {
    color: #ffd700;
    font-size: 16px;
    white-space: nowrap;
    letter-spacing: 2px;
}

.review-period {
    font-size: 13px;
    color: #666;
    margin-bottom: 8px;
}

.review-text {
    font-size: 14px;
    line-height: 1.5;
    color: #444;
    white-space: pre-wrap;
    margin-bottom: 8px;
    padding: 8px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
}

.review-date {
    font-size: 12px;
    color: #888;
    text-align: right;
}

.no-reviews {
    text-align: center;
    padding: 20px;
    color: #666;
    font-style: italic;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.error-message {
    text-align: center;
    padding: 20px;
    color: #dc3545;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin: 16px;
}

.review-card {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    border: 1px solid #e9ecef;
}

.review-card h3 {
    margin: 0 0 10px 0;
    font-size: 16px;
    color: #333;
}

.review-card .period {
    font-size: 14px;
    color: #666;
    margin-bottom: 8px;
}

.review-card .rating {
    color: #ff9800;
    margin-bottom: 8px;
}

.review-card .text {
    font-size: 14px;
    line-height: 1.4;
    color: #444;
}

/* Review Panel Styles */
#review-panel {
    position: absolute;
    top: 20px;
    right: 32%;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    width: 360px;
}

#review-panel.hidden {
    display: none;
}

#review-panel h2 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 18px;
}

#selected-address {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
    word-wrap: break-word;
}

#review-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.period-inputs {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.date-field {
    flex: 1;
}

.date-field label {
    display: block;
    font-size: 13px;
    margin-bottom: 4px;
    color: #666;
}

.date-field input[type="month"] {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    min-height: 20px;
}

.date-field input[type="month"]::-webkit-calendar-picker-indicator {
    scale: 0.8;
    margin-left: -4px;
}

.rating {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.rating label {
    font-size: 14px;
    color: #666;
}

.star-rating {
    display: flex;
    flex-direction: row-reverse;
    justify-content: flex-end;
}

.star-rating input {
    display: none;
}

.star-rating label {
    font-size: 24px;
    color: #ddd;
    cursor: pointer;
    padding: 0 2px;
}

.star-rating label:hover,
.star-rating label:hover ~ label,
.star-rating input:checked ~ label {
    color: #ffd700;
}

#review-text {
    width: 100%;
    height: 100px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    resize: vertical;
    font-size: 14px;
    font-family: inherit;
}

#review-form button {
    background: #3498db;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    font-size: 14px;
    transition: background-color 0.2s;
}

#review-form button:hover {
    background: #2980b9;
}

/* Review markers and popups */
.review-marker {
    width: 30px;
    height: 40px;
    background: #e74c3c;  /* Red color */
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    position: relative;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    transition: all 0.2s ease;
}

.review-marker::after {
    content: '★';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(45deg);
    color: white;
    font-size: 16px;
}

.review-marker:hover {
    background: #c0392b;  /* Darker red on hover */
    transform: rotate(-45deg) scale(1.1);
    box-shadow: 0 3px 6px rgba(0,0,0,0.4);
}

.review-popup {
    padding: 12px;
    max-width: 300px;
    background: white;
}

.review-popup h3 {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
}

.review-popup .stars {
    color: #f1c40f;  /* Brighter yellow for better contrast */
    margin-bottom: 6px;
    font-size: 18px;
}

.review-popup .period {
    color: #7f8c8d;
    font-size: 14px;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid #ecf0f1;
}

.review-popup p {
    margin: 8px 0;
    font-size: 14px;
    line-height: 1.5;
    color: #34495e;
}

.review-popup .date {
    color: #95a5a6;
    font-size: 12px;
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px solid #ecf0f1;
}

.mapboxgl-popup-content {
    padding: 0;
    border-radius: 8px;
    box-shadow: 0 3px 15px rgba(0,0,0,0.2);
    border: none;
}

.mapboxgl-popup-close-button {
    font-size: 18px;
    color: #7f8c8d;
    padding: 8px;
    right: 4px;
    top: 4px;
    transition: color 0.2s ease;
}

.mapboxgl-popup-close-button:hover {
    color: #34495e;
    background: none;
}

/* Mapbox Geocoder custom styles */
.mapboxgl-ctrl-geocoder {
    min-width: 100%;
}

.mapboxgl-ctrl-top-left .mapboxgl-ctrl {
    margin: 20px 0 0 20px;
    width: 400px;
}

/* Footer Styles */
.footer {
    background: #2c3e50;
    color: white;
    padding: 40px 20px;
    text-align: center;
}

.footer h2 {
    font-size: 28px;
    margin-bottom: 30px;
}

.contact-items {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-bottom: 30px;
}

.contact-link {
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
}

.contact-link i {
    font-size: 20px;
}

.copyright {
    color: rgba(255, 255, 255, 0.7);
    font-size: 16px;
}
