.webinar-dialog {
    --webinar-right: max(1rem, env(safe-area-inset-right));
    --webinar-left: max(1rem, env(safe-area-inset-left));
    --webinar-bottom: max(1rem, env(safe-area-inset-bottom));
    position: fixed;
    z-index: 70;
    right: var(--webinar-right);
    bottom: var(--webinar-bottom);
    width: min(21rem, 100% - var(--webinar-right) - var(--webinar-left));
    max-height: calc(100dvh - var(--webinar-bottom) - 1rem);
    overflow: auto;
    padding: 1.25rem;
    border: 1px solid #e9a990;
    border-top: .25rem solid #b14e38;
    border-radius: 1rem;
    background: linear-gradient(145deg, #fff6ec, #ffe0ce);
    color: #42251f;
    box-shadow: 0 .75rem 2rem rgb(42 24 19 / 28%);
}

.webinar-dialog[hidden] {
    display: none;
}

.webinar-dialog-close {
    position: absolute;
    top: .5rem;
    right: .5rem;
    display: grid;
    width: 2.75rem;
    height: 2.75rem;
    place-items: center;
    border-radius: 50%;
    color: #602c24;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}

.webinar-dialog-close:hover {
    background: #f5c6b2;
}

.webinar-dialog-eyebrow {
    margin: 0 2.75rem .5rem 0;
    color: #843929;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.webinar-dialog h2 {
    margin: 0;
    padding-right: .75rem;
    color: #42251f;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    line-height: 1.25;
    letter-spacing: normal;
}

.webinar-dialog-description {
    margin: .5rem 0 .9rem;
    color: #56342b;
    font-size: .95rem;
    line-height: 1.4;
}

.webinar-dialog .button {
    min-height: 2.75rem;
    padding: .5rem .875rem;
    border-color: #7b3327;
    background: #7b3327;
    color: #fff;
    font-size: .9rem;
}

.webinar-dialog .button:hover {
    border-color: #60251d;
    background: #60251d;
    color: #fff;
}

.webinar-dialog :is(button, a):focus-visible {
    outline: 2px solid #7b3327;
    outline-offset: 3px;
}

@media (max-width: 35rem) {
    .webinar-dialog {
        --webinar-right: max(.75rem, env(safe-area-inset-right));
        --webinar-left: max(.75rem, env(safe-area-inset-left));
        --webinar-bottom: max(.75rem, env(safe-area-inset-bottom));
        width: min(19rem, 100% - var(--webinar-right) - var(--webinar-left));
        padding: .875rem 1rem 1rem;
    }

    .webinar-dialog h2 {
        padding-right: 1.75rem;
        font-size: 1.1rem;
    }

    .webinar-dialog-description {
        margin-bottom: .75rem;
        font-size: .875rem;
    }

    .webinar-dialog .button {
        width: 100%;
        justify-content: space-between;
    }
}

@media (prefers-reduced-motion: no-preference) {
    .webinar-dialog:not([hidden]) {
        transform-origin: bottom right;
        animation: webinar-promo-enter 720ms cubic-bezier(.22, .75, .25, 1) 300ms both;
    }
}

@keyframes webinar-promo-enter {
    from {
        visibility: hidden;
        opacity: 0;
        transform: translateY(3rem) scale(.94);
    }

    1% {
        visibility: visible;
    }

    75% {
        opacity: 1;
        transform: translateY(-.25rem) scale(1);
    }

    to {
        visibility: visible;
        opacity: 1;
        transform: none;
    }
}
