.welcome-modal {
    position: fixed;
    inset: 0;
    z-index: calc(var(--z-index-modal-layout, 1000) + 2);
    display: grid;
    place-items: center;
    padding: 20px;
    pointer-events: none;
}

.welcome-modal.is-hidden,
.welcome-modal[hidden] {
    display: none !important;
}

.welcome-modal.is-open {
    pointer-events: auto;
}

.welcome-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(5, 4, 14, 0.82);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    opacity: 0;
    transition: opacity 320ms ease;
}

.welcome-modal.is-open .welcome-modal__backdrop {
    opacity: 1;
}

.welcome-modal__panel {
    position: relative;
    z-index: 1;
    width: min(420px, calc(100vw - 32px));
    padding: 32px 28px 28px;
    border-radius: 20px;
    background: #fff;
    border: 1px solid rgba(20, 23, 68, 0.1);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.28);
    color: #141744;
    --color-content-base-primary: #141744;
    overflow: hidden;
    opacity: 0;
    transform: translate3d(0, 14px, 0) scale(0.92);
    transform-origin: center center;
    transition:
        opacity 300ms cubic-bezier(.22, 1, .36, 1),
        transform 300ms cubic-bezier(.22, 1, .36, 1);
}

.welcome-modal.is-open .welcome-modal__panel {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
}

.welcome-modal.is-leaving .welcome-modal__panel {
    opacity: 0;
    transform: translate3d(0, 8px, 0) scale(0.94);
    transition-duration: 180ms;
}

.welcome-modal.is-leaving .welcome-modal__backdrop {
    opacity: 0;
    transition-duration: 200ms;
}

.welcome-modal__glow {
    display: none;
}

.welcome-modal__close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 6px;
    background: rgba(20, 23, 68, 0.06);
    color: #3d4566;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 160ms ease, color 160ms ease;
}

.welcome-modal__close:hover {
    background: rgba(20, 23, 68, 0.1);
    color: #141744;
}

.welcome-modal__brand {
    display: flex;
    margin-bottom: 18px;
}

.welcome-modal__brand .p101-logo,
.welcome-modal__brand .p101-logo__word {
    font-size: 28px;
    line-height: 1;
}

.welcome-modal__title {
    margin: 0 0 10px;
    font-family: var(--font-headline-font-family, inherit);
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.welcome-modal__text {
    margin: 0 0 24px;
    color: #3d4566;
    font-size: 15px;
    line-height: 1.55;
}

.welcome-modal__actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.welcome-modal__btn {
    appearance: none;
    border: 0;
    border-radius: 6px;
    min-height: 44px;
    padding: 0 18px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: filter 160ms ease, background 160ms ease;
}

.welcome-modal__btn--primary {
    background: var(--color-solid-action-cta, #1e46eb);
    color: var(--color-content-base-on-primary, #fff);
}

.welcome-modal__btn--primary:hover {
    filter: brightness(1.05);
}

.welcome-modal__btn--ghost {
    background: rgba(20, 23, 68, 0.06);
    color: #141744;
}

.welcome-modal__btn--ghost:hover {
    background: rgba(20, 23, 68, 0.1);
}
