.z-modal-dialog {
    max-width: 1300px;
    margin: 1.5rem auto;
}

.z-modal-content {
    background: #fff;
    border: none;
    border-radius: 12px;
    overflow: hidden;
    font-family: 'Open Sans', sans-serif;
    color: #2a2a33;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
}

.z-scrollable-body {
    overflow-y: auto;
    height: calc(85vh - 50px);
    flex-grow: 1;
}

.z-section-anchor {
    scroll-margin-top: 60px;
}

.z-global-header {
    height: 70px;
    top: 0;
    z-index: 1060;
    background: #fff;
    padding: 12px 24px;
    border-bottom: 1px solid #e5e5e5;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.z-brand {
    color: rgba(34, 93, 119, 1);
    font-family: Careem;
    font-weight: 700;
    font-style: Bold;
    font-size: 40px;
    line-height: 100%;
    letter-spacing: 0%;
}

.z-sticky-nav-container {
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 1050;
    border-bottom: 1px solid #d1d1d5;
    padding: 0 40px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    flex-shrink: 0;
}

.z-nav-list {
    display: flex;
    gap: 32px;
    list-style: none;
    margin: 0;
    padding: 0;
    overflow-x: auto;
}

.z-nav-item {
    padding: 16px 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #596b82;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    white-space: nowrap;
    transition: color 0.2s;
}

.z-nav-item.active,
.z-nav-item:hover {
    color: rgba(34, 93, 119, 1);
    border-bottom-color: rgba(34, 93, 119, 1);
}

.z-hero {
    height: 450px;
    background: transparent;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 0;
    width: 100%;
}

.z-hero-grid-wrapper {
    width: 100%;
    max-width: 1200px;
    height: 100%;
    padding: 0 40px;
}

.z-hero-card {
    background: transparent;
    box-shadow: none;
    padding: 0;
    border-radius: 0;
    height: 100%;
}

.z-hero-grid {
    display: grid;
    grid-template-columns: 3fr 1.5fr;
    gap: 12px;
    height: 100%;
    border-radius: 12px;
    overflow: hidden;
}

/* New/Updated rule for when only main image is present */
.z-hero-grid.single-image {
    grid-template-columns: 1fr;
}

.z-hero-main,
.z-hero-main-full {
    position: relative;
    height: 100%;
    background: #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    overflow: hidden;
}

.z-hero-main-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    cursor: zoom-in;
}

.z-hero-main-video,
.z-hero-thumb-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    background: #000;
}

.z-hero-thumb-video {
    pointer-events: none;
}

.z-hero-thumb-video-badge {
    position: absolute;
    inset-inline-start: 10px;
    inset-block-end: 10px;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: rgba(15, 23, 42, 0.72);
    font-size: 0.95rem;
    z-index: 2;
}

.z-hero-grid.single-image .z-hero-main-full {
    width: 100%;
    height: 100%;
    min-height: 320px;
}

.z-tag-sale {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: rgba(227, 31, 38, 0.95);
    color: #ffffff;
    padding: 6px 14px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 2;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.z-hero-thumbs-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 1fr;
    gap: 12px;
    height: 100%;
}

.z-hero-thumb-item {
    position: relative;
    overflow: hidden;
    background: #e5e7eb;
    border-radius: 12px;
    cursor: pointer;
}

.z-hero-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.2s ease-out;
}

.z-hero-thumb-item:hover .z-hero-thumb-img {
    transform: scale(1.03);
}

.z-hero-thumb-item:hover .z-hero-thumb-video {
    transform: scale(1.03);
}

.z-hero-thumb-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
    border-radius: 12px;
}

.z-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    padding: 32px 40px;
}

.z-price {
    font-size: 2.2rem;
    font-weight: 800;
    color: #1a1a1a;
    letter-spacing: -1px;
    line-height: 1;
}

.z-address {
    font-size: 1.1rem;
    color: #596b82;
    margin-top: 8px;
    margin-bottom: 24px;
}

.z-section-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: #1a1a1a;
}

.z-attributes-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 24px;
}

.z-attributes-section {
    border: 1px solid #FFFFFF;
    background: #FFFFFF;
    border-radius: 12px;
    padding: 16px;
}

.z-attributes-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #2b3a4a;
    margin-bottom: 12px;
}

.z-attribute-chip {
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: #FFFFFF;
    border: 1px solid #FFFFFF;
    padding: 10px 14px;
    border-radius: 8px;
    min-width: 160px;
}

.z-attribute-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: #6c7b8e;
}

.z-attribute-value {
    font-size: 0.95rem;
    color: #1f2a37;
    line-height: 1.3;
}

.z-feature-table {
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 16px;
}

.z-feature-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.z-feature-row:nth-child(odd) {
    background: #f3f3f5;
}

.z-feature-cell {
    min-height: 78px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    text-align: start;
}

.z-feature-cell-empty {
    visibility: hidden;
}

.z-feature-text {
    font-size: 1.15rem;
    font-weight: 500;
    color: #1f2937;
    line-height: 1.25;
    white-space: normal;
}

.z-feature-icon-img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    display: block;
}

.z-feature-icon-slot {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.z-feature-icon-fallback {
    font-size: 1.6rem;
    color: #1f2937;
    line-height: 1;
}

.z-desc-box {
    position: relative;
    line-height: 1.7;
    color: #2a2a33;
}

.z-desc-collapsed {
    max-height: 120px;
    overflow: hidden;
    mask-image: linear-gradient(black 50%, transparent 100%);
    -webkit-mask-image: linear-gradient(black 50%, transparent 100%);
}

.z-link-btn {
    background: none;
    border: none;
    color: rgba(34, 93, 119, 1);
    font-weight: 700;
    padding: 0;
    margin-top: 8px;
    cursor: pointer;
}

.z-map-box {
    height: 320px;
    background: #eee;
    border-radius: 8px;
    overflow: hidden;
    margin-top: 10px;
}

.z-sidebar-sticky {
    position: sticky;
    top: 80px;
}

.z-contact-box {
    padding: 24px;
    border: 1px solid #d1d1d5;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.z-btn-primary,
.z-btn-outline,
.z-btn-whatsapp {
    display: block;
    width: 100%;
    text-align: center;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 700;
    border-radius: 4px;
    padding: 12px;
}

.z-btn-primary {
    background: rgba(34, 93, 119, 1);
    color: #fff;
    border: none;
    margin-bottom: 12px;
}

.z-btn-primary:hover {
    background: rgba(34, 93, 119, 1);
    filter: brightness(1.1);
}

.z-btn-outline {
    background: #fff;
    color: rgba(34, 93, 119, 1);
    border: 1px solid rgba(34, 93, 119, 1);
}

.z-btn-outline:hover {
    background: #f5faff;
}

.z-btn-whatsapp {
    background: #25D369;
    color: #fff;
    border: none;
    margin-top: 8px;
}

.z-btn-whatsapp:hover {
    filter: brightness(1.05);
}

.z-btn-whatsapp i {
    margin-right: 0.5rem;
}

#zContactPane {
    padding: 32px 40px;
    background: #FFFFFF;
    min-height: 420px;
}

.z-contact-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    gap: 40px;
    align-items: stretch;
}

.z-contact-left {
    max-width: 520px;
}

.z-contact-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: #1a1a1a;
}

.z-contact-subtitle {
    font-size: 0.95rem;
    color: #6b7280;
    margin-bottom: 24px;
}

#zContactForm .form-label {
    font-weight: 600;
    font-size: 0.9rem;
    color: #374151;
}

#zContactForm .form-control {
    border-radius: 8px;
    border-color: #d1d5db;
    padding: 10px 12px;
}

#zContactForm .form-control::placeholder {
    color: #9ca3af;
    font-size: 0.9rem;
}

#zContactForm .btn-primary {
    padding-inline: 22px;
}

.z-contact-right {
    position: relative;
    min-height: 420px;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    overflow: visible;
}

.z-contact-right .project-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background-color: transparent;
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.z-contact-right:hover .project-img {
    transform: scale(1.02);
}

.z-contact-actions .btn-primary {
    background: rgba(34, 93, 119, 1);
    border-color: rgba(34, 93, 119, 1);
    font-weight: 600;
    padding-inline: 24px;
    border-radius: 999px;
}

.z-contact-actions .btn-primary:hover {
    background: rgba(34, 93, 119, 1);
    border-color: rgba(34, 93, 119, 1);
    filter: brightness(1.06);
}

.z-contact-actions .btn-light {
    background: #f3f4f6;
    border-color: #e5e7eb;
    color: #374151;
    font-weight: 500;
    padding-inline: 20px;
    border-radius: 999px;
}

.z-contact-actions .btn-light:hover {
    background: #e5e7eb;
    border-color: #d1d5db;
}

.z-gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.z-gallery-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.75);
}

.z-gallery-dialog {
    position: relative;
    width: 100%;
    max-width: 1100px;
    height: 80vh;
    background: #0f172a;
    border-radius: 12px;
    overflow: hidden;
    padding: 32px 48px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.z-gallery-close {
    position: absolute;
    top: 12px;
    right: 16px;
    border: none;
    background: rgba(15, 23, 42, 0.7);
    color: #e5e7eb;
    width: 32px;
    height: 32px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
}

.z-gallery-close:hover {
    background: rgba(30, 64, 175, 0.9);
}

.z-gallery-swiper {
    width: 100%;
    height: 100%;
}

.z-gallery-slide-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #020617;
}

.z-gallery-lightbox .swiper-button-next,
.z-gallery-lightbox .swiper-button-prev {
    color: #f9fafb;
}

.z-gallery-lightbox .swiper-pagination-bullet {
    background: #9ca3af;
}

.z-gallery-lightbox .swiper-pagination-bullet-active {
    background: #f9fafb;
}

html[dir="rtl"] .z-btn-whatsapp i {
    margin-right: 0;
    margin-left: 0.5rem;
}

@media (max-width: 992px) {
    .z-modal-dialog {
        margin: 0;
        max-width: 100%;
        width: 100%;
    }

    .z-global-header {
        padding: 10px 16px;
        height: auto;
    }

    .z-brand {
        font-size: 26px;
    }

    .z-sticky-nav-container {
        padding: 0 16px;
    }

    .z-hero {
        height: 360px;
        padding: 15px 0;
    }

    .z-hero-grid-wrapper {
        padding: 0 20px;
    }

    .z-hero-card {
        padding: 0;
    }

    .z-hero-grid.single-image .z-hero-main-full {
        min-height: 260px;
    }

    .z-grid {
        grid-template-columns: 1fr;
        padding: 24px 16px 32px;
        gap: 24px;
    }

    .z-sidebar-sticky {
        position: static;
        margin-top: 8px;
    }

    .z-feature-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .z-feature-cell-empty {
        display: none;
    }

    .z-feature-cell {
        min-height: 56px;
        padding: 8px 10px;
        gap: 8px;
    }

    .z-feature-text {
        font-size: 0.92rem;
        line-height: 1.25;
    }

    .z-feature-icon-img {
        width: 26px;
        height: 26px;
    }

    .z-feature-icon-slot {
        width: 26px;
        height: 26px;
    }

    .z-feature-icon-fallback {
        font-size: 1.1rem;
    }
}

@media (max-width: 768px) {
    .z-gallery-dialog {
        padding: 24px 16px;
        height: 75vh;
        border-radius: 0;
    }
}

@media (max-width: 576px) {
    .z-hero {
        height: 260px;
        padding: 10px 0;
    }

    .z-hero-card {
        padding: 0;
    }

    .z-hero-grid {
        grid-template-columns: 1fr;
    }

    .z-hero-grid.single-image .z-hero-main-full {
        min-height: 220px;
    }

    .z-hero-thumbs-grid {
        display: none;
    }

    #zContactPane {
        padding: 24px 16px;
    }

    .z-contact-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 24px;
    }

    .z-contact-right {
        display: none;
    }

    .z-feature-row {
        grid-template-columns: 1fr;
    }

    .z-feature-cell {
        min-height: 50px;
        padding: 8px 10px;
        gap: 7px;
    }

    .z-feature-text {
        font-size: 0.86rem;
        line-height: 1.2;
    }

    .z-feature-icon-img {
        width: 22px;
        height: 22px;
    }

    .z-feature-icon-slot {
        width: 22px;
        height: 22px;
    }

    .z-feature-icon-fallback {
        font-size: 1rem;
    }
}
