:root {
    --page-popup-accent: var(--button-color-accent-buttton-accent-background-default-color, #f59c00);
    --page-popup-accent-hover: var(--button-color-accent-buttton-accent-background-hover-color, #f7ad2c);
    --page-popup-ink: var(--text-text-headline-color-dark, #303030);
    --page-popup-paper: var(--background-background-default, #fcfcfc);
    --page-popup-panel: var(--background-background-accent, #f3f3f3);
    --page-popup-line: var(--background-background-line-accent, #dce0e4);
    --page-popup-backdrop: rgb(17 20 22 / 58%);
    --page-popup-max-width: 71.5rem;
    --page-popup-ease: cubic-bezier(.22, 1, .36, 1);
}

.page-popup-is-open {
    overflow: hidden;
}

.page-popup {
    position: fixed;
    z-index: 1990;
    inset: 0;
    box-sizing: border-box;
    width: min(calc(100% - 2rem), var(--page-popup-max-width));
    max-width: none;
    max-height: min(90dvh, 48rem);
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--page-popup-ink);
    font-family: var(--typeface-family-text, Inter, sans-serif);
    overflow: visible;
}

.page-popup__backdrop {
    position: fixed;
    z-index: 1980;
    inset: 0;
    background: var(--page-popup-backdrop);
    animation: page-popup-backdrop-in 260ms ease-out both;
}

.page-popup__backdrop[hidden] {
    display: none;
}

.page-popup[open] {
    animation: page-popup-in 420ms var(--page-popup-ease) both;
}

.page-popup__surface {
    position: relative;
    display: grid;
    width: 100%;
    height: 30.75rem;
    box-sizing: border-box;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 1.125rem 1.25rem;
    gap: .75rem;
    border: .125rem solid var(--page-popup-line);
    border-radius: 1.25rem;
    background: var(--page-popup-paper);
    box-shadow: 0 1.5rem 5rem rgb(0 0 0 / 28%);
    overflow: hidden;
}

.page-popup--without-image {
    max-width: 36.6875rem;
}

.page-popup--without-image .page-popup__surface {
    grid-template-columns: minmax(0, 1fr);
}

.page-popup__close {
    position: absolute;
    z-index: 2;
    top: 2.625rem;
    right: 2.875rem;
    display: flex;
    width: 1.875rem;
    height: 1.875rem;
    box-sizing: border-box;
    align-items: center;
    justify-content: center;
    padding: .375rem;
    border: .0625rem solid var(--button-color-primary-buttton-primary-outline-default-color, #303030);
    border-radius: .875rem;
    background: var(--button-color-primary-buttton-primary-background-default-color, #fcfcfc);
    cursor: pointer;
    transition: background-color 180ms ease, border-color 180ms ease;
}

.page-popup__close img {
    display: block;
    width: 1rem;
    height: 1rem;
}

.page-popup__close:hover {
    border-color: var(--button-color-primary-buttton-primary-outline-hover-color, #535f6c);
    background: var(--button-color-primary-buttton-primary-background-hover-color, #f3f3f3);
}

.page-popup__close:active {
    border-color: var(--button-color-primary-primary-outline-active-color, #535f6c);
    background: var(--button-color-primary-buttton-primary-background-active-color, #f3f3f3);
}

.page-popup__cta:focus-visible,
.page-popup__secondary-link:focus-visible {
    outline: .1875rem solid var(--page-popup-ink);
    outline-offset: .1875rem;
}

.page-popup__close:focus,
.page-popup__close:focus-visible {
    outline: none;
}

.page-popup__close:focus-visible {
    border-color: var(--button-color-primary-buttton-primary-outline-hover-color, #535f6c);
    background: var(--button-color-primary-buttton-primary-background-hover-color, #f3f3f3);
}

.page-popup__media,
.page-popup__figure,
.page-popup__figure picture {
    min-width: 0;
    min-height: 0;
    height: 100%;
    margin: 0;
    overflow: hidden;
    border-radius: 1.25rem;
}

.page-popup__image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: left center;
}

.page-popup__body {
    display: flex;
    min-width: 0;
    min-height: 0;
    box-sizing: border-box;
    align-items: center;
    flex-direction: column;
    justify-content: center;
    padding: 2.5rem;
    border: .125rem solid rgb(9 58 230 / 5%);
    border-radius: 1.25rem;
    background: var(--page-popup-panel);
    text-align: center;
}

.page-popup__title {
    width: 26.625rem;
    max-width: 100%;
    margin: 0;
    color: var(--page-popup-ink);
    font-family: var(--typeface-family-heading, Calibri, sans-serif);
    font-size: var(--typeface-size-2xl, 2.5rem);
    font-weight: var(--typeface-weight-bold, 700);
    line-height: var(--typeface-line-height-2xl, 2.875rem);
    overflow-wrap: break-word;
    text-wrap: balance;
}

.page-popup__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    margin-top: .75rem;
    gap: .5rem 1.6875rem;
    color: var(--page-popup-ink);
    font-size: var(--typeface-size-xs, .875rem);
    font-weight: var(--typeface-weight-regular, 400);
    line-height: var(--typeface-line-height-xs, 1.25rem);
}

.page-popup__meta-item {
    display: inline-flex;
    min-width: 0;
    align-items: center;
    gap: .25rem;
}

.page-popup__meta-item img,
.page-popup__secondary-link img {
    display: block;
    width: 1rem;
    height: 1rem;
    flex: 0 0 1rem;
}

.page-popup__lead {
    width: 25.9375rem;
    max-width: 100%;
    margin: 1.25rem 0 0;
    color: var(--page-popup-ink);
    font-size: var(--typeface-size-s, 1rem);
    font-weight: var(--typeface-weight-semi-bold, 600);
    line-height: var(--typeface-line-height-s, 1.375rem);
}

.page-popup__text {
    width: 25.9375rem;
    max-width: 100%;
    margin-top: .5rem;
    color: var(--page-popup-ink);
    font-size: var(--typeface-size-xs, .875rem);
    font-weight: var(--typeface-weight-regular, 400);
    line-height: var(--typeface-line-height-xs, 1.25rem);
}

.page-popup__text > :first-child {
    margin-top: 0;
}

.page-popup__text > :last-child {
    margin-bottom: 0;
}

.page-popup__cta {
    display: inline-flex;
    min-height: 3rem;
    box-sizing: border-box;
    align-items: center;
    justify-content: center;
    margin-top: 1.5rem;
    padding: .125rem .75rem;
    border: var(--d-0-2-4, .0625rem) solid var(--button-color-accent-buttton-accent-outline-default-color, #f59c00);
    border-radius: var(--d-2-5, .625rem);
    background: var(--page-popup-accent);
    color: var(--button-text-accent-button-accent-text-default-color, #393d40);
    font-size: var(--typeface-size-s, 1rem);
    font-weight: var(--typeface-weight-regular, 400);
    line-height: var(--typeface-line-height-s, 1.375rem);
    text-decoration: none;
    transition: background-color 180ms ease, transform 180ms var(--page-popup-ease);
}

.page-popup__cta:hover {
    background: var(--page-popup-accent-hover);
    color: var(--button-text-accent-button-accent-text-hover-color, #393d40);
}

.page-popup__cta:active {
    background: var(--button-color-accent-buttton-accent-background-active-color, #f59c00);
    transform: scale(.99);
}

.page-popup__secondary-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: .75rem;
    color: var(--page-popup-ink);
    font-size: var(--typeface-size-xs, .875rem);
    font-weight: var(--typeface-weight-regular, 400);
    line-height: var(--typeface-line-height-xs, 1.25rem);
    text-decoration: none;
}

.page-popup__secondary-link img {
    transition: transform 180ms var(--page-popup-ease);
}

.page-popup__secondary-link:hover {
    color: var(--page-popup-ink);
}

.page-popup__secondary-link:hover img {
    transform: translateX(.25rem);
}

@keyframes page-popup-in {
    from {
        opacity: 0;
        transform: translateY(1.5rem) scale(.975);
    }
}

@keyframes page-popup-backdrop-in {
    from { opacity: 0; }
}

@media (max-width: 53.75rem) {
    .page-popup {
        width: min(calc(100% - 1.75rem), 22.8125rem);
        max-height: calc(100dvh - 1rem);
        overflow-x: hidden;
        overflow-y: auto;
    }

    .page-popup__surface {
        display: flex;
        width: 100%;
        height: auto;
        min-height: 34.625rem;
        flex-direction: column;
        padding: 1.125rem;
        gap: .75rem;
        border-radius: 1.25rem;
        background: var(--page-popup-panel);
    }

    .page-popup__media {
        width: 100%;
        height: 10.75rem;
        flex: 0 0 10.75rem;
    }

    .page-popup__image {
        object-position: center;
    }

    .page-popup__body {
        width: calc(100% + .125rem);
        min-height: 20.625rem;
        margin-inline: -.0625rem;
        flex: 1 0 20.625rem;
        justify-content: flex-start;
        padding: .75rem;
        border: 0;
        background: transparent;
    }

    .page-popup__title {
        width: 26.625rem;
        max-width: none;
        font-size: var(--typeface-size-xl, 2rem);
        line-height: var(--typeface-line-height-xl, 2.375rem);
    }

    .page-popup__close {
        top: 1.75rem;
        right: 2.25rem;
    }

    .page-popup__meta {
        align-items: center;
        flex-direction: column;
        margin-top: .75rem;
        gap: .5rem;
        opacity: .8;
    }

    .page-popup__lead {
        margin-top: 1.5rem;
        opacity: .8;
    }

    .page-popup__text {
        display: none;
    }

    .page-popup__cta {
        min-height: 2.5rem;
        margin-top: 1.125rem;
        font-size: var(--typeface-size-xs, .875rem);
        line-height: var(--typeface-line-height-xs, 1.25rem);
    }

    .page-popup--without-image .page-popup__surface {
        min-height: 24rem;
    }

    .page-popup--without-image .page-popup__body {
        min-height: 21.5rem;
    }

    .page-popup--without-image .page-popup__close {
        top: 1.75rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .page-popup,
    .page-popup__backdrop,
    .page-popup__close,
    .page-popup__cta,
    .page-popup__secondary-link img {
        animation: none;
        scroll-behavior: auto;
        transition: none;
    }
}

/* SCHROTH theme */
:root {
    --page-popup-accent: #ffdc05;
    --page-popup-accent-hover: #fff19e;
    --page-popup-ink: #3c3c3c;
    --page-popup-paper: #fff;
    --page-popup-panel: #f4f4f4;
    --page-popup-line: #3c3c3c;
    --page-popup-backdrop: rgb(0 0 0 / 78%);
}

.page-popup {
    font-family: paralucent, Arial, sans-serif;
}

.page-popup__surface {
    padding: .75rem;
    gap: .75rem;
    border: 0;
    border-radius: 0;
    box-shadow: 0 1.5rem 4rem rgb(0 0 0 / 35%);
}

.page-popup__media,
.page-popup__figure,
.page-popup__figure picture,
.page-popup__body {
    border-radius: 0;
}

.page-popup__body {
    border: 0;
    background: var(--page-popup-panel);
}

.page-popup__title {
    font-family: "interstate-mono", monospace, sans-serif;
    font-size: 2rem;
    font-weight: 800;
    line-height: 1.2;
    text-transform: uppercase;
}

.page-popup__close {
    top: 1.5rem;
    right: 1.5rem;
    width: 2.5rem;
    height: 2.5rem;
    padding: .6875rem;
    border: 0;
    border-radius: 0;
    background: var(--page-popup-accent);
}

.page-popup__close:hover,
.page-popup__close:focus-visible {
    background: var(--page-popup-accent-hover);
}

.page-popup__close:focus-visible,
.page-popup__cta:focus-visible,
.page-popup__secondary-link:focus-visible {
    outline: .1875rem solid var(--page-popup-ink);
    outline-offset: .1875rem;
}

.page-popup__cta {
    border-color: var(--page-popup-accent);
    border-radius: 0;
    background: var(--page-popup-accent);
    color: var(--page-popup-ink);
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.page-popup__cta:hover {
    background: var(--page-popup-accent-hover);
}

.page-popup__secondary-link {
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: .2em;
}

/* A popup without editorial content is a clean, responsive image lightbox. */
.page-popup--image-only {
    width: min(26.5625rem, calc(100% - 5.5rem));
    max-width: none;
    overflow: visible;
}

.page-popup--image-only .page-popup__surface {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    min-height: 0;
    max-height: 90dvh;
    padding: 0;
    background: transparent;
    box-shadow: 0 1.5rem 4rem rgb(0 0 0 / 40%);
    overflow: visible;
}

.page-popup--image-only .page-popup__media,
.page-popup--image-only .page-popup__figure,
.page-popup--image-only .page-popup__figure picture {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    max-height: calc(90dvh - .25rem);
    flex: none;
}

.page-popup--image-only .page-popup__image {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    max-height: calc(90dvh - .25rem);
    object-fit: contain;
    object-position: center;
}

.page-popup--image-only .page-popup__close {
    top: 0;
    right: -3rem;
}

@media (max-width: 53.75rem) {
    .page-popup__surface {
        border-radius: 0;
    }

    .page-popup__text {
        display: block;
    }

    .page-popup__title {
        font-size: 1.65rem;
        line-height: 1.2;
    }

    .page-popup--image-only {
        width: calc(100% - 6rem);
        max-width: 26.5625rem;
        overflow: visible;
    }

    .page-popup--image-only .page-popup__surface {
        min-height: 0;
    }
}
