/* NOVVIA Esthetic Finder - Frontend */

.nef-finder { max-width: 1200px; margin: 0 auto; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; }

/* Search Bar */
.nef-search-bar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 16px; }
.nef-search-input-wrap { display: flex; gap: 8px; flex: 1; min-width: 280px; }
.nef-search-input-wrap input { flex: 1; padding: 10px 16px; border: 1px solid #d1d5db; border-radius: 8px; font-size: 15px; outline: none; }
.nef-search-input-wrap input:focus { border-color: #1a1a6c; box-shadow: 0 0 0 2px rgba(26,26,108,0.15); }
#nef-search-btn { padding: 10px 24px; border: none; border-radius: 8px; background: #1a1a6c; color: #fff; font-size: 14px; font-weight: 600; cursor: pointer; transition: background 0.2s; }
#nef-search-btn:hover { background: #2a2a8c; }
#nef-locate-btn { padding: 10px 14px; border: 1px solid #d1d5db; border-radius: 8px; background: #fff; font-size: 18px; cursor: pointer; transition: background 0.2s; }
#nef-locate-btn:hover { background: #f1f5f9; }

/* Brand Filter */
.nef-brand-filters { display: flex; gap: 8px; flex-wrap: wrap; }
.nef-brand-btn { width: 48px; height: 48px; border: 2px solid #e2e8f0; border-radius: 8px; background: #fff; cursor: pointer; padding: 4px; transition: all 0.2s; display: flex; align-items: center; justify-content: center; }
.nef-brand-btn img { width: 100%; height: 100%; object-fit: contain; }
.nef-brand-btn:hover { border-color: #1a1a6c; transform: scale(1.05); }
.nef-brand-btn.active { border-color: #1a1a6c; box-shadow: 0 0 0 3px rgba(26,26,108,0.2); background: #f0f0ff; }

/* Map */
#nef-map { height: 500px; border-radius: 12px; border: 1px solid #e2e8f0; z-index: 1; }

/* Custom Marker */
.nef-marker { background: none !important; border: none !important; }
.nef-marker-pin { width: 24px; height: 24px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); position: relative; }
.nef-marker-pin::after { content: ''; width: 10px; height: 10px; background: #fff; border-radius: 50%; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); }

/* Popup */
.leaflet-popup-content-wrapper { border-radius: 12px !important; box-shadow: 0 8px 30px rgba(0,0,0,0.15) !important; padding: 0 !important; }
.leaflet-popup-content { margin: 0 !important; padding: 0 !important; }
.leaflet-popup-tip { box-shadow: 0 4px 10px rgba(0,0,0,0.1) !important; }

.nef-popup { min-width: 420px; font-size: 14px; line-height: 1.6; }
.nef-popup-header { padding: 20px 24px; border-radius: 12px 12px 0 0; color: #fff; text-align: center; }
.nef-popup-header-name { font-size: 20px; font-weight: 700; letter-spacing: 0.5px; }
.nef-popup-header-addr { font-size: 13px; opacity: 0.85; margin-top: 4px; }
.nef-popup-logo-wrap { text-align: center; padding: 16px 0; background: #f8fafc; border-bottom: 1px solid #e2e8f0; }
.nef-popup-logo { max-width: 400px; width: 100%; max-height: 120px; object-fit: contain; }

.nef-popup-body { padding: 16px 22px; }
.nef-popup-section { margin-bottom: 14px; }
.nef-popup-section-title { font-size: 11px; text-transform: uppercase; letter-spacing: 1px; color: #94a3b8; font-weight: 700; margin-bottom: 5px; }

.nef-popup-contact { font-size: 13px; margin-bottom: 4px; color: #334155; }
.nef-popup-contact a { color: #1a1a6c; text-decoration: none; }
.nef-popup-contact a:hover { text-decoration: underline; }

.nef-popup-hours { font-size: 11px; color: #64748b; line-height: 1.8; }
.nef-popup-hour { display: inline-block; margin-right: 8px; }
.nef-popup-hour strong { color: #334155; }

.nef-popup-treatments { display: flex; flex-wrap: wrap; gap: 4px; }

.nef-popup-desc { font-size: 13px; color: #475569; line-height: 1.7; }
.nef-popup-desc p { margin: 0 0 6px; }
.nef-popup-desc ul, .nef-popup-desc ol { margin: 4px 0; padding-left: 18px; }
.nef-popup-desc strong { color: #1e293b; }

.nef-popup-gallery { display: flex; gap: 4px; overflow-x: auto; padding-bottom: 4px; }
.nef-popup-gallery-img { width: 100px; height: 72px; object-fit: cover; border-radius: 6px; flex-shrink: 0; border: 1px solid #e2e8f0; cursor: pointer; transition: all 0.2s; }
.nef-popup-gallery-img:hover { transform: scale(1.05); box-shadow: 0 2px 8px rgba(0,0,0,0.15); }

/* Partner-Modal (ersetzt Leaflet-Popup) */
.nef-modal-overlay {
    position: fixed; inset: 0;
    background: rgba(15, 23, 42, 0.65);
    z-index: 100000;
    display: flex; align-items: center; justify-content: center;
    padding: 20px;
    animation: nefFadeIn 0.18s ease-out;
}
.nef-modal-content {
    position: relative;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.35);
    max-width: 720px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    animation: nefScaleIn 0.2s ease-out;
}
.nef-modal-content .nef-popup { min-width: 0; }
.nef-modal-close {
    position: absolute; top: 12px; right: 14px;
    width: 32px; height: 32px;
    border: none; border-radius: 50%;
    background: rgba(255,255,255,0.9);
    color: #1e293b; font-size: 22px; line-height: 1;
    cursor: pointer; z-index: 2;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
    transition: all 0.15s;
}
.nef-modal-close:hover { background: #fff; transform: scale(1.1); }
body.nef-modal-open { overflow: hidden; }
@keyframes nefFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes nefScaleIn { from { opacity: 0; transform: scale(0.96); } to { opacity: 1; transform: scale(1); } }

/* Lightbox */
.nef-lightbox { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.85); z-index: 200000; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.nef-lightbox img { max-width: 90vw; max-height: 90vh; border-radius: 8px; box-shadow: 0 8px 40px rgba(0,0,0,0.4); }
.nef-lightbox-close { position: absolute; top: 20px; right: 30px; color: #fff; font-size: 36px; font-weight: 300; cursor: pointer; line-height: 1; }
.nef-lightbox-close:hover { color: #ccc; }

.nef-popup-brands { display: flex; gap: 6px; align-items: center; }
.nef-popup-brands img { width: 32px; height: 32px; object-fit: contain; }

.nef-popup-actions { display: flex; gap: 8px; padding: 14px 22px; border-top: 1px solid #e2e8f0; background: #f8fafc; border-radius: 0 0 12px 12px; }
.nef-popup-btn { display: inline-flex; align-items: center; gap: 4px; padding: 9px 18px; border-radius: 6px; font-size: 12px; font-weight: 600; text-decoration: none; background: #fff; color: #1a1a6c; border: 1px solid #e2e8f0; transition: all 0.2s; flex: 1; justify-content: center; }
.nef-popup-btn:hover { background: #f1f5f9; border-color: #1a1a6c; }
.nef-popup-btn-route { background: #1a1a6c; color: #fff; border-color: #1a1a6c; }
.nef-popup-btn-route:hover { background: #2a2a8c; color: #fff; }

/* Results */
.nef-results { margin-top: 20px; }
.nef-results-count { font-size: 14px; color: #64748b; margin-bottom: 12px; font-weight: 600; }
.nef-results-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.nef-card { display: flex; gap: 16px; background: #fff; border: 1px solid #e2e8f0; border-radius: 10px; padding: 16px; cursor: pointer; transition: all 0.2s; }
.nef-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.08); border-color: #1a1a6c; }
.nef-card-logo { width: 60px; height: 60px; flex-shrink: 0; }
.nef-card-logo img { width: 100%; height: 100%; object-fit: contain; border-radius: 6px; }
.nef-card-info { flex: 1; min-width: 0; }
.nef-card-name { margin: 0 0 4px; font-size: 15px; font-weight: 600; }
.nef-card-address { font-size: 13px; color: #64748b; }
.nef-card-phone { font-size: 13px; margin-top: 4px; }
.nef-card-distance { font-size: 12px; color: #1a1a6c; font-weight: 600; margin-top: 4px; }
.nef-card-brands { display: flex; gap: 4px; margin-top: 8px; }
.nef-card-brands img { width: 28px; height: 28px; object-fit: contain; }
.nef-card-hours { font-size: 11px; color: #64748b; margin-top: 4px; }
.nef-card-treatments { display: flex; flex-wrap: wrap; gap: 3px; margin-top: 6px; }
.nef-card-actions { display: flex; gap: 6px; margin-top: 10px; padding-top: 8px; border-top: 1px solid #f1f5f9; }
.nef-card-btn { display: inline-flex; align-items: center; gap: 4px; padding: 5px 12px; border-radius: 6px; font-size: 12px; font-weight: 600; text-decoration: none; background: #f1f5f9; color: #1a1a6c; transition: background 0.2s; }
.nef-card-btn:hover { background: #e2e8f0; }
.nef-card-btn-route { background: #1a1a6c; color: #fff; }
.nef-card-btn-route:hover { background: #2a2a8c; color: #fff; }

/* Behandlungs-Tags */
.nef-treatment-tag { display: inline-block; background: #e7f5ff; color: #004085; padding: 2px 8px; border-radius: 12px; font-size: 11px; }

.nef-no-results { text-align: center; color: #64748b; padding: 40px; font-size: 15px; }

/* Account Form */
.nef-account { max-width: 700px; }
.nef-account input[type="text"],
.nef-account textarea { border: 1px solid #d1d5db; border-radius: 6px; padding: 8px 12px; font-size: 14px; }
.nef-account input[type="text"]:focus,
.nef-account textarea:focus { border-color: #1a1a6c; outline: none; box-shadow: 0 0 0 2px rgba(26,26,108,0.15); }

/* Responsive */
@media (max-width: 768px) {
    .nef-search-bar { flex-direction: column; }
    #nef-map { height: 350px !important; }
    .nef-results-list { grid-template-columns: 1fr; }
}
