.ec-large { display: none; }
.ec-card { box-sizing: border-box; padding: 24px; border: 1px solid #dce2e8; border-radius: 20px; background: #fff; color: #17212b; box-shadow: 0 8px 28px #17212b0c; }
.ec-small > :first-child, .ec-dialog-content > :first-child { margin-top: 0; }
.ec-small > :last-child, .ec-dialog-content > :last-child { margin-bottom: 0; }
/* Also hide the old trigger on pages saved with version 1.0. */
.ec-card > .ec-open { display: none; }
.ec-card:not(.ec-editor) { width: var(--ec-small-width, 100%); max-width: 100%; height: var(--ec-small-height, auto); min-height: 60px; display: flex; flex-direction: column; }
.ec-card[data-ec-ready] { cursor: pointer; }
.ec-card > .ec-small { flex: 1 1 auto; min-height: 0; overflow: auto; }
.ec-card > .ec-small, .ec-dialog > .ec-dialog-content { display: flex; flex-direction: column; }
.ec-card > .ec-small { gap: var(--ec-small-gap, 16px); }
.ec-dialog > .ec-dialog-content { gap: var(--ec-large-gap, 24px); }
.ec-card > .ec-small > *, .ec-dialog > .ec-dialog-content > * { margin-block: 0 !important; flex-shrink: 0; }
.ec-dialog { cursor: auto; }
.ec-card:focus-visible, .ec-close:focus-visible { outline: 3px solid #2271b1; outline-offset: 4px; }
dialog.ec-dialog { box-sizing: border-box; position: fixed; inset: 0; margin: auto; width: 90vw; height: 80vh; max-width: 90vw; max-height: 80vh; padding: 0; border: 1px solid #dce2e8; border-radius: 20px; background: #fff; color: #17212b; box-shadow: 0 24px 100px #0005; overflow: hidden; transform-origin: center; }
dialog.ec-dialog:not([open]) { display: none; }
dialog.ec-dialog[open] { display: flex; flex-direction: column; }
dialog.ec-dialog::backdrop { background: rgb(10 18 28 / 65%); backdrop-filter: blur(5px); }
.ec-dialog-header { flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 24px; border-bottom: 1px solid #e8edf2; }
.ec-dialog-title { font-size: 16px; font-weight: 600; overflow-wrap: anywhere; }
.ec-dialog .ec-close { flex-shrink: 0; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: #edf1f5; color: #17212b; font: 30px/1 sans-serif; cursor: pointer; }
.ec-dialog-content { flex: 1 1 auto; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: clamp(16px, 3vw, 48px); }
.ec-dialog-content img, .ec-small img { max-width: 100%; height: auto; }
html.ec-modal-open { overflow: hidden !important; }
@media (max-width: 600px) { .ec-card { padding: 18px; } .ec-dialog-header { padding: 10px 16px; } }
