/* ==========================================================================
   LVD REAL ESTATE - FILTER BAR & ARCHIVE / SINGLE (PURE CSS)
   ========================================================================== */

/* --- 1. MĂȘTI SVG PENTRU ICONIȚE (Bootstrap Icons) --- */
.lvd-icon {display: inline-block; background-color: #94a3b8; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-size: contain; mask-size: contain; -webkit-mask-position: center; mask-position: center; transition: transform 0.3s ease;}
.lvd-icon-chevron-down {width: 20px; height: 20px; -webkit-mask-image: url('../assets/svg/bs-icons/chevron-down.svg'); mask-image: url('../assets/svg/bs-icons/chevron-down.svg');}
.lvd-icon-search {width: 18px; height: 18px; background-color: #ffffff; -webkit-mask-image: url('../assets/svg/bs-icons/search.svg'); mask-image: url('../assets/svg/bs-icons/search.svg');}
.lvd-icon-filter {width: 24px; height: 24px; background-color: #ffffff; -webkit-mask-image: url('../assets/svg/bs-icons/sliders.svg'); mask-image: url('../assets/svg/bs-icons/sliders.svg');}
.lvd-icon-geo {width: 14px; height: 14px; background-color: currentColor; -webkit-mask-image: url('../assets/svg/bs-icons/geo-alt-fill.svg'); mask-image: url('../assets/svg/bs-icons/geo-alt-fill.svg');}
.lvd-icon-rotate {transform: rotate(180deg);}
.lvd-hidden {display: none !important;}

/* --- 2. LAYOUT FILTER BAR --- */
.lvd-modern-filter-bar {background-color: #ffffff; border: 1px solid #f3f4f6; border-radius: 16px; padding: 12px; margin-bottom: 2rem; box-shadow: 0 10px 40px -10px rgba(0,0,0,0.08); position: relative; z-index: 40;}
.lvd-realestate-filter-form {display: flex; flex-direction: column; gap: 12px;}
.lvd-custom-filter-group {position: relative; width: 100%; flex: 1;}

/* --- 3. STILIZARE BUTON TRIGGER --- */
.lvd-filter-trigger {width: 100%; display: flex; justify-content: space-between; align-items: center; background-color: #f8fafc; border: 1px solid transparent; padding: 14px 16px; border-radius: 12px; text-align: left; cursor: pointer; transition: all 0.2s ease;}
.lvd-filter-trigger:hover {background-color: #f1f5f9; border-color: #e2e8f0;}
.lvd-trigger-text {display: flex; flex-direction: column;}
.lvd-trigger-label {font-size: 10px; font-weight: 700; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 2px;}
.lvd-selected-text {font-size: 14px; font-weight: 600; color: #1e293b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;}

/* --- 4. DROPDOWN OPTIONS --- */
.lvd-filter-options {position: absolute; top: calc(100% + 8px); left: 0; width: 100%; background-color: #ffffff; border: 1px solid #f1f5f9; border-radius: 12px; box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.1); z-index: 50; overflow: hidden;}
.lvd-options-list {max-height: 240px; overflow-y: auto; padding: 6px; margin: 0; list-style: none;}
.lvd-options-list::-webkit-scrollbar {width: 4px;}
.lvd-options-list::-webkit-scrollbar-thumb {background: #cbd5e1; border-radius: 4px;}
.lvd-radio-label {display: flex; align-items: center; padding: 10px 12px; border-radius: 8px; cursor: pointer; transition: background-color 0.2s; margin: 0;}
.lvd-radio-label:hover {background-color: #eff6ff;}
.lvd-option-text {font-size: 14px; color: #475569; width: 100%;}
.lvd-option-text.lvd-active {color: var(--lvd-color-primary, #2563eb); font-weight: 700;}

/* --- 5. LIVE SEARCH ÎN DROPDOWN --- */
.lvd-dropdown-search {padding: 10px; border-bottom: 1px solid #f1f5f9; background-color: #fafafa; border-radius: 12px 12px 0 0;}
.lvd-loc-search-input {width: 100%; padding: 10px 14px; border: 1px solid #e2e8f0; border-radius: 8px; font-size: 13px; color: #1e293b; background-color: #ffffff; outline: none; transition: border-color 0.2s, box-shadow 0.2s; box-sizing: border-box;}
.lvd-loc-search-input:focus {border-color: var(--lvd-color-primary, #2563eb); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);}
.lvd-no-loc-results {padding: 16px; text-align: center; font-size: 13px; color: #94a3b8; font-style: italic;}

/* --- 6. BUTON CAUTARE --- */
.lvd-submit-group {width: 100%;}
.lvd-apply-filters-btn {width: 100%; display: flex; justify-content: center; align-items: center; gap: 8px; background-color: var(--lvd-color-primary, #2563eb); color: #ffffff; font-weight: 700; font-size: 15px; padding: 14px 20px; border: none; border-radius: 12px; cursor: pointer; box-shadow: 0 4px 14px 0 rgba(37, 99, 235, 0.3); transition: transform 0.2s, box-shadow 0.2s;}
.lvd-apply-filters-btn:hover {transform: translateY(-1px); box-shadow: 0 6px 20px 0 rgba(37, 99, 235, 0.4);}

/* --- 7. MOBILE FAB (Buton Plutitor) --- */
.lvd-mobile-fab-filter {position: fixed; bottom: 24px; right: 24px; width: 56px; height: 56px; background-color: var(--lvd-color-primary, #2563eb); border: none; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.5); z-index: 999; cursor: pointer; transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s;}
.lvd-hide-fab {transform: translateY(100px); opacity: 0; pointer-events: none;}

/* --- 8. ARCHIVE & LISTING --- */
.lvd-property-archive {padding: 0 8px;}
.lvd-property-archive .lvd-property-archive-header {padding: 24px 16px;}
.lvd-box-ansamblu {background: var(--lvd-color-white); border-radius: var(--lvd-rounded); position: relative;}
.lvd-box-ansamblu .lvd-img img {border-radius: var(--lvd-rounded-top);}
.lvd-box-ansamblu .lvd-content {padding: 16px 16px 32px 16px;}
.lvd-box-ansamblu .lvd-title {font-size: var(--lvd-text-h4); color: var(--lvd-color-black); margin-bottom: 16px;}
.lvd-box-ansamblu .lvd-keyword {font-size: var(--lvd-text-s1); margin-bottom: 8px; color: var(--lvd-color-tertiary);}
.lvd-box-ansamblu .lvd-ansamblu-unit {margin-bottom: 8px;}
.lvd-box-ansamblu .lvd-price-from {margin-bottom: 16px;}
.lvd-box-ansamblu .lvd-button-primary-small {position: absolute; bottom: 8px; right: 8px;}

/* --- 9. SINGLE PROPERTY --- */
.lvd-property-single .lvd-breadcrumbs {margin-left: 16px; margin-right: 16px; margin-bottom: 16px;}
.lvd-property-single .lvd-property-hero {margin-left: 8px; margin-right: 8px;}
.lvd-property-hero {background: var(--lvd-color-white); border-radius: var(--lvd-rounded);}
.lvd-property-summary .lvd-content {padding: 16px;}
.lvd-property-image img {border-radius: var(--lvd-rounded);}
.lvd-property-location {margin-bottom: 16px;}
.lvd-property-price {margin-bottom: 16px;}
.lvd-property-types .lvd-title {margin-bottom: 8px; font-weight: 700;}
.lvd-property-related {margin-left: 8px; margin-right: 8px;}

/* --- 10. GOOGLE MAPS EMBED --- */
.lvd-property-map {scroll-margin-top: 100px;}
.lvd-map-wrapper {width: 100%; border-radius: 16px; overflow: hidden; background-color: #f8fafc;}
.lvd-map-wrapper iframe {width: 100% !important; height: 450px !important; display: block; border: 0 !important;}

/* --- 11. GRAVITY FORMS OVERWRITE --- */
.lvd-property-form {background: var(--lvd-color-primary); border-radius: var(--lvd-rounded); color: var(--lvd-color-white); padding: 60px 120px;}
.lvd-property-form a {color: var(--lvd-color-white);}
.lvd-property-form .percentbar_blue {background: var(--lvd-color-success) !important;}
.lvd-property-form .gf_progressbar_title {color: var(--lvd-color-white) !important;}
.lvd-property-form .gsection {border-bottom: 1px solid rgba(255,255,255,0.2) !important;}
.lvd-property-form .button {background: var(--lvd-color-success); color: var(--lvd-color-white); border: none; display: inline-block; height: 48px; line-height: 46px; font-weight: 700; font-size: var(--lvd-text-body); padding: 0 24px; border-radius: 25px;}
.lvd-property-form .gfield_list_icons button {background-color: var(--lvd-color-success) !important; border-radius: 8px;}
.lvd-property-form .gfield_required {color: var(--lvd-color-white) !important;}


/*############################# MOBILE ONLY (max-width: 767px) #############################*/
@media (max-width: 767px) {
    .lvd-property-map {margin-left: 8px; margin-right: 8px;}
    .lvd-map-wrapper iframe {height: 300px !important;}
    .lvd-property-form                      {padding:40px 24px; margin-right:8px; margin-left:8px;}
}


/*############################# TABLET & DESKTOP (min-width: 768px) #############################*/
@media (min-width: 768px) {
    /* Filter Bar */
    .lvd-modern-filter-bar {position: sticky; top: 70px;}
    .lvd-realestate-filter-form {flex-direction: row; align-items: center;}
    .lvd-submit-group {width: 20%; flex: none;}
    .lvd-mobile-fab-filter {display: none !important;}

    /* Archive */
    .lvd-property-archive {padding: 0;}
    .lvd-property-archive .lvd-property-archive-header {padding: 32px 0;}

    /* Single */
    .lvd-property-single .lvd-property-hero {margin-left: 0; margin-right: 0;}
    .lvd-property-single .lvd-breadcrumbs {margin-left: 0; margin-right: 0;}
    .lvd-property-summary .lvd-content {padding: 32px;}
    .lvd-property-related {margin-left: auto; margin-right: auto;}
}