.mcpp-dialog {
    box-sizing: border-box;
    position: fixed;
    inset: 0;
    width: min(860px, calc(100% - 32px));
    max-width: none;
    max-height: calc(100vh - 32px);
    max-height: calc(100dvh - 32px);
    margin: auto;
    padding: 0;
    border: 0;
    border-radius: 18px;
    overflow: auto;
    background: #fff;
    color: #202020;
    font-family: inherit;
    box-shadow: 0 24px 90px #0005;
}
.mcpp-dialog:not([open]) { display: none; }
.mcpp-dialog::backdrop { background: rgb(0 0 0 / 58%); }
.mcpp-dialog * { box-sizing: border-box; }
.mcpp-layout { display: grid; }
.mcpp-with-image { grid-template-columns: 1fr 1fr; }
.mcpp-media { min-width: 0; background: #f4f4f4; display: grid; place-items: center; }
.mcpp-dialog .mcpp-photo { display: block; width: 100%; height: auto; max-height: 65vh; object-fit: contain; margin: 0; border: 0; }
.mcpp-content { min-width: 0; padding: 56px 36px 36px; align-self: center; overflow-wrap: anywhere; }
.mcpp-dialog #mcpp-heading { font-family: inherit; font-size: clamp(24px, 3vw, 34px); line-height: 1.15; margin: 0 0 18px; color: inherit; }
.mcpp-text { font-size: 16px; line-height: 1.65; }
.mcpp-text p { margin: 0 0 16px; }
.mcpp-text img { max-width: 100%; height: auto; }
.mcpp-dialog .mcpp-button { display: inline-block; padding: 13px 22px; margin-top: 8px; border: 2px solid #202020; border-radius: 6px; background: #202020; color: #fff; font: inherit; font-weight: 700; line-height: 1.4; text-align: center; text-decoration: none; }
.mcpp-dialog .mcpp-button:hover { background: #444; border-color: #444; color: #fff; }
.mcpp-dialog .mcpp-close { position: sticky; float: right; top: 10px; right: 10px; z-index: 1; width: 44px; height: 44px; min-height: 44px; margin: 10px 10px -54px 0; padding: 0; border: 1px solid #ddd; border-radius: 50%; background: #fff; color: #202020; font: 30px/1 Arial, sans-serif; cursor: pointer; display: grid; place-items: center; }
.mcpp-dialog :focus-visible { outline: 3px solid #55585f; outline-offset: 3px; }
@media (max-width: 600px) {
    .mcpp-with-image { grid-template-columns: 1fr; }
    .mcpp-dialog .mcpp-photo { max-height: 32vh; max-height: 32dvh; }
    .mcpp-content { padding: 28px 24px; }
    .mcpp-layout:not(.mcpp-with-image) .mcpp-content { padding-top: 60px; }
    .mcpp-dialog .mcpp-button { width: 100%; }
}
/* Banner layouts keep the original image ratio at every viewport width. */
.mcpp-mode-banner .mcpp-layout,
.mcpp-mode-image .mcpp-layout { grid-template-columns: minmax(0, 1fr); }
.mcpp-banner-link { display: block; width: 100%; min-width: 0; }
.mcpp-mode-banner .mcpp-photo,
.mcpp-mode-image .mcpp-photo { height: auto; max-height: none; }
.mcpp-mode-banner .mcpp-content { padding-top: 28px; }
.mcpp-dialog .mcpp-banner-link:focus-visible { outline-offset: -4px; }

.mcpp-dialog { border:1px solid #d4d6da; }
.mcpp-dialog .mcpp-close { background:linear-gradient(135deg,#fff,#e2e4e8); border-color:#c6c8cd; }
.mcpp-dialog .mcpp-button { background:#191a1c; border-color:#191a1c; }
.mcpp-dialog .mcpp-button:hover { background:#35363a; border-color:#35363a; }
/* Isolate banner sizing from theme image/link rules, including thumbnail limits. */
.mcpp-dialog.mcpp-mode-image .mcpp-layout,
.mcpp-dialog.mcpp-mode-banner .mcpp-layout {
    width: 100%;
    min-width: 0;
    min-height: 0;
    margin: 0;
    padding: 0;
}
.mcpp-dialog .mcpp-media {
    width: 100%;
    max-width: none;
    min-height: 0;
    margin: 0;
    padding: 0;
}
.mcpp-dialog .mcpp-banner-link {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0;
    line-height: 0;
}
.mcpp-dialog .mcpp-media img.mcpp-photo {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    aspect-ratio: auto;
}
.mcpp-dialog.mcpp-mode-banner .mcpp-media img.mcpp-photo,
.mcpp-dialog.mcpp-mode-image .mcpp-media img.mcpp-photo {
    max-height: none !important;
}
