/**
 * منارات الفرص - صفحة العقارات المحدثة
 * Manarat Elforas - Properties Page Updated
 * استخدم مع main.css
 */

/* ============================================
   Properties Page - Premium Design
   ============================================ */

/* Page Hero */
.page-hero {
    min-height: 50vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding: 4rem 0;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(ellipse at 20% 80%, rgba(0, 107, 100, 0.5) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(174, 147, 87, 0.2) 0%, transparent 40%),
        linear-gradient(135deg, #004C48 0%, #003D3A 100%);
}

.hero-pattern {
    position: absolute;
    inset: 0;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23AE9357' fill-opacity='1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.page-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-block;
    background: rgba(174, 147, 87, 0.2);
    border: 2px solid var(--gold);
    padding: 0.5rem 1.5rem;
    border-radius: var(--radius-full);
    color: var(--gold-light);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    box-shadow: 0 0 20px rgba(174, 147, 87, 0.2);
}

.page-hero h1 {
    font-size: clamp(2rem, 5vw, 3rem);
    color: var(--off-white);
    margin-bottom: 1rem;
    font-weight: 900;
}

.page-hero h1 .highlight {
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.page-hero-subtitle {
    font-size: 1.2rem;
    color: var(--light-cream);
}

/* Filters Section */
.filters-section {
    background: linear-gradient(135deg, #006b648f 0%, rgb(174 147 87 / 24%) 50%, #004c41 100%);
    padding: 1rem 0 1rem;
    border-bottom: 2px solid rgb(174 147 87 / 21%);
    border-top: 2px solid rgb(174 147 87 / 21%);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.filters-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
}

.filter-tabs {
    display: flex;
    gap: 0.5rem;
    background: rgba(0, 42, 40, 0.6);
    padding: 0.4rem;
    border-radius: var(--radius-full);
    border: 1px solid rgba(174, 147, 87, 0.2);
}

.filter-tab {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    border-radius: var(--radius-full);
    color: var(--light-cream);
    font-family: var(--font-main);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-count {
    background: rgba(174, 147, 87, 0.25);
    padding: 0.2rem 0.7rem;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    min-width: 30px;
    text-align: center;
}

.filter-tab:hover {
    background: rgba(174, 147, 87, 0.15);
    color: var(--gold);
}

.filter-tab.active {
    background: #d4b978;
    color: var(--dark-teal);
    box-shadow: var(--shadow-gold);
}

.filter-tab.active .filter-count {
    background: rgba(0, 42, 40, 0.3);
    color: var(--dark-teal);
    font-weight: 700;
}

.filter-dropdowns {
    display: flex;
    gap: 1rem;
}

.filter-select {
    padding: 0.75rem 1.5rem;
    background: rgb(10 58 51 / 51%);
    border: 2px solid #e3e3e329;
    border-radius: var(--radius-md);
    color:#e5dcbf;
    font-family: var(--font-main);
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 180px;
}

.filter-select:hover,
.filter-select:focus {
    border-color: #d4b9785c;
    background: rgb(7 57 50);
    outline: none;
}

.filter-select option {
    background: #002A28;
    color: #E8E7E2;
    padding: 0.5rem;
}

.results-info {
    text-align: center;
    padding: 0.75rem 0;
}

.results-info p {
    color: var(--light-cream);
    font-size: 1rem;
    margin: 0;
}

.results-info span {
    color: var(--gold);
    font-weight: 700;
    font-size: 1.1rem;
}

/* Properties Section */
.properties-section {
    background: rgb(30 68 57 / 80%);
    padding: 4rem 0;
    min-height: 60vh;
}

/* PREMIUM GRID - 3 CARDS */
.properties-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 3rem;
}

/* PREMIUM PROPERTY CARD - IMPROVED DESIGN */
.property-card {
    background: linear-gradient(145deg, rgba(0, 76, 72, 0.6) 0%, rgba(0, 107, 100, 0.4) 100%);
    border: 2px solid rgba(174, 147, 87, 0.3);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: block;
    text-decoration: none;
    color: inherit;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(174, 147, 87, 0.1);
    backdrop-filter: blur(10px);
}

.property-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    background: radial-gradient(circle at top right, rgba(174, 147, 87, 0.1) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.property-card:hover {
    transform: translateY(-10px);
    border-color: #ae93577d;
    box-shadow: 
        0 20px 50px rgba(0, 0, 0, 0.4),
        0 0 60px rgba(174, 147, 87, 0.3),
        inset 0 1px 0 rgba(174, 147, 87, 0.2);
   box-shadow: 0 10px 30px #d4b97830, inset 0 1px 0 rgb(199 152 49 / 42%);
}

.property-card:hover::before {
    opacity: 1;
}

/* Image - INCREASED HEIGHT */
.property-image {
    position: relative;
    height: 320px;
    overflow: hidden;
}

.property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.property-card:hover .property-image img {
    transform: scale(1.08);
}

/* Enhanced overlay gradient */
.image-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 42, 40, 0%) 0%, rgb(0 42 40 / 12%) 40%, rgb(0 24 23 / 65%) 100%);
}

.property-card:hover .image-overlay {
    background: linear-gradient(
        180deg,
        rgba(0, 42, 40, 0.05) 0%,
        rgba(0, 42, 40, 0.4) 40%,
        rgba(0, 42, 40, 0.95) 100%
    );
}

/* Badges */
.badges-top {
    position: absolute;
    top: 15px;
    left: 15px;
    right: 15px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    z-index: 2;
}

.badge-purpose {
    padding: 0.6rem 1.3rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.badge-purpose.sale {
    background: #d1af6fe3;
    color: #012b2b;
    border-color: rgba(212, 185, 120, 0.5);
    padding: 0.5rem 1.7rem;
    border-radius: 20px;
    border: 0px solid rgba(255, 255, 255, 0.2);
}

.badge-purpose.rent {
    background: linear-gradient(167deg, #03e357cc 0%, #1aad9ccf 100%), #00db52ba 0%;
    color: #012b2b;
    border-color: rgba(212, 185, 120, 0.5);
    padding: 0.5rem 1.7rem;
    border-radius: 20px;
    border: 0px solid rgba(255, 255, 255, 0.2);
}

.property-card:hover .badge-purpose {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
}

.badge-featured {
    background: rgb(206 205 105);
    color: #012b2b;
    padding: 0.5rem 1.7rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    backdrop-filter: blur(12px);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Title and Location Overlay at Bottom of Image */
.property-title-overlay {
    position: absolute;
    bottom: 15px;
    left: 15px;
    right: 15px;
    z-index: 3;
}

.property-title-overlay .property-title {
    color: #fffcf3;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0;
    margin-top: 0.5rem;
    line-height: 1.4;
}

.property-card:hover .property-title-overlay .property-title {
    color: #ffffff;
}

.property-title-overlay .property-location {
    color: #E8E7E2;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.property-title-overlay .property-location svg {
    flex-shrink: 0;
    fill: rgb(212 165 116);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

/* Content */
.property-content {
    padding: 1.75rem 1.5rem;
    background: rgb(30 68 56);
}

/* Hide old title and location in content */
.property-content > .property-title {
    display: none;
}

.property-content > .property-location {
    display: none;
}

.property-content > .property-location-row {
    display: none;
}

/* Type badge */
.type-badge {
    background: rgba(0, 42, 40, 0.85);
    backdrop-filter: blur(10px);
    color: #D4B978;
    padding: 0.5rem 1.2rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 700;
    border: 2px solid rgba(174, 147, 87, 0.4);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    white-space: nowrap;
    display: inline-block;
    margin-bottom: 1rem;
}

/* Features */
.property-features {
    display: flex;
    gap: 1.5rem;
    padding: 1.25rem 0;
    border-top: 1px solid rgba(174, 147, 87, 0.2);
    border-bottom: 1px solid rgb(174 147 87 / 17%);
    margin-bottom: 1.25rem;
    background: #0037140f;
    border-radius: 10px;
    padding: 1rem 1.25rem;
    justify-content: center;
}

.feature {
    color: #E8E7E2;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.feature svg {
    flex-shrink: 0;
    color: rgb(212 165 116 / var(--tw-text-opacity, 1));
}

/* Footer - Details LEFT, Price RIGHT */
.property-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.25rem;
}

.property-price {
    text-align: right;
    flex: 1;
}

.property-price .price {
    background: #fffcf3;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 1.35rem;
    font-weight: 900;
    line-height: 1;
    letter-spacing: -0.5px;
    display: block;
}

.details-btn {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: linear-gradient(135deg, #015f42 0%, #0e4537 100%);
    color: #fffcf3;
    padding: 0.85rem 2.4rem;
    border-radius: 30px;
    font-weight: 700;
    font-size: 1.0rem;
    transition: all 0.3s ease;
    box-shadow: 0 5px 7px #003721;
    letter-spacing: 0.3px;
    border: 2px solid #005347;
    cursor: pointer;
    text-decoration: none;
    font-family: var(--font-main);
}

.details-btn svg {
    transition: transform 0.3s ease;
    width: 18px;
    height: 18px;
}

.property-card:hover .details-btn {
    transform: translateX(-3px);
}

.property-card:hover .details-btn svg {
    transform: translateX(5px);
}

/* No Results */
.no-results {
    text-align: center;
    padding: 4rem 2rem;
    background: linear-gradient(145deg, rgba(0, 107, 100, 0.3) 0%, rgba(0, 76, 72, 0.2) 100%);
    border: 2px solid rgba(174, 147, 87, 0.3);
    border-radius: var(--radius-lg);
}

.no-results h3 {
    color: var(--gold);
    margin-bottom: 0.5rem;
}

.no-results p {
    color: var(--light-cream);
}

.no-results a {
    color: var(--gold);
    text-decoration: underline;
}

.no-results a:hover {
    color: var(--gold-light);
}

/* Pagination */
.pagination-wrapper {
    display: flex;
    justify-content: center;
    margin-top: 3rem;
}

.pagination {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.page-btn {
    min-width: 45px;
    height: 45px;
    padding: 0.5rem 1rem;
    background: rgba(0, 107, 100, 0.3);
    border: 2px solid rgba(174, 147, 87, 0.3);
    border-radius: var(--radius-md);
    color: var(--off-white);
    font-family: var(--font-main);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.page-btn:hover {
    background: rgba(0, 107, 100, 0.5);
    border-color: var(--gold);
    transform: translateY(-2px);
}

.page-btn.active {
    background: var(--gold-gradient);
    color: var(--dark-teal);
    border-color: var(--gold-light);
    box-shadow: var(--shadow-gold);
}

.page-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.page-btn:disabled:hover {
    transform: none;
}

/* CTA Section */
.cta-section {
    background: var(--teal-gold-gradient);
    padding: 5rem 0;
    text-align: center;
    border-top: 3px solid #ae935747;
}

.cta-content {
    max-width: 600px;
    margin: 0 auto 2rem;
}

.cta-content h2 {
    color: var(--off-white);
    margin-bottom: 1rem;
}

.cta-content p {
    color: var(--light-cream);
    font-size: 1.1rem;
}

.contact-buttons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1.2rem 2.5rem;
    border-radius: var(--radius-full);
    font-size: 1.1rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.contact-btn svg {
    flex-shrink: 0;
}

.call-btn {
    background: linear-gradient(135deg, #006B64 0%, #004C48 100%);
    color: var(--gold);
    border: 2px solid var(--gold);
}

.call-btn:hover {
    background: var(--gold);
    color: var(--dark-teal);
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(174, 147, 87, 0.4);
}

.whatsapp-btn {
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    color: white;
    border: 2px solid #25D366;
}

.whatsapp-btn:hover {
    background: #128C7E;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(37, 211, 102, 0.5);
}

/* Responsive */
@media (max-width: 1200px) {
    .properties-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.75rem;
    }
}

@media (max-width: 1024px) {
    .page-hero {
        padding: 3rem 0;
    }
    
    .filters-wrapper {
        flex-direction: column;
        gap: 1rem;
    }
    
    .filter-tabs {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .page-hero {
        padding: 2rem 0;
        min-height: 40vh;
    }
    
    .hero-badge {
        font-size: 0.8rem;
        padding: 0.4rem 1.2rem;
    }
    
    .page-hero-subtitle {
        font-size: 1rem;
    }
    
    .properties-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .filter-tab {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }
    
    .filter-count {
        font-size: 0.75rem;
        padding: 0.15rem 0.5rem;
        min-width: 24px;
    }
    
    .filter-dropdowns {
        width: 100%;
        flex-direction: column;
    }
    
    .filter-select {
        width: 100%;
    }
    
    .property-image {
        height: 260px;
    }
    
    .property-title-overlay {
        bottom: 10px;
        left: 10px;
        right: 10px;
    }
    
    .property-title-overlay .property-title {
        font-size: 1.1rem;
        margin-bottom: 0.4rem;
    }
    
    .property-title-overlay .property-location {
        font-size: 0.85rem;
    }
    
    .property-content {
        padding: 1.0rem 0.9rem;
    }
    
    .property-features {
        gap: 0.5rem;
        padding: 0.7rem 0.1rem;
        flex-wrap: wrap;
        margin-bottom: 1.1rem;
    }
    
    .feature {
        font-size: 0.85rem;
    }
    
    .property-footer {
        flex-direction: column;
        gap: 1.3rem;
    }
    
    .property-price,
    .details-btn {
        width: 100%;
        text-align: center;
    }
    
    .details-btn {
        justify-content: center;
        padding: 0.75rem 1.5rem;
        font-size: 0.9rem;
    }
    
    .property-price .price {
        font-size: 1.4rem;
        text-align: center;
    }
    
    .contact-btn {
        width: 100%;
        justify-content: center;
        padding: 1rem 2rem;
    }
    
    .contact-buttons {
        flex-direction: column;
    }
    
    .cta-section {
        padding: 3.5rem 0;
    }
}