/*
 * Dream Albania - Unified Design System
 * Modern, elegant, and fully responsive property cards and layouts
 */

/* ========================================================================
   DESIGN TOKENS & VARIABLES
   ======================================================================== */
:root {
    --da-primary: #274abb;
    --da-primary-dark: #1e3a8a;
    --da-primary-light: #3b5ec9;
    --da-secondary: #ef4444;
    --da-success: #10b981;
    --da-text-primary: #1f2937;
    --da-text-secondary: #6b7280;
    --da-text-light: #9ca3af;
    --da-bg-light: #f9fafb;
    --da-bg-white: #ffffff;
    --da-border: #e5e7eb;
    --da-border-light: #f3f4f6;
    --da-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --da-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --da-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --da-shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --da-radius-sm: 8px;
    --da-radius-md: 12px;
    --da-radius-lg: 16px;
    --da-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ========================================================================
   ENHANCED PROPERTY CARDS - WORKING WITH EXISTING STRUCTURE
   ======================================================================== */

/* Card Container Enhancements */
.da-property-card-wrapper.listing-item {
    background: white;
    border-radius: var(--da-radius-md);
    overflow: hidden;
    transition: var(--da-transition);
    box-shadow: var(--da-shadow-md);
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--da-border-light);
}

.da-property-card-wrapper.listing-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--da-shadow-xl);
}

/* Image Container */
.da-property-card-wrapper .listing-img-container {
    position: relative;
    display: block;
    overflow: hidden;
    height: 250px;
}

.da-property-card-wrapper .listing-img-container .item {
    height: 100%;
    width: 100%;
}

.da-property-card-wrapper .listing-img-container .item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.da-property-card-wrapper:hover .listing-img-container .item img {
    transform: scale(1.08);
}

/* No Image Placeholder */
.da-no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: linear-gradient(135deg, var(--da-bg-light) 0%, #e5e7eb 100%);
    color: var(--da-text-light);
    font-size: 48px;
}

/* Badges Enhancement */
.da-property-card-wrapper .listing-badges {
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.da-property-card-wrapper .listing-badges span {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.025em;
    text-transform: uppercase;
    backdrop-filter: blur(10px);
    box-shadow: var(--da-shadow-md);
}

.da-property-card-wrapper .listing-badges .badge-sale {
    background: rgba(16, 185, 129, 0.95);
    color: white;
}

.da-property-card-wrapper .listing-badges .badge-rent {
    background: rgba(59, 130, 246, 0.95);
    color: white;
}

.da-property-card-wrapper .listing-badges .da-badge-exclusive {
    background: rgba(239, 68, 68, 0.95);
    color: white;
}

/* Old Price Enhancement */
.da-property-card-wrapper .property-price.old-price {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 10;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    text-decoration: line-through;
    backdrop-filter: blur(10px);
}

/* Current Price Enhancement */
.da-property-card-wrapper .listing-img-content {
    position: absolute;
    bottom: 16px;
    left: 16px;
    right: 16px;
    z-index: 10;
}

.da-property-card-wrapper .listing-price {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    padding: 12px 16px;
    border-radius: var(--da-radius-sm);
    box-shadow: var(--da-shadow-lg);
    display: block;
    font-size: 20px;
    font-weight: 700;
    color: var(--da-primary);
    line-height: 1.4;
}

.da-property-card-wrapper .listing-price small {
    display: block;
    font-size: 12px;
    color: var(--da-text-secondary);
    margin-top: 4px;
    font-weight: 500;
}

/* Content Area */
.da-property-card-wrapper .listing-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 16px;
}

.da-property-card-wrapper .listing-title {
    margin-bottom: 0;
}

.da-property-card-wrapper .listing-title h4 {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.4;
}

.da-property-card-wrapper .listing-title h4 a {
    color: var(--da-text-primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

.da-property-card-wrapper .listing-title h4 a:hover {
    color: var(--da-primary);
}

.da-property-card-wrapper .listing-address {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--da-text-secondary);
    font-size: 14px;
    text-decoration: none;
}

.da-property-card-wrapper .listing-address i {
    opacity: 0.7;
}

/* Features List - FIX ICON SIZING */
.da-property-card-wrapper .listing-features {
    list-style: none;
    padding: 16px 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    border-top: 1px solid var(--da-border-light);
    border-bottom: 1px solid var(--da-border-light);
}

.da-property-card-wrapper .listing-features li {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--da-text-secondary);
    font-size: 14px;
    font-weight: 500;
    margin: 0;
    padding: 0;
}

/* CRITICAL: Fix SVG Icon Sizing */
.da-property-card-wrapper .listing-features li svg,
.da-property-card-wrapper .listing-features li .rh_svg {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    min-height: 18px !important;
    max-width: 18px !important;
    max-height: 18px !important;
    flex-shrink: 0;
    opacity: 0.7;
    display: inline-block;
    vertical-align: middle;
}

/* Ensure SVG paths render correctly */
.da-property-card-wrapper .listing-features li svg path,
.da-property-card-wrapper .listing-features li .rh_svg path,
.da-property-card-wrapper .listing-features li svg circle,
.da-property-card-wrapper .listing-features li .rh_svg circle,
.da-property-card-wrapper .listing-features li svg rect,
.da-property-card-wrapper .listing-features li .rh_svg rect {
    vector-effect: non-scaling-stroke;
}

/* Reset any conflicting SVG container styles */
.da-property-card-wrapper .listing-features li svg g,
.da-property-card-wrapper .listing-features li .rh_svg g {
    transform: none !important;
}

.da-property-card-wrapper .listing-features li span {
    font-size: 14px;
    font-weight: 500;
    margin: 0;
}

/* Footer */
.da-property-card-wrapper .listing-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 4px;
    font-size: 13px;
}

.da-property-card-wrapper .listing-footer i {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--da-text-secondary);
}

.da-property-card-wrapper .listing-footer i .fa-user {
    opacity: 0.6;
}

.da-property-card-wrapper .listing-footer > span {
    font-weight: 600;
    color: var(--da-text-light);
    letter-spacing: 0.05em;
}

/* ========================================================================
   PROPERTY GRID LAYOUTS - OVERRIDE EXISTING GRID
   ======================================================================== */
.da-properties-grid.grid-layout-three {
    display: grid !important;
    gap: 24px;
    margin: 0;
    padding: 0;
    left: 0 !important;
    width: 100% !important;
    position: static !important;
}

.da-properties-grid.grid-layout-three .listing-item {
    display: flex !important;
    width: 100% !important;
    float: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    position: relative;
}

/* 3 Column Grid */
@media (min-width: 1024px) {
    .da-properties-grid.grid-layout-three {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* 2 Column Grid */
@media (min-width: 768px) and (max-width: 1023px) {
    .da-properties-grid.grid-layout-three {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 1 Column Grid (Mobile) */
@media (max-width: 767px) {
    .da-properties-grid.grid-layout-three {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* ========================================================================
   SECTION CONTAINERS
   ======================================================================== */
.da-section {
    padding: 80px 0;
}

.da-section-header {
    text-align: center;
    margin-bottom: 48px;
}

.da-section-title {
    font-size: 36px;
    font-weight: 700;
    color: var(--da-text-primary);
    margin: 0 0 12px 0;
    letter-spacing: -0.025em;
}

.da-section-subtitle {
    font-size: 18px;
    color: var(--da-text-secondary);
    margin: 0;
    max-width: 600px;
    margin: 0 auto;
}

/* ========================================================================
   HOMEPAGE SECTIONS
   ======================================================================== */
.da-hero-section {
    position: relative;
    padding: 120px 0 80px;
    background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%);
}

/* ========================================================================
   SWIPER CAROUSEL CUSTOMIZATION
   ======================================================================== */
.da-carousel-container {
    position: relative;
    padding: 0 50px;
}

.da-carousel-container .swiper-button-next,
.da-carousel-container .swiper-button-prev {
    width: 44px;
    height: 44px;
    background: white;
    border-radius: 50%;
    box-shadow: var(--da-shadow-lg);
    transition: var(--da-transition);
}

.da-carousel-container .swiper-button-next:after,
.da-carousel-container .swiper-button-prev:after {
    font-size: 18px;
    font-weight: 700;
    color: var(--da-primary);
}

.da-carousel-container .swiper-button-next:hover,
.da-carousel-container .swiper-button-prev:hover {
    background: var(--da-primary);
    transform: scale(1.1);
}

.da-carousel-container .swiper-button-next:hover:after,
.da-carousel-container .swiper-button-prev:hover:after {
    color: white;
}

.da-carousel-container .swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    background: var(--da-text-light);
    opacity: 0.5;
    transition: var(--da-transition);
}

.da-carousel-container .swiper-pagination-bullet-active {
    background: var(--da-primary);
    opacity: 1;
    transform: scale(1.2);
}

/* ========================================================================
   NO RESULTS STATE
   ======================================================================== */
.da-no-results {
    text-align: center;
    padding: 80px 20px;
}

.da-no-results-icon {
    width: 120px;
    height: 120px;
    margin: 0 auto 24px;
    opacity: 0.3;
}

.da-no-results-title {
    font-size: 24px;
    font-weight: 600;
    color: var(--da-text-primary);
    margin: 0 0 12px 0;
}

.da-no-results-text {
    font-size: 16px;
    color: var(--da-text-secondary);
    max-width: 500px;
    margin: 0 auto;
}

/* ========================================================================
   PROPERTIES TOOLBAR
   ======================================================================== */
.da-properties-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    margin-bottom: 32px;
    border-bottom: 1px solid var(--da-border-light);
    flex-wrap: wrap;
    gap: 16px;
}

.da-toolbar-left,
.da-toolbar-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.da-results-count {
    font-size: 16px;
    color: var(--da-text-secondary);
}

.da-results-count strong {
    color: var(--da-primary);
    font-size: 20px;
    font-weight: 700;
}

.da-sort-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.da-sort-wrapper label {
    font-size: 14px;
    font-weight: 500;
    color: var(--da-text-secondary);
    margin: 0;
}

.da-sort-select {
    min-width: 200px;
    padding: 10px 16px;
    border: 1px solid var(--da-border);
    border-radius: var(--da-radius-sm);
    background: white;
    font-size: 14px;
    font-weight: 500;
    color: var(--da-text-primary);
    cursor: pointer;
    transition: var(--da-transition);
}

.da-sort-select:hover,
.da-sort-select:focus {
    border-color: var(--da-primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(39, 74, 187, 0.1);
}

.da-layout-switcher {
    display: flex;
    gap: 8px;
    background: var(--da-bg-light);
    padding: 4px;
    border-radius: var(--da-radius-sm);
}

.da-layout-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    color: var(--da-text-secondary);
    cursor: pointer;
    border-radius: 6px;
    transition: var(--da-transition);
}

.da-layout-btn:hover {
    background: white;
    color: var(--da-primary);
}

.da-layout-btn.active {
    background: white;
    color: var(--da-primary);
    box-shadow: var(--da-shadow-sm);
}

/* ========================================================================
   PAGINATION
   ======================================================================== */
.da-pagination-wrapper {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--da-border-light);
}

.da-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 16px;
}

.da-pagination-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: white;
    border: 1px solid var(--da-border);
    border-radius: var(--da-radius-sm);
    color: var(--da-text-primary);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: var(--da-transition);
    cursor: pointer;
}

.da-pagination-btn:hover:not(.disabled) {
    background: var(--da-primary);
    border-color: var(--da-primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--da-shadow-md);
}

.da-pagination-btn.disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

.da-pagination-numbers {
    display: flex;
    align-items: center;
    gap: 4px;
}

.da-pagination-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    background: white;
    border: 1px solid var(--da-border);
    border-radius: var(--da-radius-sm);
    color: var(--da-text-primary);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: var(--da-transition);
}

.da-pagination-number:hover {
    background: var(--da-bg-light);
    border-color: var(--da-primary);
    color: var(--da-primary);
}

.da-pagination-number.active {
    background: var(--da-primary);
    border-color: var(--da-primary);
    color: white;
    box-shadow: var(--da-shadow-md);
}

.da-pagination-ellipsis {
    display: inline-flex;
    align-items: center;
    padding: 0 8px;
    color: var(--da-text-light);
    font-size: 14px;
}

.da-pagination-info {
    text-align: center;
    font-size: 14px;
    color: var(--da-text-secondary);
}

.da-pagination-info strong {
    color: var(--da-primary);
    font-weight: 600;
}

/* ========================================================================
   LIST VIEW LAYOUT
   ======================================================================== */
.da-properties-grid.da-list-view {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.da-properties-grid.da-list-view .da-property-card-wrapper {
    display: grid;
    grid-template-columns: 350px 1fr;
    height: auto;
}

.da-properties-grid.da-list-view .listing-img-container {
    height: 280px;
}

.da-properties-grid.da-list-view .listing-content {
    padding: 24px 28px;
}

.da-properties-grid.da-list-view .listing-features {
    border-top: none;
    padding-top: 0;
}

.da-properties-grid.da-list-view .listing-title h4 {
    font-size: 20px;
}

/* ========================================================================
   RESPONSIVE ADJUSTMENTS
   ======================================================================== */
@media (max-width: 1023px) {
    .da-section {
        padding: 60px 0;
    }
    
    .da-section-title {
        font-size: 32px;
    }
    
    .da-properties-grid.da-list-view {
        display: grid;
        grid-template-columns: 1fr;
    }
    
    .da-properties-grid.da-list-view .da-property-card-wrapper {
        display: flex;
        flex-direction: column;
    }
    
    .da-properties-grid.da-list-view .listing-img-container {
        height: 250px;
    }
}

@media (max-width: 767px) {
    .da-section {
        padding: 48px 0;
    }
    
    .da-section-title {
        font-size: 28px;
    }
    
    .da-carousel-container {
        padding: 0 20px;
    }
    
    .da-properties-toolbar {
        flex-direction: column;
        align-items: stretch;
    }
    
    .da-toolbar-left,
    .da-toolbar-right {
        justify-content: space-between;
        width: 100%;
    }
    
    .da-sort-wrapper {
        flex: 1;
    }
    
    .da-sort-select {
        width: 100%;
    }
    
    .da-pagination-btn span {
        display: none;
    }
    
    .da-pagination-number {
        min-width: 36px;
        height: 36px;
        font-size: 13px;
    }
}

/* ========================================================================
   UTILITIES
   ======================================================================== */
.da-mt-1 { margin-top: 8px; }
.da-mt-2 { margin-top: 16px; }
.da-mt-3 { margin-top: 24px; }
.da-mt-4 { margin-top: 32px; }
.da-mt-5 { margin-top: 48px; }

.da-mb-1 { margin-bottom: 8px; }
.da-mb-2 { margin-bottom: 16px; }
.da-mb-3 { margin-bottom: 24px; }
.da-mb-4 { margin-bottom: 32px; }
.da-mb-5 { margin-bottom: 48px; }

.da-text-center { text-align: center; }
.da-text-left { text-align: left; }
.da-text-right { text-align: right; }
