/* Isolated sharing UI. Never changes the poster or checkout presentation. */
.preview-area-label { right: 22px; justify-content: flex-end; align-items: center; }
.preview-area-tools { display: flex; align-items: center; gap: 12px; }
.studio-share-button {
    display: inline-flex; align-items: center; justify-content: center; gap: 7px;
    padding: 7px 10px; border: 1px solid #cfc7ba; border-radius: 8px;
    background: rgba(255, 255, 255, .72); color: #65543a;
    font: 600 12px var(--font-sans, sans-serif); cursor: pointer; white-space: nowrap;
}
.studio-share-button span { font: inherit; }
.studio-share-button svg { flex-shrink: 0; }
.studio-share-button:hover { background: #fff; border-color: #a78a51; }
.studio-share-button:focus-visible, .studio-share-dialog :focus-visible { outline: 2px solid #9b7734; outline-offset: 3px; }
.studio-share-button .studio-share-label-short { display: none; }
.exact-preview-result > .studio-share-button { align-self: center; margin-top: 12px; }
.studio-share-dialog {
    box-sizing: border-box; margin: auto; padding: 24px;
    width: min(520px, calc(100% - 24px)); max-height: calc(100dvh - 32px);
    overflow-y: auto; overscroll-behavior: contain; border: 1px solid #e3ddd2;
    border-radius: 18px; background: #faf9f6; color: #24221e;
    box-shadow: 0 24px 80px #0003; font: 14px/1.5 var(--font-sans, sans-serif);
}
.studio-share-dialog::backdrop { background: rgba(25, 23, 20, .58); }
.studio-share-dialog [hidden] { display: none !important; }
.studio-share-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.studio-share-heading h2 { margin: 0; font: 600 24px/1.2 var(--font-serif, Georgia, serif); }
.studio-share-close { border: 0; background: transparent; color: #5f594f; font: 28px sans-serif; width: 40px; height: 40px; flex-shrink: 0; cursor: pointer; }
.studio-share-status { margin: 0 0 12px; color: #77603a; }
.studio-share-status:empty { display: none; }
.studio-share-dialog[aria-busy="true"] .studio-share-status::before {
    content: '';
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(119, 96, 58, 0.25);
    border-top-color: #77603a;
    border-radius: 50%;
    animation: studioShareSpin 0.8s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}
@keyframes studioShareSpin {
    to { transform: rotate(360deg); }
}
.studio-share-image { display: block; width: auto; max-width: 100%; max-height: 48dvh; height: auto; margin: 0 auto 14px; border-radius: 4px; box-shadow: 0 5px 20px rgba(0,0,0,0.12); }
.studio-share-resolution { margin: 10px 0 16px; padding: 12px 14px; border: 1px solid #e4d8be; border-radius: 10px; background: #f7f3eb; color: #4e4230; text-align: left; }
.studio-share-resolution strong { display: block; font-size: 13px; font-weight: 700; color: #2e281e; }
.studio-share-note { margin: 5px 0 0; font-size: 12px; line-height: 1.55; color: #625c52; }
.studio-share-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }
.studio-share-actions button, .studio-share-download {
    display: inline-flex; align-items: center; justify-content: center; flex: 1 1 auto;
    min-height: 44px; padding: 11px 16px; border-radius: 9px; border: 1px solid #cfc7ba;
    font: 600 13px var(--font-sans, sans-serif); text-decoration: none; cursor: pointer;
    background: #fff; color: #3e382e; transition: background 0.15s ease;
}
.studio-share-actions [data-share-native] { background: #24221e; color: #fff; border-color: #24221e; }
.studio-share-actions [data-share-native]:hover { background: #3d3933; }
.studio-share-actions .studio-share-download:hover { background: #f7f5f0; border-color: #b5a995; }
.studio-share-actions button:disabled { opacity: .6; cursor: wait; }
.studio-share-fallback { margin: 10px 0 0; font-size: 12px; color: #625c52; text-align: center; }
@media (max-width: 1350px) { .preview-area-tools small { display: none; } }
@media (max-width: 800px) {
    .preview-area-label { left: 18px; right: 18px; top: 8px; }
    .preview-area-label .studio-share-label-full { display: none; }
    .preview-area-label .studio-share-label-short { display: inline; }
    .studio-share-button { min-height: 36px; }
    .studio-share-dialog { padding: 18px; }
    .studio-share-heading h2 { font-size: 21px; }
    .studio-share-image { max-height: 40dvh; }
}
