﻿/* ========================================
   Listing Page Styles - Mont / Black & White
   Horizontal card layout (1 per row)
   ======================================== */

/* --- Base --- */
.listing-page {
    font-family: 'Mont', sans-serif;
    color: #000;
    background: #fff;
    min-height: 100vh;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
}

/* --- Not Found --- */
.listing-notfound {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 24px;
    text-align: center;
    min-height: 60vh;
}
.listing-notfound i {
    font-size: 64px;
    color: #D1D5DB;
    margin-bottom: 24px;
}
.listing-notfound h1 {
    font-size: 22px;
    font-weight: 600;
    margin: 0 0 8px;
}
.listing-notfound p {
    font-size: 15px;
    color: #6B7280;
    margin: 0 0 24px;
}
.listing-notfound a {
    color: #000;
    font-weight: 600;
    text-decoration: underline;
    font-size: 14px;
}

/* --- Header / Broker --- */
.listing-header {
    display: flex;
    align-items: center;
    gap: 24px;
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 24px 32px;
}
.listing-broker-photo {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: #F3F4F6 center / cover no-repeat;
    flex-shrink: 0;
    border: 2px solid #E5E7EB;
}
.listing-broker-info h1 {
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 4px;
}
.listing-broker-info .broker-phone {
    font-size: 14px;
    color: #6B7280;
    margin: 0 0 8px;
}
.listing-broker-info .listing-text {
    font-size: 14px;
    color: #374151;
    line-height: 1.6;
    margin: 0;
}

/* --- Object count --- */
.listing-count {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px 16px;
    font-size: 13px;
    color: #9CA3AF;
    font-weight: 500;
}

/* --- List (vertical stack) --- */
.listing-list {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px 60px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* --- Horizontal Property Card --- */
.listing-card {
    display: flex;
    align-items: stretch;
    background: #fff;
    border: 1px solid #E5E7EB;
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow .2s;
}
.listing-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,.07);
}

/* Card Image (left) */
.listing-card-img {
    position: relative;
    width: 240px;
    min-height: 180px;
    flex-shrink: 0;
    background: #F3F4F6 center / cover no-repeat;
    cursor: pointer;
}
.listing-card-img .no-photo {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: #D1D5DB;
    font-size: 40px;
}
.listing-card-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #000;
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: .3px;
}

/* Card Body (center) */
.listing-card-body {
    flex: 1;
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}
.listing-card-title {
    font-size: 15px;
    font-weight: 600;
    margin: 0 0 6px;
    line-height: 1.4;
}
.listing-card-title a {
    color: #000;
    text-decoration: none;
}
.listing-card-title a:hover {
    text-decoration: underline;
}
.listing-card-address {
    font-size: 13px;
    color: #6B7280;
    margin: 0 0 10px;
    display: flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.listing-card-address i {
    font-size: 14px;
    flex-shrink: 0;
}
.listing-card-features {
    display: flex;
    gap: 16px;
    margin-bottom: 10px;
    font-size: 13px;
    color: #374151;
}
.listing-card-features .feature {
    display: flex;
    align-items: center;
    gap: 4px;
}
.listing-card-features .feature i {
    font-size: 15px;
    color: #9CA3AF;
}
.listing-card-price {
    font-size: 18px;
    font-weight: 700;
    color: #000;
    margin: 0;
}
.listing-card-desc {
    font-size: 13px;
    color: #6B7280;
    line-height: 1.5;
    margin-top: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Card Actions (right) */
.listing-card-actions {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
    padding: 16px;
    border-left: 1px solid #F3F4F6;
    flex-shrink: 0;
    min-width: 150px;
}
.listing-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 14px;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    background: #fff;
    font-family: 'Mont', sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    transition: all .15s;
    white-space: nowrap;
}
.listing-btn:hover {
    background: #F9FAFB;
    border-color: #000;
    color: #000;
}
.listing-btn i {
    font-size: 15px;
}
.listing-btn-primary {
    background: #000;
    color: #fff;
    border-color: #000;
}
.listing-btn-primary:hover {
    background: #333;
    border-color: #333;
    color: #fff;
}
.listing-btn-liked {
    color: #000;
    border-color: #000;
}
.listing-btn-liked i {
    font-weight: 700;
}
.listing-btn-remove {
    color: #EF4444;
    border-color: #FCA5A5;
}
.listing-btn-remove:hover {
    background: #FEF2F2;
    border-color: #EF4444;
    color: #EF4444;
}

/* --- Liked card (status_id 2) --- */
.listing-card-liked {
    border-color: #EF4444;
    border-width: 2px;
}

/* --- Rejected section --- */
.listing-rejected-section {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}
.listing-rejected-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: #9CA3AF;
    padding: 24px 0 16px;
    border-top: 1px solid #E5E7EB;
    margin-top: 16px;
}
.listing-rejected-header i {
    font-size: 18px;
}
.listing-list-rejected {
    padding-bottom: 20px;
}

/* --- Rejected card (status_id 3) --- */
.listing-card-rejected {
    opacity: 0.55;
    border-color: #E5E7EB;
    background: #F9FAFB;
}
.listing-card-rejected .listing-card-img {
    filter: grayscale(100%);
}
.listing-card-rejected .listing-card-title a {
    color: #9CA3AF;
}
.listing-card-rejected .listing-card-price {
    color: #9CA3AF;
}
.listing-card-rejected .listing-card-badge {
    background: #9CA3AF;
}
.listing-card-rejected:hover {
    opacity: 0.75;
}

/* --- Empty state --- */
.listing-empty {
    text-align: center;
    padding: 80px 24px;
    color: #9CA3AF;
}
.listing-empty i {
    font-size: 48px;
    margin-bottom: 16px;
    display: block;
}
.listing-empty p {
    font-size: 15px;
    margin: 0;
}

/* --- Loading --- */
.listing-loading {
    text-align: center;
    padding: 80px 24px;
    color: #9CA3AF;
    font-size: 14px;
}
.listing-loading .spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #E5E7EB;
    border-top-color: #000;
    border-radius: 50%;
    animation: listing-spin .8s linear infinite;
    margin: 0 auto 16px;
}
@keyframes listing-spin {
    to { transform: rotate(360deg); }
}

/* --- Footer --- */
.listing-footer {
    max-width: 1100px;
    margin: 0 auto;
    padding: 24px;
    text-align: center;
    font-size: 12px;
    color: #D1D5DB;
    border-top: 1px solid #F3F4F6;
}

/* --- Responsive --- */
@media (max-width: 700px) {
    .listing-header {
        flex-direction: column;
        text-align: center;
        padding: 32px 16px 24px;
    }
    .listing-list {
        padding: 0 12px 40px;
    }
    .listing-card {
        flex-direction: column;
    }
    .listing-card-img {
        width: 100%;
        height: 180px;
        min-height: auto;
    }
    .listing-card-actions {
        flex-direction: row;
        border-left: none;
        border-top: 1px solid #F3F4F6;
        min-width: auto;
        padding: 12px;
    }
    .listing-btn {
        flex: 1;
    }
}