/* ─── POPUP REDESIGN - PROFESSIONAL STYLING ─────────────────────────────── */

.leaflet-popup-content {
    max-width: 320px !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    padding: 0 !important;
    border-radius: 12px !important;
    overflow: hidden;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.16) !important;
}

.leaflet-popup-content-wrapper {
    border-radius: 12px !important;
    padding: 0 !important;
}

.leaflet-popup-tip {
    background: white !important;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.16) !important;
}

/* ─── POPUP HEADER ────────────────────────────────────────────────────── */
.popup-header {
    padding: 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px 12px 0 0;
}

.popup-header h3 {
    margin: 0 0 4px 0;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.5px;
    line-height: 1.3;
}

.popup-header .status-badge {
    display: inline-block;
    margin-top: 6px;
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* ─── POPUP BODY ──────────────────────────────────────────────────────── */
.popup-body {
    padding: 16px;
    font-size: 14px;
    line-height: 1.6;
    color: #2c3e50;
    background: white;
}

.popup-section {
    margin-bottom: 12px;
}

.popup-section:last-child {
    margin-bottom: 0;
}

.popup-label {
    font-weight: 600;
    color: #667eea;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
    display: block;
}

.popup-value {
    color: #2c3e50;
    font-size: 14px;
    word-break: break-word;
}

/* ─── POPUP FOOTER ────────────────────────────────────────────────────── */
.popup-footer {
    padding: 12px 16px;
    background: #f8f9fa;
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    border-top: 1px solid #e9ecef;
    border-radius: 0 0 12px 12px;
}

.popup-action {
    flex: 1;
    min-width: 60px;
    padding: 8px 12px;
    background: #667eea;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 12px;
    text-align: center;
    font-weight: 500;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    font-family: inherit;
    line-height: 1.4;
}

.popup-action:hover {
    background: #5568d3;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.popup-action:active {
    transform: translateY(0);
}

.popup-action.secondary {
    background: #6c757d;
}

.popup-action.secondary:hover {
    background: #5a6268;
}

/* ─── PHOTO SECTION IN POPUP ──────────────────────────────────────────── */
.popup-body img {
    width: 100%;
    height: 140px;
    object-fit: cover;
    border-radius: 6px;
    margin: 8px 0;
    display: block;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.popup-body img:hover {
    transform: scale(1.02);
}

/* ─── RATING SECTION ──────────────────────────────────────────────────── */
.popup-rating {
    color: #f39c12;
    font-weight: 600;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ─── RESPONSIVE ──────────────────────────────────────────────────────── */
@media (max-width: 480px) {
    .leaflet-popup-content {
        max-width: 280px !important;
    }

    .popup-footer {
        flex-direction: column;
    }

    .popup-action {
        width: 100%;
        min-width: auto;
    }
}

/* ─── ANIMATIONS ──────────────────────────────────────────────────────── */
@keyframes popupSlideUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.leaflet-popup {
    animation: popupSlideUp 0.2s ease-out;
}
