:root {
    --pn-button-size: 56px;
    --pn-button-offset-x: 24px;
    --pn-button-offset-y: 24px;
    --pn-button-active-stroke: #ffffff;
    --pn-button-active-stroke-width: 3px;
    --pn-button-active-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
    --pn-popover-bg: #eae7e2;
    --pn-popover-radius: 0.625rem;
    --pn-popover-padding: 1.75rem 2rem;
    --pn-popover-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
    --pn-popover-max-width: 360px;
    --pn-popover-gap: 18px;
    --pn-popover-arrow-size: 12px;
    --pn-popover-z: 99999;
}

.pn-notification {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pn-notification[hidden] {
    display: none;
}

.pn-notification__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
}

.pn-notification__box {
    position: relative;
    z-index: 1;
    border-radius: 0.625rem;
    background: #eae7e2;
    padding: 2.5rem 2.875rem;
    max-width: 600px;
    width: auto;
    max-height: 85vh;
    overflow-x: hidden;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
    box-sizing: border-box;
}

.pn-notification__close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 2rem;
    height: 2rem;
    border: 0;
    background: transparent;
    font-size: 1.75rem;
    line-height: 1;
    cursor: pointer;
    color: inherit;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.15s ease;
}

.pn-notification__close:hover,
.pn-notification__close:focus {
    background: rgba(0, 0, 0, 0.08);
    outline: none;
}

.pn-notification__title {
    font-size: 1.5rem;
    margin: 0 0 1rem;
    padding-right: 2rem;
}

.pn-notification__content {
    font-size: 1rem;
    line-height: 1.5;
}

.pn-notification__content :last-child {
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .pn-notification__box {
        max-width: 90vw;
        max-height: 80vh;
        overflow-x: hidden;
        overflow-y: scroll;
        padding: 2rem 1.5rem;
    }
}

/* ---------- Button mode ---------- */

.pn-notification.pn-notification--button {
    position: fixed;
    top: auto;
    left: auto;
    right: var(--pn-button-offset-x);
    bottom: var(--pn-button-offset-y);
    inset: auto var(--pn-button-offset-x) var(--pn-button-offset-y) auto;
    z-index: var(--pn-popover-z);
    width: var(--pn-button-size);
    height: var(--pn-button-size);
    display: block;
    align-items: initial;
    justify-content: initial;
    pointer-events: none;
}

.pn-notification.pn-notification--button > * {
    pointer-events: auto;
}

.pn-trigger {
    position: relative;
    width: var(--pn-button-size);
    height: var(--pn-button-size);
    padding: 0;
    margin: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    border-radius: 50%;
    line-height: 0;
    display: block;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.pn-trigger:focus {
    outline: none;
}

.pn-trigger svg {
    display: block;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.pn-trigger.is-active {
    box-shadow:
        0 0 0 var(--pn-button-active-stroke-width) var(--pn-button-active-stroke),
        var(--pn-button-active-shadow);
}

.pn-popover {
    position: absolute;
    bottom: calc(100% + var(--pn-popover-gap));
    right: 0;
    background: var(--pn-popover-bg);
    border-radius: var(--pn-popover-radius);
    padding: var(--pn-popover-padding);
    box-shadow: var(--pn-popover-shadow);
    width: max-content;
    max-width: var(--pn-popover-max-width);
    box-sizing: border-box;
}

.pn-popover[hidden] {
    display: none;
}

.pn-popover::after {
    content: "";
    position: absolute;
    top: 100%;
    right: calc(var(--pn-button-size) / 2 - var(--pn-popover-arrow-size));
    width: 0;
    height: 0;
    border: var(--pn-popover-arrow-size) solid transparent;
    border-top-color: var(--pn-popover-bg);
    border-bottom: 0;
    pointer-events: none;
}

.pn-popover .pn-notification__title {
    font-size: 1.25rem;
    margin: 0 0 0.75rem;
    padding-right: 2rem;
}

.pn-popover .pn-notification__content {
    font-size: 1rem;
    line-height: 1.5;
}

.pn-popover .pn-notification__content :last-child {
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .pn-popover {
        max-width: calc(100vw - var(--pn-button-offset-x) * 2);
    }
}
