html {
    scroll-behavior: smooth;
}
.dii-inventory-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.di-project-card {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
}

.di-card-image {
    position: relative;
    height: 200px;
    background-size: cover;
    background-position: center;
}

.di-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #FF5A5F;
    color: #fff;
    padding: 5px 10px;
    font-size: 12px;
    border-radius: 4px;
    text-transform: uppercase;
}

.di-delivery {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background: rgba(0,0,0,0.7);
    color: #fff;
    padding: 5px 10px;
    font-size: 12px;
    border-radius: 4px;
}

.di-card-body {
    padding: 15px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.di-title {
    font-size: 18px;
    margin-bottom: 5px;
}

.di-meta, .di-location {
    font-size: 13px;
    color: #555;
}

.di-units span {
    display: inline-block;
    background: #eee;
    padding: 3px 8px;
    margin: 2px;
    font-size: 12px;
    border-radius: 4px;
}

.di-price {
    font-size: 16px;
    font-weight: bold;
    margin: 10px 0;
}

.di-details-btn {
    display: block;
    text-align: center;
    background: #0073e6;
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    text-decoration: none;
    transition: background 0.3s;
}

.di-details-btn:hover {
    background: #005bb5;
}















































































































/* =====================================================
   GLOBAL SAFETY FIX (STOP HORIZONTAL SCROLL)
===================================================== */
html, body {
    overflow-x: hidden;
}

/* Elementor parent flex break fix */
.elementor-section,
.elementor-container,
.elementor-widget-wrap,
.elementor-column-wrap {
    max-width: 100%;
    overflow-x: hidden;
    display: block !important;
    width: 100% !important;
}

/* =====================================================
   DEVELOPER GRID — 4 COLUMNS
===================================================== */
.di-developers-grid {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 24px !important;

    width: 100%;
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 15px;
    box-sizing: border-box;

    float: none !important;
    flex-wrap: unset !important;
    justify-content: unset !important;
}

/* Ensure each card stays inside grid cell */
.di-developers-grid > .di-developer-card {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    float: none !important;
}

/* =====================================================
   RESPONSIVE GRID
===================================================== */
@media (max-width: 1024px) {
    .di-developers-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 600px) {
    .di-developers-grid {
        grid-template-columns: 1fr !important;
    }
}

/* =====================================================
   CARD
===================================================== */
.di-project-card,
.di-developer-card {
    background: #ffffff;
    border-radius: 10px;
    overflow: hidden;

    display: flex !important;
    flex-direction: column !important;

    width: 100%;
    min-height: 420px;

    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.di-project-card:hover,
.di-developer-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.15);
}

/* =====================================================
   IMAGE
===================================================== */
.di-card-image,
.di-developer-image {
    width: 100%;
    height: 180px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* =====================================================
   CARD BODY
===================================================== */
.di-card-body {
    padding: 20px;
    display: flex !important;
    flex-direction: column !important;
    flex: 1;
    min-width: 0;
}

/* =====================================================
   TITLE
===================================================== */
.di-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    line-height: 1.3;
}

.di-title a {
    color: #0073e6;
    text-decoration: none;
}

.di-title a:hover {
    text-decoration: underline;
}

/* =====================================================
   DESCRIPTION — FULL
===================================================== */
.di-description {
    font-size: 14px;
    color: #555;
    line-height: 1.5;
    margin-bottom: 10px;

    display: block !important;
    -webkit-line-clamp: unset !important;
    -webkit-box-orient: unset !important;
    overflow: visible !important;
}

/* =====================================================
   HIGHLIGHTS (FIRST 3 ITEMS VISIBLE)
===================================================== */
.di-highlights {
    font-size: 13px;
    color: #444 !important;
    padding-left: 16px;
    margin-bottom: 15px;

    list-style-type: disc !important;
    list-style-position: inside;
}

.di-highlights li {
    margin-bottom: 4px;
    color: #444 !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* Show only first 3 items */
.di-highlights li:nth-child(n+4) {
    display: none;
}

/* =====================================================
   BUTTON
===================================================== */
.di-details-btn {
    margin-top: auto;
    display: block;
    width: 100%;

    background: #0073e6;
    color: #ffffff;

    text-align: center;
    padding: 10px 15px;
    border-radius: 6px;

    text-decoration: none;
    font-weight: 500;
}

.di-details-btn:hover {
    background: #005bb5;
}



/* =====================================================
   CITY CARD — COMPACT FIX
===================================================== */

/* City card height smaller */
.di-city-card {
    min-height: 340px;   /* developer 420px, city smaller */
}

/* Limit city description height */
.di-city-card .di-description {
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 10px;

    display: -webkit-box;
    -webkit-line-clamp: 3;   /* max 3 lines */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Limit highlights to 2 items for city */
.di-city-card .di-highlights li:nth-child(n+3) {
    display: none;
}

/* Remove excessive vertical gap before button */
.di-city-card .di-details-btn {
    margin-top: 12px;   /* instead of auto */
}














/* =========================
 * FORCE CENTER PAGINATION
 * ========================= */
.dii-pagination {
    width: 100% !important;
    display: block !important;
    text-align: center !important; /* 🔥 KEY FIX */
    margin: 48px auto 24px !important;
}

/* reset possible flex parents */
.dii-pagination * {
    box-sizing: border-box;
}

.dii-pagination .page-numbers {
    display: inline-flex !important; /* 🔥 inline center */
    align-items: center;
    justify-content: center;

    min-width: 40px;
    height: 40px;
    margin: 0 6px;

    font-size: 14px;
    font-weight: 500;

    border: 1px solid #e5e7eb;
    border-radius: 6px;

    background: #fff;
    color: #111827;
    text-decoration: none;

    transition: all 0.2s ease;
}

.dii-pagination .page-numbers:hover {
    background: #f3f4f6;
}

.dii-pagination .page-numbers.current {
    background: #111827;
    color: #fff;
    border-color: #111827;
}

.dii-pagination .page-numbers.prev,
.dii-pagination .page-numbers.next {
    font-weight: 600;
}

/* =========================
 * MOBILE
 * ========================= */
@media (max-width: 768px) {
    .dii-pagination {
        margin: 32px auto 16px !important;
    }

    .dii-pagination .page-numbers {
        min-width: 36px;
        height: 36px;
        font-size: 13px;
        margin: 0 4px;
    }
}