/* ============================================================
   LF BnB — Plum Guide style
   ============================================================ */

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

:root {
    --lf-cream: #ffffff;
    --lf-amber: #e8a020;
    --lf-amber-h: #cf8d18;
    --lf-dark: #1a1a1a;
    --lf-text: #3d3d3d;
    --lf-muted: #717171;
    --lf-border: #dddddd;
    --lf-white: #ffffff;
    --lf-radius: 12px;
}

.lf-bnb-wrapper {
    font-family: "Plus Jakarta Sans";
    color: var(--lf-text);
    background: var(--lf-cream);
    min-height: 100vh;
}

/* ── Search bar ── */
.lf-search-bar {
    display: flex;
    align-items: center;
    background: var(--lf-white);
    border: 1.5px solid var(--lf-border);
    border-radius: 2px;
    padding: 6px 6px 6px 0;
    gap: 0;
    margin-bottom: 24px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.lf-search-section {
    flex: 1;
    padding: 8px 20px;
    border-right: 1.5px solid var(--lf-border);
    cursor: pointer;
    position: relative;
}

.lf-search-section:last-of-type {
    border-right: none;
}

.lf-search-section:hover {
    background: #f5f5f5;
    border-radius: 2px;
}

.lf-search-label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: var(--lf-dark);
    margin-bottom: 2px;
}

.lf-search-input {
    width: 100%;
    border: none;
    background: transparent;
    font-size: 14px;
    color: var(--lf-muted);
    outline: none;
    padding: 0;
    cursor: pointer;
    font-family: inherit;
}

.lf-search-input::placeholder {
    color: var(--lf-muted);
}
.lf-search-input:focus {
    color: var(--lf-dark);
}

.lf-search-guests-display {
    font-size: 14px;
    color: var(--lf-muted);
    cursor: pointer;
    user-select: none;
}

.lf-search-btn {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--lf-amber);
    color: var(--lf-white);
    border: none;
    border-radius: 50px;
    padding: 14px 22px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
    margin-left: 6px;
    white-space: nowrap;
}

.lf-search-btn:hover {
    background: var(--lf-amber-h);
}

.lf-search-btn svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

/* Guests dropdown */
.lf-guests-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    background: var(--lf-white);
    border: 1px solid var(--lf-border);
    border-radius: var(--lf-radius);
    padding: 16px 20px;
    min-width: 280px;
    z-index: 200;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.lf-guests-dropdown.open {
    display: block;
}

.lf-guest-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.lf-guest-row:last-child {
    border-bottom: none;
}

.lf-guest-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--lf-dark);
}
.lf-guest-sublabel {
    font-size: 12px;
    color: var(--lf-muted);
}

.lf-guest-counter {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lf-counter-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1.5px solid var(--lf-border);
    background: var(--lf-white);
    font-size: 18px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--lf-muted);
    transition:
        border-color 0.2s,
        color 0.2s;
}

.lf-counter-btn:hover {
    border-color: var(--lf-dark);
    color: var(--lf-dark);
}
.lf-counter-btn:disabled {
    opacity: 0.3;
    cursor: default;
}
.lf-counter-val {
    font-size: 15px;
    font-weight: 600;
    min-width: 20px;
    text-align: center;
    color: var(--lf-dark);
}

/* ── Toolbar row (filters + sort) ── */
.lf-bnb-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.lf-bnb-cat-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.lf-cat-tab {
    padding: 8px 18px;
    border: 1.5px solid var(--lf-border);
    border-radius: 50px;
    background: var(--lf-white);
    color: var(--lf-text);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.18s;
    white-space: nowrap;
}

.lf-cat-tab:hover {
    border-color: var(--lf-dark);
}
.lf-cat-tab.active {
    background: var(--lf-dark);
    border-color: var(--lf-dark);
    color: var(--lf-white);
}

.lf-bnb-sort {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--lf-muted);
}

.lf-bnb-sort select {
    border: 1.5px solid var(--lf-border);
    border-radius: 50px;
    padding: 7px 14px;
    font-size: 13px;
    cursor: pointer;
    background: var(--lf-white);
    color: var(--lf-dark);
    outline: none;
}

/* ── Result count ── */
.lf-result-count {
    font-size: 13px;
    color: var(--lf-muted);
    margin-bottom: 12px;
}

/* ── Main split ── */
.lf-bnb-main {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

.lf-bnb-listings-col {
    flex: 1 1 0;
    min-width: 0;
}

.lf-bnb-map-col {
    flex: 0 0 480px;
    width: 480px;
}

.lf-bnb-map-sticky {
    position: sticky;
    top: 16px;
}

#lf-bnb-map {
    height: calc(100vh - 80px);
    max-height: 820px;
    border-radius: var(--lf-radius);
    overflow: hidden;
}

/* ── Property list (horizontal cards) ── */
.lf-bnb-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* ── Single card ── */
.lf-card {
    display: flex;
    align-items: stretch;
    gap: 0;
    background: var(--lf-white);
    border-bottom: 1px solid var(--lf-border);
    padding: 20px 10px;
    cursor: pointer;
    transition: background 0.15s;
    position: relative;
}

.lf-card:first-child {
    border-top: 1px solid var(--lf-border);
}
.lf-card:hover {
    background: #fdfbf8;
}

.lf-card.lf-card--highlighted {
    background: f5f5f5;
}

/* Card image */
.lf-card-image-wrap {
    flex-shrink: 0;
    width: 260px;
    height: 180px;
    border-radius: var(--lf-radius);
    overflow: hidden;
    position: relative;
}

.lf-card-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-color: #e8e8e8;
    transition: transform 0.3s;
}

.lf-card:hover .lf-card-image {
    transform: scale(1.03);
}

.lf-card-cat-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--lf-amber);
    color: var(--lf-white);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 9px;
    border-radius: 50px;
}

/* Belge/izin no rozeti — köşede diyagonal şerit, yasal olarak zorunlu gösterim */
.lf-card-permit-ribbon {
    position: absolute;
    top: 14px;
    right: -34px;
    width: 140px;
    transform: rotate(45deg);
    background: #1a1a1a;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.3px;
    text-align: center;
    padding: 4px 0;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
    z-index: 2;
}

.lf-card-status {
    position: absolute;
    bottom: 10px;
    left: 10px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    padding: 3px 9px;
    border-radius: 50px;
    color: #fff;
}

.lf-status-open {
    background: #2ecc71;
}
.lf-status-closed {
    background: #888;
}

/* İzin/belge rozeti varsa favori butonu köşede çakışmasın diye aşağı iner */
.lf-card-permit-ribbon ~ .lf-fav-btn {
    top: 46px;
}

/* Favorite button */
.lf-fav-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition:
        background 0.2s,
        transform 0.15s;
}

.lf-fav-btn:hover {
    background: #fff;
    transform: scale(1.1);
}
.lf-fav-btn svg {
    width: 16px;
    height: 16px;
}
.lf-fav-btn.active svg {
    fill: #e8294c;
    stroke: #e8294c;
}

/* Card body */
.lf-card-body {
    flex: 1;
    padding: 0 0 0 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.lf-card-top {
    flex: 1;
}

.lf-card-title {
    margin: 0 0 4px;
    font-size: 17px;
    font-weight: 600;
    line-height: 1.3;
    color: var(--lf-dark);
}

.lf-card-title a {
    color: inherit;
    text-decoration: none;
}

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

.lf-card-address {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: var(--lf-muted);
    margin: 0 0 10px;
}

.lf-card-address svg {
    width: 12px;
    height: 12px;
    flex-shrink: 0;
}

.lf-card-specs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    font-size: 13px;
    color: var(--lf-muted);
    margin-bottom: 10px;
}

.lf-card-specs span {
    white-space: nowrap;
}
.lf-card-specs span + span::before {
    content: " • ";
}

.lf-card-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    color: #2e7d32;
    font-weight: 500;
    margin-bottom: 12px;
}

.lf-card-badge svg {
    width: 13px;
    height: 13px;
    flex-shrink: 0;
}

.lf-card-amenities {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 10px;
}

.lf-amenity-tag {
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 50px;
    background: #f0f0f0;
    color: #555;
}

/* Card footer */
.lf-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 10px;
    border-top: 1px solid #f0f0f0;
}

.lf-card-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    font-weight: 600;
    color: var(--lf-dark);
}

.lf-card-rating svg {
    width: 13px;
    height: 13px;
}

.lf-card-price {
    font-size: 14px;
    font-weight: 700;
    color: var(--lf-dark);
}

.lf-card-price span {
    font-weight: 400;
    font-size: 12px;
    color: var(--lf-muted);
}

/* ── Loading / no results ── */
.lf-no-results {
    text-align: center;
    color: var(--lf-muted);
    padding: 48px 0;
    font-size: 15px;
}

.lf-bnb-loading .lf-bnb-list {
    opacity: 0.45;
    pointer-events: none;
}

/* ── Pagination ── */
.lf-bnb-pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 28px;
    flex-wrap: wrap;
}

.lf-page-btn {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--lf-border);
    border-radius: 50%;
    background: var(--lf-white);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    color: var(--lf-text);
    transition: all 0.18s;
}

.lf-page-btn:hover {
    border-color: var(--lf-dark);
}
.lf-page-btn.active {
    background: var(--lf-dark);
    border-color: var(--lf-dark);
    color: #fff;
}

/* ── Leaflet overrides ── */
.leaflet-popup-content-wrapper {
    padding: 0 !important;
    border-radius: var(--lf-radius) !important;
    overflow: hidden;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.16) !important;
}

.leaflet-popup-content {
    margin: 0 !important;
    width: auto !important;
}

.leaflet-popup-close-button {
    color: #fff !important;
    background: rgba(0, 0, 0, 0.35) !important;
    border-radius: 50% !important;
    width: 24px !important;
    height: 24px !important;
    font-size: 16px !important;
    line-height: 24px !important;
    text-align: center !important;
    top: 8px !important;
    right: 8px !important;
    padding: 0 !important;
    z-index: 10;
}

/* Map popup card */
.lf-map-popup {
    width: 230px;
}

.lf-map-popup-image {
    width: 100%;
    height: 140px;
    object-fit: cover;
    display: block;
}

.lf-map-popup-body {
    padding: 10px 12px 14px;
}

.lf-map-popup-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--lf-dark);
    margin: 0 0 3px;
}

.lf-map-popup-address,
.lf-map-popup-specs {
    font-size: 12px;
    color: var(--lf-muted);
    margin: 0 0 8px;
}

.lf-map-popup-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.lf-map-popup-rating {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 13px;
    font-weight: 700;
}

.lf-map-popup-rating svg {
    width: 12px;
    height: 12px;
}

.lf-map-popup-link {
    font-size: 12px;
    font-weight: 700;
    color: var(--lf-white);
    background: var(--lf-amber);
    text-decoration: none;
    padding: 5px 12px;
    border-radius: 50px;
    transition: background 0.18s;
}

.lf-map-popup-link:hover {
    background: var(--lf-amber-h);
}

/* Map marker: home icon */
.lf-marker-icon {
    width: 36px;
    height: 36px;
    background: var(--lf-white);
    border: 2px solid var(--lf-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition:
        background 0.15s,
        border-color 0.15s;
    cursor: pointer;
}

.lf-marker-icon svg {
    width: 16px;
    height: 16px;
    color: var(--lf-dark);
}

.lf-marker-icon:hover,
.lf-marker-icon.active {
    background: var(--lf-amber);
    border-color: var(--lf-amber);
}

.lf-marker-icon:hover svg,
.lf-marker-icon.active svg {
    color: #fff;
}

/* ── Responsive ── */
@media (max-width: 1100px) {
    .lf-bnb-map-col {
        flex: 0 0 380px;
        width: 380px;
    }
    .lf-card-image-wrap {
        width: 200px;
    }
}

@media (max-width: 860px) {
    .lf-bnb-main {
        flex-direction: column;
    }
    .lf-bnb-map-col {
        flex: none;
        width: 100%;
        order: -1;
    }
    #lf-bnb-map {
        height: 320px;
        max-height: 320px;
    }
    .lf-bnb-map-sticky {
        position: static;
    }
    .lf-card-image-wrap {
        width: 160px;
        height: 140px;
    }
}

@media (max-width: 560px) {
    .lf-search-bar {
        flex-wrap: wrap;
        border-radius: var(--lf-radius);
        padding: 12px;
        gap: 8px;
    }
    .lf-search-section {
        border-right: none;
        border-bottom: 1px solid var(--lf-border);
        padding: 8px 4px;
    }
    .lf-search-section:last-of-type {
        border-bottom: none;
    }
    .lf-search-btn {
        width: 100%;
        justify-content: center;
        margin-left: 0;
    }
    .lf-card {
        flex-direction: column;
    }
    .lf-card-image-wrap {
        width: 100%;
        height: 200px;
        border-radius: var(--lf-radius) var(--lf-radius) 0 0;
    }
    .lf-card-body {
        padding: 14px 0 0;
    }
}
