.real-projects {
    padding-top: 165px;
}
.real-projects__heading {
    margin-top: 40px;
}
.real-projects__heading h1 {
    margin-top: 0;
    font-size: 36px;
    font-weight: 800;
    line-height: 1.3;
}
.real-projects__heading p {
    margin-top: 20px;
    font-size: 18px;
    line-height: 1.3;
    color: #021549;
}
.real-projects__tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 40px;
}
.real-projects__tabs-item {
    min-height: 36px;
    padding: 9px 12px;
    border: none;
    border-radius: 25px;
    background-color: #eff3ff;
    color: #021549;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.3;
    cursor: pointer;
    transition: all 0.2s ease;
}
.real-projects__tabs-item:hover,
.real-projects__tabs-item.active {
    background-color: #021549;
    color: #fff;
}
.real-projects__list {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin-top: 40px;
}
/* .real-projects__card {
    display: grid;
    grid-template-columns: 338px minmax(0, 1fr);
    min-height: 203px;
    overflow: hidden;
    border: 1px solid #dfe4f3;
    border-radius: 8px;
    background-color: #fff;
    transition: box-shadow 0.2s ease;
}
.real-projects__card:hover {
    box-shadow: 0 0 6px 2px rgba(14, 14, 15, 0.25);
}
.real-projects__card-image {
    position: relative;
    display: block;
    min-height: 203px;
    overflow: hidden;
}
.real-projects__card-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}
.real-projects__card-tag {
    position: absolute;
    left: 10px;
    top: 10px;
    z-index: 2;
    padding: 8px 10px;
    border-radius: 25px;
    background-color: #fff;
    color: #021549;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.15;
}
.real-projects__card-content {
    display: grid;
    grid-template-areas: "text order" "link order";
    grid-template-columns: minmax(0, 1fr) 259px;
    gap: 30px;
    align-items: start;
    padding: 40px 20px;
}
.real-projects__card-text {
    grid-area: text;
    min-width: 0;
}
.real-projects__card-text h2 {
    max-width: 688px;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
}
.real-projects__card-text h2 a {
    color: #021549;
}
.real-projects__card-text p {
    max-width: 688px;
    margin-top: 10px;
    font-size: 14px;
    line-height: 1.5;
    color: #021549;
}
.real-projects__card-link {
    grid-area: link;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 60px;
    color: #850003;
    font-size: 14px;
    line-height: 1.3;
}
.real-projects__card-link::after {
    content: "";
    width: 7px;
    height: 7px;
    border-right: 1px solid #850003;
    border-bottom: 1px solid #850003;
    transform: rotate(-45deg);
    transition: transform 0.2s ease;
} */
/* =========================================
   CARTE PRINCIPALE (Hauteur Uniforme)
   ========================================= */
.real-projects__card {
    display: grid;
    grid-template-columns: 338px minmax(0, 1fr);
    overflow: hidden;
    border: 1px solid #dfe4f3;
    border-radius: 8px;
    background-color: #fff;
    transition: box-shadow 0.2s ease;
    align-items: stretch; /* Essentiel : force les colonnes à la même hauteur */
}

.real-projects__card:hover {
    box-shadow: 0 0 6px 2px rgba(14, 14, 15, 0.25);
}

/* =========================================
   IMAGE GAUCHE (S'étire parfaitement)
   ========================================= */
.real-projects__card-image {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    min-height: 203px;
}

.real-projects__card-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover; /* Recadre l'image sans la déformer */
}

.real-projects__card-tag {
    position: absolute;
    left: 10px;
    top: 10px;
    z-index: 2;
    padding: 8px 10px;
    border-radius: 25px;
    background-color: #fff;
    color: #021549;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.15;
}

.real-projects__card-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: 1fr auto;
    grid-template-areas:
        "text order"
        "link .";
    gap: 30px;
    padding: 40px 20px;
    min-height: 203px;
}

.real-projects__card-text {
    grid-area: text;
    min-width: 0;
}

.real-projects__card-text h2 {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
}

.real-projects__card-text h2 a {
    color: #021549;
}

.real-projects__card-text p {
    margin-top: 10px;
    font-size: 14px;
    line-height: 1.5;
    color: #021549;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.real-projects__card-order {
    grid-area: order;
    align-self: start;
    width: 259px;
    height: 40px;
    padding: 0 18px;
    background: #021549;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    border-radius: 30px;
    border: none;
    cursor: pointer;
    transition: background 0.2s ease-in, box-shadow 0.2s ease;
}

.real-projects__card-order:hover {
    background: #850003;
    box-shadow: 0 0 6px 2px rgba(14, 14, 15, 0.25);
}

.real-projects__card-link {
    grid-area: link;
    align-self: end;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #850003;
    font-size: 14px;
    line-height: 1.3;
}

.real-projects__card-link::after {
    content: "";
    width: 7px;
    height: 7px;
    border-right: 1px solid #850003;
    border-bottom: 1px solid #850003;
    transform: rotate(-45deg);
    transition: transform 0.2s ease;
}

.real-projects__card-link:hover {
    color: #850003;
}

.real-projects__card-link:hover::after {
    transform: translateX(3px) rotate(-45deg);
}
.real-projects__card-link:hover {
    color: #850003;
}
.real-projects__card-link:hover::after {
    transform: translateX(3px) rotate(-45deg);
}
.real-projects__card-order {
    grid-area: order;
    background: linear-gradient(to right, #850003 0%, #850003 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 30px;
    border: none;
    cursor: pointer;
    transition: background 0.2s ease-in;
    width: 259px;
    min-height: 40px;
    padding: 10px 18px;
    background: linear-gradient(to right, #021549 0%, #021549 100%);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.3;
    text-align: center;
    justify-self: end;
}
.real-projects__card-order:hover {
    background: linear-gradient(to right, #850003 0%, #a80f12 100%);
    box-shadow: 0 0 6px 2px rgba(14, 14, 15, 0.25);
}
.real-projects__showmore {
    margin-top: 30px;
}
.real-projects__showmore-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 40px;
    border: 1px solid #dfe4f3;
    border-radius: 5px;
    background-color: rgba(0, 0, 0, 0);
    color: #021549;
    text-decoration: underline;
    cursor: pointer;
    transition: all 0.3s ease;
}
.real-projects__showmore-button:hover {
    background-color: #f9faff;
}
.real-projects .pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    color: #021549;
    font-size: 20px;
    margin-top: 30px;
}
.real-projects .pagination__num {
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    transition: all 0.3s ease;
    border-radius: 50%;
}
.real-projects .pagination__num:hover {
    color: #fff;
    background-color: #850003;
}
.real-projects .pagination__num.current {
    color: #fff;
    background-color: #850003;
}
.real-projects .pagination .arrow {
    width: 9px;
    height: 9px;
    border-left: 1px solid #021549;
    border-bottom: 1px solid #021549;
}
.real-projects .pagination .arrow:hover {
    border-left: 1px solid #021549;
    border-bottom: 1px solid #021549;
    cursor: pointer;
}
.real-projects .pagination .arrow-left {
    transform: rotate(45deg);
}
.real-projects .pagination .arrow-right {
    transform: rotate(-135deg);
}
@media screen and (max-width: 992px) {
    .real-projects__heading h1 {
        font-size: 30px;
    }
    .real-projects__heading p {
        font-size: 16px;
    }
    .real-projects__tabs {
        gap: 10px;
    }
    .real-projects__card {
        grid-template-columns: 280px minmax(0, 1fr);
    }
    .real-projects__card-content {
        grid-template-areas:
            "text text"
            "link order";
        grid-template-rows: 1fr auto;
        padding: 20px 15px;
        gap: 15px;
    }
    .real-projects__card-image {
        min-height: 168px;
    }
    .real-projects__card-text h2 {
        font-size: 16px;
    }
    .real-projects__card-text p {
        line-height: 1.3;
    }
    .real-projects__card-link {
        margin-top: 0;
        align-self: center;
    }
    .real-projects__card-order {
        align-self: end;
        justify-self: end;
    }
}
@media screen and (max-width: 768px) {
    .real-projects__card {
        grid-template-columns: 240px minmax(0, 1fr);
    }
    .real-projects__card-content {
        grid-template-areas:
            "text"
            "link"
            "order";
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
    }
    .real-projects__card-image {
        min-height: 168px;
    }
    .real-projects__card-order {
        width: 100%;
        justify-self: start;
    }
    .real-projects__card-link {
        justify-self: start;
        white-space: nowrap;
    }
}
@media screen and (max-width: 640px) {
    .real-projects__heading {
        margin-top: 30px;
    }
    .real-projects__heading h1 {
        font-size: 24px;
    }
    .real-projects__heading p {
        font-size: 14px;
    }
    .real-projects__tabs {
        margin-top: 30px;
    }
    .real-projects__list {
        gap: 24px;
        margin-top: 30px;
    }
    .real-projects__card {
        grid-template-columns: 1fr;
    }
    .real-projects__card-image {
        aspect-ratio: 16 / 9;
        height: auto;
    }
    .real-projects__card-image img {
        position: relative;
    }
    .real-projects__card-content {
        grid-template-areas: "text" "link" "order";
        grid-template-columns: 1fr;
        gap: 18px;
        padding: 15px 10px 10px;
    }
    .real-projects__card-text h2 {
        font-size: 16px;
    }
    .real-projects__card-link {
        margin-top: 0;
        justify-self: start;
    }
    .real-projects__card-order {
        width: 100%;
        justify-self: stretch;
    }
    .real-projects__pagination {
        gap: 10px;
        font-size: 18px;
    }
    .real-projects .pagination__num {
        width: 30px;
        height: 30px;
    }
}
