/* ===============================
   TEXTE DES CARTES
   =============================== */
.svc-txt {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 0.95rem;
    line-height: 1.55;
    color: #374151;
    margin-top: 5px;
}

/* ===============================
   TITRE DES CARTES
   =============================== */
.svc-title-2 {
    font-size: 1rem;
    font-weight: 700;
    color: #15416e;
    line-height: 1.3;
    margin: 10px 0 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: calc(1rem * 1.3 * 2);
}

/* ===============================
   MODALE (POPUP)
   =============================== */
.svc-modal {
    position: fixed;
    inset: 0;
    background: rgba(10, 20, 30, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

/* Quand la modale est ouverte */
.svc-modal:not([hidden]) {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* ===============================
   CONTENEUR PRINCIPAL DE LA MODALE
   =============================== */
.svc-modal__dialog {
    background: #fff;
    width: min(860px, 92vw);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22),
    0 4px 14px rgba(0, 0, 0, 0.12);
    animation: modalFadeUp 0.3s ease both;
    overflow: hidden;
    position: relative;
}

/* Effet de halo discret autour de la modale */
.svc-modal__dialog::before {
    content: "";
    position: absolute;
    inset: 0;
    border: 1px solid rgba(14, 53, 77, 0.25);
    pointer-events: none;
    box-shadow: 0 0 20px rgba(14, 53, 77, 0.25);
    z-index: 1;
}

/* Animation d’apparition */
@keyframes modalFadeUp {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===============================
   EN-TÊTE DE LA MODALE
   =============================== */
.svc-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 22px;
    border-bottom: 2px solid #0e354d; /* Ligne accent élégante */
    background: linear-gradient(90deg, #0e354d 0%, #15416e 100%);
}

.svc-modal__title {
    font-family: "Rajdhani", sans-serif;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #fff;
    font-size: 22px;
    line-height: 1.2;
    margin: 0;
}

.svc-modal__close {
    border: 0;
    background: transparent;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    color: #f8fafc;
    transition: color 0.2s ease, transform 0.15s ease;
}

.svc-modal__close:hover {
    color: #bcd3e2;
    transform: scale(1.05);
}

/* ===============================
   CONTENU DE LA MODALE
   =============================== */
.svc-modal__body {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 18px;
    padding: 18px 22px 22px;
    align-items: start;
}

.svc-modal__img {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    max-height: 230px;
    object-fit: cover;
    border: 1px solid rgba(14, 53, 77, 0.2);
}

/* Texte long avec scroll si besoin */
#svc-modal-text {
    max-height: 50vh;
    overflow: auto;
    font-size: 1rem;
    line-height: 1.7;
    color: #111827;
}

/* ===============================
   CARTES (EFFET HOVER MODERNE)
   =============================== */
.svc-card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid transparent;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.svc-card picture img {
    width: 100%;
    height: auto;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.svc-card:hover picture img {
    transform: scale(1.035);
}

/* Accent color sous le titre au hover */
.svc-card:hover .svc-title-2 {
    color: #0e354d;
    transition: color 0.3s ease;
}

/* ===============================
   RESPONSIVE (MOBILE)
   =============================== */
@media (max-width: 768px) {
    .svc-modal__dialog {
        width: 94vw;
    }

    .svc-modal__body {
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 14px 16px 18px;
    }

    .svc-modal__img {
        aspect-ratio: 16 / 9;
        max-height: 36vh;
    }

    #svc-modal-text {
        max-height: 38vh;
    }

    .svc-modal__title {
        font-size: 19px;
        letter-spacing: 1.6px;
    }
}
