/* =============================================================
   Share Modal — share-modal.css
   ============================================================= */

/* ── Bouton déclencheur ── */
.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 44px;
    border: 2px solid currentColor;
    border-radius: 22px;
    background: transparent;
    cursor: pointer;
    color: #555;
    transition: color 0.2s ease, background 0.2s ease, transform 0.15s ease;
    padding: 0 18px 0 14px;
    line-height: 1;
}

.share-btn:hover {
    color: #ffffff;
    background: #555;
    transform: scale(1.05);
}

.share-btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
    pointer-events: none;
    flex-shrink: 0;
}

.share-btn-label {
    font-size: 0.875rem;
    font-weight: 600;
    white-space: nowrap;
    pointer-events: none;
}

/* ── Overlay ── */
#share-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 99998;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(2px);
}

#share-modal-overlay.is-open {
    display: flex;
}

/* ── Modale ── */
#share-modal {
    background: #ffffff;
    border-radius: 12px;
    padding: 36px 32px 28px;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    position: relative;
    animation: shareModalIn 0.25s ease;
}

@keyframes shareModalIn {
    from { opacity: 0; transform: translateY(-16px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0)    scale(1); }
}

/* ── Bouton fermeture ── */
#share-modal-close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    cursor: pointer;
    color: #999;
    padding: 4px;
    line-height: 1;
    font-size: 22px;
    transition: color 0.15s ease;
}

#share-modal-close:hover {
    color: #333;
}

/* ── Titre de la modale ── */
#share-modal h3 {
    margin: 0 0 6px;
    font-size: 1.1rem;
    font-weight: 700;
    color: #222;
}

#share-modal-content-title {
    margin: 0 0 24px;
    font-size: 0.88rem;
    color: #777;
    word-break: break-word;
}

/* ── Boutons réseaux ── */
.share-network-btns {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
}

.share-network-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 14px 10px;
    border-radius: 10px;
    border: 1.5px solid #e5e5e5;
    background: #fafafa;
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 600;
    color: #444;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.12s ease;
    text-decoration: none;
}

.share-network-btn:hover {
    transform: translateY(-2px);
}

.share-network-btn svg {
    width: 26px;
    height: 26px;
}

/* Facebook */
.share-network-btn--facebook:hover {
    background: #1877f2;
    border-color: #1877f2;
    color: #fff;
}
.share-network-btn--facebook:hover svg { fill: #fff; }
.share-network-btn--facebook svg { fill: #1877f2; }

/* LinkedIn */
.share-network-btn--linkedin:hover {
    background: #0a66c2;
    border-color: #0a66c2;
    color: #fff;
}
.share-network-btn--linkedin:hover svg { fill: #fff; }
.share-network-btn--linkedin svg { fill: #0a66c2; }

/* ── Zone copier le lien ── */
.share-copy-zone {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.share-copy-url {
    flex: 1;
    padding: 10px 12px;
    border: 1.5px solid #e0e0e0;
    border-radius: 8px;
    font-size: 0.8rem;
    color: #555;
    background: #f5f5f5;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: default;
    outline: none;
}

.share-copy-btn {
    padding: 10px 16px;
    border-radius: 8px;
    border: none;
    background: #333;
    color: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.18s ease;
}

.share-copy-btn:hover {
    background: #111;
}

.share-copy-btn.copied {
    background: #28a745;
}

/* ── Responsive ── */
@media (max-width: 480px) {
    #share-modal {
        padding: 28px 20px 22px;
    }

    .share-network-btns {
        flex-direction: column;
    }

    .share-network-btn {
        flex-direction: row;
        justify-content: center;
        gap: 10px;
        padding: 12px 14px;
    }
}