.site-modal-admin-thumb {
    display: block;
    max-height: 96px;
    max-width: 180px;
    width: auto;
    object-fit: contain;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: #f8fafc;
}

.site-modal-admin-preview-panel .card-body {
    padding: 1.25rem;
}

.site-modal-admin-preview-stage {
    position: relative;
    height: 768px;
    border-radius: 1rem;
    overflow: hidden;
    background:
        linear-gradient(135deg, rgba(6, 199, 85, 0.12), rgba(59, 130, 246, 0.12)),
        #eef2f7;
    border: 1px solid rgba(15, 23, 42, 0.08);
}

.site-modal-admin-preview-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.35);
}

.site-modal-admin-preview-overlay--pos-x-left { justify-content: flex-start; }
.site-modal-admin-preview-overlay--pos-x-center { justify-content: center; }
.site-modal-admin-preview-overlay--pos-x-right { justify-content: flex-end; }

.site-modal-admin-preview-overlay--pos-y-top { align-items: flex-start; }
.site-modal-admin-preview-overlay--pos-y-center { align-items: center; }
.site-modal-admin-preview-overlay--pos-y-bottom { align-items: flex-end; }

.site-modal-admin-preview-stage .site-modal-card {
    animation: none;
}

.site-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 10060;
    display: flex;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(4px);
    animation: siteModalOverlayIn 0.25s ease both;
}

.site-modal-overlay--pos-x-left { justify-content: flex-start; }
.site-modal-overlay--pos-x-center { justify-content: center; }
.site-modal-overlay--pos-x-right { justify-content: flex-end; }

.site-modal-overlay--pos-y-top { align-items: flex-start; }
.site-modal-overlay--pos-y-center { align-items: center; }
.site-modal-overlay--pos-y-bottom { align-items: flex-end; }

.site-modal-card {
    position: relative;
    width: min(var(--site-modal-width, 480px), 100%);
    max-height: calc(100vh - 2rem);
    margin-left: var(--site-modal-offset-x, 0px);
    margin-top: var(--site-modal-offset-y, 0px);
    overflow: auto;
    border-radius: 1.25rem;
    background: #fff;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.25);
    animation: siteModalCardIn 0.35s cubic-bezier(0.21, 1.02, 0.73, 1) both;
}

.site-modal-card--preview {
    max-height: none;
    transform: scale(0.92);
    transform-origin: center center;
}

[data-theme-style="dark"] .site-modal-card {
    background: #181c24;
    color: #f8fafc;
}

.site-modal-card__close {
    position: absolute;
    top: 0.85rem;
    right: 0.85rem;
    z-index: 2;
    width: 2rem;
    height: 2rem;
    border: 0;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.08);
    color: #64748b;
}

.site-modal-card__image {
    display: block;
    width: 100%;
    height: auto;
    object-fit: var(--site-modal-image-object-fit, contain);
    object-position: center;
    background: #f8fafc;
    border-radius: 1.25rem 1.25rem 0 0;
}

[data-theme-style="dark"] .site-modal-card__image {
    background: #0f172a;
}

.site-modal-card__body {
    padding: 1.25rem 1.5rem 1.5rem;
}

.site-modal-card--preview .site-modal-card__body {
    padding: 1rem 1.125rem 1.125rem;
}

.site-modal-card__title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.65rem;
    padding-right: 2rem;
}

.site-modal-card--preview .site-modal-card__title {
    font-size: 1rem;
}

.site-modal-card__description {
    color: #475569;
    line-height: 1.55;
    white-space: pre-wrap;
    font-size: 0.95rem;
}

.site-modal-card--preview .site-modal-card__description {
    font-size: 0.85rem;
}

[data-theme-style="dark"] .site-modal-card__description {
    color: #cbd5e1;
}

.site-modal-card__actions {
    margin-top: 1rem;
}

.site-modal-card__cta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.85rem 1rem;
    border: 0;
    border-radius: 14px;
    text-decoration: none !important;
    background: linear-gradient(135deg, #229ED9 0%, #0088cc 50%, #0077b5 100%);
    color: #ffffff !important;
    box-shadow: 0 8px 24px rgba(0, 136, 204, 0.35);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    position: relative;
    overflow: hidden;
}

.site-modal-card__cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, transparent 40%, rgba(255, 255, 255, 0.18) 50%, transparent 60%);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.site-modal-card__cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(0, 136, 204, 0.45);
    color: #ffffff !important;
}

.site-modal-card__cta:hover::before {
    transform: translateX(100%);
}

.site-modal-card__cta-icon {
    width: 2.65rem;
    height: 2.65rem;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.2rem;
}

.site-modal-card__cta-copy {
    flex: 1;
    min-width: 0;
    text-align: left;
}

.site-modal-card__cta-title {
    display: block;
    font-weight: 700;
    font-size: 0.95rem;
    line-height: 1.25;
}

.site-modal-card__cta-arrow {
    opacity: 0.85;
    font-size: 0.85rem;
    flex-shrink: 0;
}

.site-modal-card--preview .site-modal-card__cta {
    padding: 0.7rem 0.85rem;
}

.site-modal-card--preview .site-modal-card__cta-icon {
    width: 2.25rem;
    height: 2.25rem;
    font-size: 1rem;
}

.site-modal-card--preview .site-modal-card__cta-title {
    font-size: 0.82rem;
}

.site-modal-card__progress {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 4px;
    transform-origin: left center;
    background: linear-gradient(90deg, #06C755, #2DD668);
    animation: siteModalProgress linear forwards;
}

@keyframes siteModalOverlayIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes siteModalCardIn {
    from { opacity: 0; transform: translateY(16px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes siteModalProgress {
    from { transform: scaleX(1); }
    to { transform: scaleX(0); }
}

@media (max-width: 991.98px) {
    .site-modal-admin-preview-panel {
        position: static !important;
        margin-top: 1.5rem;
    }
}

@media (max-width: 575.98px) {
    .site-modal-overlay {
        padding: 0.75rem;
    }

    .site-modal-card {
        border-radius: 1rem;
    }

    .site-modal-admin-preview-stage {
        height: 320px;
    }
}
