/* ============================================================
   Design Lab : Share
   Styles for the one shared Share popup (Views/DesignLab/_DesignLabShareModal.cshtml,
   behaviour in js/designlab-share.js). Used by the Design Lab page (viewer, diamond
   overlay, Finalise Purchase summary) and the Ring Board.

   Desktop is the full popup. At <= 1024px phones normally get the device's own share
   sheet instead (navigator.share); this smaller layout is only the fallback for
   browsers without it.
   ============================================================ */

/* ---------- backdrop ---------- */
.dl-share-backdrop {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(0, 0, 0, 0.45);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.18s ease, visibility 0.18s ease;
}

    .dl-share-backdrop.is-open {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

/* ---------- dialog ---------- */
.dl-share-modal {
    box-sizing: border-box;
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: fit-content;
    max-width: 657px;
    padding: 42px;
    background: #f7f6f1;
    color: #003743;
    outline: none;
}

.dl-share-modal__close {
    position: absolute;
    top: 20px;
    right: 20px;
    padding: 0;
    border: 0;
    background: transparent;
    line-height: 0;
    cursor: pointer;
}

    .dl-share-modal__close img {
        display: block;
        width: 42px;
        height: 42px;
    }

.dl-share-modal__title {
    margin: 0;
    display: flex;
    justify-content: center;
    gap: 8px;
    font-size: 32px;
    line-height: 120%;
    letter-spacing: 4%;
    font-weight: 700;
    text-transform: uppercase;
    text-align: center;
    color: #003743;
}

.dl-share-modal__title-part {
    font-weight: 400;
}

.dl-share-modal__subtitle {
    margin: 0;
    font-size: 16px;
    line-height: 1;
    font-weight: 400;
    text-align: center;
    color: #003743;
}

/* ---------- tiles ---------- */
.dl-share-modal__grid {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    row-gap: 30px;
    column-gap: 30px;
    margin-top: 30px;
}

.dl-share-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 0 3px;
    border: 0;
    background: transparent;
    font-family: inherit;
    cursor: pointer;
}

.dl-share-tile__label {
    margin: 0;
    font-size: 14px;
    line-height: 100%;
    font-weight: 700;
    text-align: center;
    color: #000;
}

.dl-share-tile:hover .share-icon {
    transform: translateY(-2px);
    opacity: 0.9;
}

/* ---------- brand icons ---------- */
.share-icon {
    width: 62px;
    height: 62px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #fff;
    font-size: 30px;
    line-height: 1;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.share-icon--whatsapp {
    background: #25D366;
}

.share-icon--instagram {
    background: linear-gradient(45deg, #feda75, #fa7e1e, #d62976, #962fbf, #4f5bd5);
}

.share-icon--x {
    background: #000000;
}

.share-icon--facebook {
    background: #1877F2;
}

.share-icon--pinterest {
    background: #E60023;
}

.share-icon--tiktok {
    background: #000000;
}

.share-icon--copy {
    background: #003743;
}

.share-icon--save {
    background: #f8e6e6;
}

    .share-icon--save i {
        color: #e5233d;
        transition: transform 0.2s ease;
    }

.dl-share-tile.is-saved .share-icon--save i {
    transform: scale(1.1);
}

/* ---------- phone-sized fallback (no native share sheet) ---------- */
@media screen and (max-width: 1024px) {
    .dl-share-modal {
        width: 330px;
        max-width: 100%;
        padding: 20px 18px 20px 20px;
        gap: 6px;
    }

    .dl-share-modal__close {
        top: 19px;
        right: 19px;
    }

        .dl-share-modal__close img {
            width: 32px;
            height: 32px;
        }

    .dl-share-modal__title {
        gap: 6px;
        font-size: 22px;
    }

    .dl-share-modal__subtitle {
        font-size: 12px;
    }

    .dl-share-modal__grid {
        display: grid;
        grid-template-columns: repeat(4, max-content);
        justify-content: space-between;
        justify-items: start;
        row-gap: 24px;
        column-gap: 0;
        margin-top: 26px;
    }

    .dl-share-tile {
        gap: 6px;
        padding: 0;
    }

    .dl-share-tile__label {
        font-size: 8px;
    }

    .share-icon {
        width: 50px;
        height: 50px;
    }
}
