/* ========================================
   PROPERTIES PAGE
   ======================================== */
.row {
       padding: 2rem 0;
}

.filters-column {
    position: sticky;
    top:0;
    height: 100vh;
    overflow-y: auto;
    overflow-x: hidden;
}

.filters-column::-webkit-scrollbar {
    width: 5px;
}
.filters-column::-webkit-scrollbar-thumb {
    background: var(--gold-color);
    border-radius: 4px;
}
.filters-column::-webkit-scrollbar-thumb:hover {
    background: var(--gold-color-light);
}
.filters-column::-webkit-scrollbar-track {
    background: rgba(0, 0, 0,0.1);
}
body.dark-theme .filters-column::-webkit-scrollbar-track {
    background: rgba(0, 0, 0,0.1);
}

/* Filter Controls */
.filter-container {
    background-color: transparent;
    border-radius: var(--border-radius);
    border: var(--box-border);
    box-shadow: var(--box-shadow);
    padding: 1rem;
    height:100%;
    
}



.title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 2rem;
    padding-bottom: 10px;
    text-decoration: underline 3px solid var(--gold-color-secondary);
    text-underline-offset: 10px;
    text-align: center;
    letter-spacing: 3px;
    font-style: italic;
}

body.dark-theme .title {
    color: var(--dark-text-color);
}

.filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.filter-group {
    margin-bottom: 1rem;
}

.filter-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--font-color);
}


/* ========================================
   CUSTOM INPUT & DROPDOWN (SELECT)
   ======================================== */

.custom-input {
    position: relative;
    background: linear-gradient(to right, rgb(240, 240, 240), rgb(245, 245, 245), rgb(240, 240, 240));
    font-size: 1rem;
    border: 2px solid transparent;
    border-radius: 8px;
    transition: all 0.3s ease;
    min-height: 45px;
    width: 100%;
    padding: 10px 15px;
    color: #333;
    position: relative;
    display: flex;
    align-items: center;
}

.custom-input:focus {
    border: 2px solid var(--gold-color-dark);

}

/* --- Dark Theme for Custom Input --- */
body.dark-theme .custom-input {
    background: rgba(0, 0, 0, 0.4);
    border-radius: 8px;
    border: 2px solid transparent;
    color: var(--dark-text-color);

}

body.dark-theme .custom-input:focus {
    border: 2px solid var(--gold-color-dark);
}



.custom-select {
    position: relative;
    background: linear-gradient(to right, rgb(240, 240, 240), rgb(245, 245, 245), rgb(240, 240, 240));
    border: 2px solid transparent;
    border-radius: 8px;
    transition: all 0.3s ease;
    min-height: 45px;
}

.custom-select .select-selected {
    padding: 10px 15px;
    font-size: 1rem;
    color: #666;
    cursor: pointer;
    position: relative;
    padding-right: 40px;
    min-height: 35px;
    display: flex;
    align-items: center;
}

.custom-select .select-selected .has-value {
    color: #333;
}

.custom-select .select-selected::after {
    content: '';
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid var(--text-color);
    transition: transform 0.3s ease;
}

.custom-select.active .select-selected::after {
    transform: translateY(-50%) rotate(180deg);
}

.custom-select .select-items {
    position: absolute;
    top: 125%;
    bottom: auto;
    display: none;
    left: 0;
    right: 0;
    transform: translateY(-7px);
    z-index: 999 !important;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 2px solid var(--gold-color-dark);
    border-radius: 8px;
    max-height: 250px;
    overflow-x: hidden;
    overflow-y: auto;
    box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: -2px;

}

.custom-select.active .select-items {
    display: block;
}

.custom-select.drop-up .select-items {
    top: auto !important;
    bottom: 100% !important;
}

.custom-select .option {
    padding: 10px 15px;
    min-height: 35px;
    width: 100%;
    cursor: pointer;
    color: var(--text-color);
    transition: all 0.3s ease;
    border-radius: 5px;
    margin: 2px;
    display: flex;
    align-items: center;
}

.custom-select .option:hover {
    background: rgba(139, 105, 20, 0.2);
}

.custom-select .option.selected {
    background: rgba(139, 105, 20, 0.3);
    color: var(--gold-color-dark);
    font-weight: 500;
}

.custom-select.active {
    border: 2px solid var(--gold-color-dark);
    border-radius: 8px;
}

.custom-select.active .select-selected {
    border-color: var(--gold-color-dark);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.custom-select.active .select-items {
    display: block;
}

.select-hide {
    display: none;
}

/* --- Dark Theme for Custom Dropdown --- */
body.dark-theme .custom-select {
    background: rgba(0, 0, 0, 0.4);
    border-radius: 8px;
    border: 2px solid transparent;

}

body.dark-theme .custom-select .select-selected {

    color: #aaa;
}

body.dark-theme .custom-select .select-selected .has-value {
    color: var(--dark-text-color);
}

body.dark-theme .custom-select .select-selected::after {
    border-top-color: white;
}

body.dark-theme .custom-select .select-items {
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid var(--gold-color-dark);
}

body.dark-theme .custom-select .option {
    color: white;
}

body.dark-theme .custom-select .option:hover {
    background: rgba(139, 105, 20, 0.3);
}

body.dark-theme .custom-select .option.selected {
    background: rgba(139, 105, 20, 0.4);
    color: var(--gold-color-secondary);
}

body.dark-theme .custom-select.active {
    border: 2px solid var(--gold-color-dark);
    border-radius: 8px;
}

body.dark-theme .custom-select.active .select-selected {
    color: var(--dark-text-color);
}

input[type="range"] {
    -webkit-appearance: none;
    width: 100%;
    height: 6px;
    background: transparent;
    border-radius: 5px;
    outline: none;
    margin-top: 10px;
}

input[type="range"]::-webkit-slider-runnable-track {
    height: 6px;
    background: var(--gold-color-secondary);
    border-radius: 10px;
}

input[type="range"]::-moz-range-track {
    height: 6px;
    background: var(--gold-color-secondary);
    border-radius: 5px;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    height: 18px;
    width: 18px;
    background: var(--gold-color);
    border-radius: 50%;
    cursor: pointer;
    margin-top: -6px;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.2);
    transition: background 0.3s ease;
}

input[type="range"]::-moz-range-thumb {
    height: 18px;
    width: 18px;
    background: var(--gold-color);
    border-radius: 50%;
    cursor: pointer;
    border: none;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.2);
}


/* Action Buttons */
.action-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}

.btn-reset {
    background-color: var(--gold-color);
    color: var(--dark-text-color);
    font-weight: 400;
    border: 2px solid var(--gold-color);
    margin-bottom:10rem;
    transition: all 0.3s ease-in-out;
}

.btn-reset:hover,
.btn-reset:focus,
.btn-reset:active
{
    background-color: transparent !important;
    color: var(--gold-color) !important;
    border: 2px solid var(--gold-color) !important;
    transform: translateY(-2px) !important;
}

body.dark-theme .btn-reset {
    background-color: var(--gold-color-secondary);
    color: var(--primary-color);
    font-weight: 400;
    border: 2px solid var(--gold-color-secondary);
    transition: all 0.3s ease-in-out;
}

body.dark-theme .btn-reset:hover,
body.dark-theme .btn-reset:focus,
body.dark-theme .btn-reset:active {
    background-color: transparent !important;
    color: var(--gold-color-secondary) !important;
    border: 2px solid var(--gold-color-secondary) !important;
    transform: translateY(-2px) !important;
}

/* Responsive Adjustments */
@media (max-width: 768px) {

    .filter-grid {
        grid-template-columns: 1fr;
    }

    .action-buttons {
        grid-template-columns: 1fr;
    }
}


/* --- Cards Container --- */
.result-container {
    background-color: transparent;
    border: none;
    margin-bottom: 2rem;
    padding: 1rem 0;
    /*border-left: 2px solid #ccc;*/


}

body.dark-theme .result-container {
    /*border-left: 2px solid var(--gold-color-light);*/
}

.loading-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.spinner-border.custom-color {
    color: var(--gold-color) !important;
}

.result {
    background: transparent;
    position: relative;
    overflow-x: hidden;
    overflow-y: auto;
    display: flex;
    padding: 0;
    flex-direction: column;

}




.cards-container {
    background: transparent;
    position: relative;
    width: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 1rem 2rem;
    margin-top:1rem;
    margin-bottom: 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

/* --- property Card --- */
.property-card {
    background: linear-gradient(to right, rgb(235, 235, 235), rgb(245, 245, 245), rgb(235, 235, 235));
    border-radius: 10px;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: transform 0.3s cubic-bezier(.25, .8, .25, 1), box-shadow 0.3s;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    max-width: 450px;
    min-width: 280px;
    height: 100%;
    min-height: 480px;
    padding: 0;
    border: 1px solid rgba(0, 0, 0, 0.3);
}

body.dark-theme .property-card {
    background: var(--box-color) !important;
    border: 2px solid rgba(212, 175, 55, 0.3);

}

.property-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 12px rgba(0, 0, 0, 0.5);
}

body.dark-theme .property-card:hover {
   /* background: var(--primary-color-light) !important;*/
    border: 2px solid rgba(212, 175, 55, 0.5);
}

.rent::after {
    content: "RENT";
    position: absolute;
    top: 10px;
    left: 10px;
    color: var(--dark-text-color);
    background-color: rgba(64, 0, 64, 0.8);
    border-radius: 5px;
    opacity: 1;
    padding:5px 10px;
    font-size: 0.7em;
    font-weight: bold;
    letter-spacing: 1px;
    z-index: 1;
}

.sale::after {
    content: "SALE";
    position: absolute;
    top: 10px;
    left: 10px;
    color: var(--dark-text-color);
    background-color: rgba(0, 64, 64, 0.8);
    border-radius: 5px;
    opacity: 1;
    padding:5px 10px;
    font-size: 0.7em;
    font-weight: bold;
    letter-spacing: 1px;
    z-index: 1;
}

.hot-deal::before {
    content: "HOT DEAL";
    position: absolute;
    top: 20px;
    right: -30px;
    width: 120px;
    text-align: center;
    transform: rotate(45deg);
    color: var(--dark-text-color);
    background-color: rgba(255, 102, 0, 0.7);
    border-radius: 5px;
    opacity: 1;
    padding: 5px 0;
    font-size: 0.7em;
    font-weight: bold;
    letter-spacing: 1px;
    z-index: 1;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.new::before {
    content: "NEW";
    position: absolute;
    top: 20px;
    right: -30px;
    width: 120px;
    text-align: center;
    transform: rotate(45deg);
    color: var(--dark-text-color);
    background-color: rgba(0, 128, 0, 0.7);
    border-radius: 5px;
    opacity: 1;
    padding: 5px 0;
    font-size: 0.7em;
    font-weight: bold;
    letter-spacing: 1px;
    z-index: 1;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.off-plan::before {
    content: "OFF-PLAN";
    position: absolute;
    top: 20px;
    right: -30px;
    width: 120px;
    text-align: center;
    transform: rotate(45deg);
    color: var(--dark-text-color);
    background-color: rgba(65, 105, 225, 0.7);
    border-radius: 5px;
    opacity: 1;
    padding: 5px 0;
    font-size: 0.7em;
    font-weight: bold;
    letter-spacing: 1px;
    z-index: 1;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.share-icon {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.2);
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.5);
    line-height: 1;
    padding: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: all 0.5s ease-in-out;
}


.share-icon:hover,
.share-icon:focus,
.share-icon:active {
    background-color: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 5px rgba(255, 255, 255, 1);
}

.share-icon button {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.2rem;
    font-weight: 100;
    cursor: pointer;
    transition: all 0.5s ease-in-out;

}

.share-icon:hover button,
.share-icon:focus button,
.share-icon:active button {
    color: rgba(255, 255, 255, 0.7);
}

.property-image-wrapper {
    position: relative;
    overflow: hidden;
    flex: 0 0 60%;
    height: 60%;
    min-height: 180px;
    max-height: 240px;
    border-radius: 8px 8px 0 0;
}

.property-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-bottom: 3px solid var(--gold-color-secondary);
    transition: all 0.5s ease-in-out;
}

.property-image:hover {
    transform: scale(1.1);
}

.property-price-badge {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.5);
    color: var(--dark-text-color);
    font-size: 1.08rem;
    font-weight: 700;
    padding: 10px 0 10px 0;
    box-shadow: 0 -2px 8px rgba(212, 175, 55, 0.10);
    letter-spacing: 1px;
    text-align: center;
    z-index: 2;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.property-card-body {
    padding: 24px 22px 28px 22px;
    text-align: left;
    flex: 1 1 40%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    background: transparent;
}

.property-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-color) !important;
    margin-bottom: 8px;
}

.property-location {
    color: var(--gold-color-secondary);
    font-size: 1rem;
    margin-bottom: 8px;
}

.property-meta {
    color: var(--text-color);
    font-size: 0.98rem;
    margin-bottom: 8px;
}

.property-features {
    display: flex;
    align-items: center;
    gap: 16px;
    color: var(--text-color);
    font-size: 1.02rem;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.property-features i {
    color: #999;
    margin-right: 4px;
    font-size: 1.1em;
}


body.dark-theme .property-features,
body.dark-theme .property-title,
body.dark-theme .property-meta {
    color: var(--dark-text-color) !important;
}

.property-actions {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.btn-action {
    flex: 1 1 0;
    border-radius: 8px;
    font-weight: 600;
    padding: 7px 0;
    font-size: 1rem;
    border: 1px solid var(--gold-color-secondary);
    color: var(--gold-color-secondary);
    text-decoration: none;
    background: transparent;
    transition: background 0.5s, color 0.5s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    cursor: pointer;
}

.btn-action:hover,
.btn-action:focus {
    background: var(--gold-color-secondary);
    color: rgb(240, 240, 240);

}

body.dark-theme .btn-action:hover,
body.dark-theme .btn-action:focus {
    background: var(--gold-color-secondary);
    color: var(--box-color);
    transform: scale(1.05);
}

@media (min-width:1890px) {
    .result-container {
        border-left: 2px solid var(--gold-color);
    }

    body.dark-theme .result-container {
        border-left: 2px solid var(--gold-color);
    }
}

/* --- card Responsive --- */
@media (min-width:990px) {
    .col-lg-2-5 {
        width: 20% !important;
    }

    .col-lg-9-5 {
        width: 80% !important;
    }
}

@media (max-width: 990px) {

    .property-image {
        height: 300px;
    }

    .property-card-body {
        padding: 20px;
    }

    .property-image-wrapper {
        min-height: 50%;
    }
}

@media (max-width: 767.99px) {

    .filters-column {
        position: relative;
        overflow-y: hidden;
        overflow-x: hidden;
        height:100%;
    }
    .result-container {
        border-left: none;
        border-top: 2px solid #ccc;
        padding-top: 3rem;
    }

    body.dark-theme .result-container {
        padding-top: 3rem;
        border-left: none;
        border-top: 2px solid var(--gold-color-light);
    }

    .cards-container {
        padding: 1rem 0.4rem;
    }

    .property-image {
        height: 300px;
    }

    .property-image-wrapper {
        min-height: 50%;
    }

    .property-title {
        font-size: 1rem;
    }

    .property-meta,
    .property-location,
    .property-features {
        font-size: 0.92rem;
    }

    .property-card-body {
        padding: 20px 15px 20px 15px;
    }
    
    .btn-reset {
        margin-bottom:0rem;
    }
}


/* Pagination styles */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 18px;
    flex-wrap: wrap;
}

.pagination .page-btn {
    min-width: 38px;
    height: 38px;
    border: none;
    border-radius: 50%;
    background: rgba(230, 230, 230, 1);
    color: #666;
    font-size: 16px;
    margin: 0 2px;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
    transition: background 0.2s, color 0.2s, transform 0.15s;
    outline: none;
    position: relative;
}

.pagination .page-btn:hover {
    background: var(--gold-color);
    color: #fff;
    transform: scale(1.08);
}

body.dark-theme .pagination .page-btn {
    background: transparent;
    color: #aaa;
}

body.dark-theme .pagination .page-btn:hover {
    background: var(--gold-color);
    color: #fff;
    transform: scale(1.08);
}

.pagination .page-btn[style*="background:#007bff"] {
    background: var(--gold-color) !important;
    color: #fff !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
    border: 2px solid var(--gold-color);
}

.pagination .page-btn:active {
    transform: scale(0.97);
}

@media (max-width: 600px) {
    .pagination .page-btn {
        min-width: 32px;
        height: 32px;
        font-size: 14px;
    }
}

.no-data-text {
    margin: 1rem 0;
    color: rgba(0, 0, 0, 0.6);
    font-size: 20px;
    font-weight: 500;
}

body.dark-theme .no-data-text {
    color: rgba(255, 255, 255, 0.8);
}