#globalShareModal.modal-backdrop {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(17, 25, 44, 0.6);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    overflow-y: auto;
    padding: 2rem 1rem;
    -webkit-overflow-scrolling: touch;
}
#globalShareModal .btn {
    white-space: nowrap;
    max-width: 100%;
    border-radius: 0.5rem;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
    padding: 0.6rem 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border: 1px solid transparent;
    cursor: pointer;
}
#globalShareModal .btn:focus-visible {
    outline: 2px solid var(--brand-header-secondary-bg, #2b3a7f);
    outline-offset: 2px;
}
#globalShareModal .btn-primary {
    background-color: var(--brand-header-secondary-bg, #2b3a7f);
    color: #fff;
    border-color: var(--brand-header-secondary-bg, #2b3a7f);
}
#globalShareModal .btn-primary:hover {
    background-color: #1f2a5c;
    border-color: #1f2a5c;
    color: #fff;
}
#globalShareModal .btn-outline {
    background-color: #fff;
    color: var(--brand-header-secondary-bg, #2b3a7f);
    border-color: var(--brand-header-secondary-bg, #2b3a7f);
}
#globalShareModal .btn-outline:hover {
    background-color: var(--brand-header-secondary-bg, #2b3a7f);
    border-color: var(--brand-header-secondary-bg, #2b3a7f);
    color: #fff;
}
#globalShareModal .modal-body {
    overflow-x: hidden;
}
#globalShareModal.is-visible {
    display: flex;
}
#globalShareModal .modal-content {
    position: relative;
    background: #fff;
    margin: 0 auto;
    border-radius: 1rem;
    width: 100%;
    max-width: 780px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    align-self: flex-start;
}
#globalShareModal .modal-large {
    max-width: 820px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}
#globalShareModal .modal-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 2;
}
#globalShareModal .modal-close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #6c757d;
    padding: 0.25rem;
}
#globalShareModal .modal-body {
    padding: 1rem 1.25rem;
}
#globalShareModal .spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e9ecef;
    border-top: 4px solid var(--color-primary, #2b3a7f);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Mobile optimizations */
@media (max-width: 480px) {
    #globalShareModal.modal-backdrop {
        padding: 1rem 0.5rem;
    }
    #globalShareModal .modal-content {
        max-width: 100%;
        border-radius: 0.75rem;
    }
    #globalShareModal .modal-header h3 {
        font-size: 1rem;
    }
    #globalShareModal .modal-header .material-icons {
        font-size: 18px;
    }
    #globalShareModal .modal-body {
        padding: 0.75rem 1rem;
    }
    #globalShareModal .form-group label {
        font-size: 0.9rem;
    }
    #globalShareModal select,
    #globalShareModal textarea,
    #globalShareModal input[type="text"] {
        font-size: 1rem;
    }
    #globalShareModal .btn {
        width: 100%;
    }
    #globalShareModal #globalShareMessage {
        min-height: 96px;
    }
    #globalShareModal #globalOgPreview > div {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    #globalShareModal #globalOgCanvas {
        width: 100% !important;
        height: auto !important;
    }
    #globalShareModal .modal-large {
        max-height: 85vh;
    }
    #globalShareModal .share-actions {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        gap: 0.5rem;
    }
}
