.registration-extra-overlay {
    position: fixed !important;
    inset: 0 0 var(--bottom-nav-height, 0) 0 !important;
    width: 100vw !important;
    height: calc(100dvh - var(--bottom-nav-height, 0)) !important;
    display: flex !important;
    align-items: stretch !important;
    padding: 0 !important;
    background: #FFFFFF !important;
    z-index: 2147483000 !important;
    overflow: hidden !important;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.registration-extra-overlay.is-visible {
    opacity: 1;
}

.registration-extra-popup {
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    display: flex !important;
    flex-direction: column !important;
    background: #FFFFFF !important;
    overflow: hidden !important;
}

.registration-extra-popup__header {
    position: relative;
    flex: none;
    padding: 34px 56px 20px 24px;
    border-bottom: 0;
}

.registration-extra-popup__title {
    margin: 0;
    font-size: 20px !important;
    font-weight: 700;
    line-height: 1.2;
    color: #161821;
}

.registration-extra-popup__text {
    margin: 8px 0 0;
    font-size: 14px;
    line-height: 1.45;
    color: #6E7280;
}

.registration-extra-popup__close {
    width: 36px;
    height: 36px;
    position: absolute;
    top: 30px;
    right: 16px;
    border: 0;
    border-radius: 0;
    outline: none !important;
    background: transparent;
    color: #161821;
    font-size: 40px;
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.registration-extra-popup__close:focus,
.registration-extra-popup__close:focus-visible {
    outline: none !important;
    box-shadow: none !important;
}

.registration-extra-popup__form {
    min-height: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.registration-extra-popup__fields {
    min-height: 0;
    flex: 1;
    display: grid;
    align-content: start;
    gap: 16px;
    padding: 8px 24px 16px;
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
}

.registration-extra-field {
    display: grid;
    gap: 6px;
}

.registration-extra-field__label {
    font-size: 14px;
    font-weight: 600;
    line-height: 120%;
    color: #282B35;
}

.registration-extra-field__required {
    margin-left: 3px;
    color: #90278E;
}

.registration-extra-field input,
.registration-extra-field select,
.registration-extra-select__button {
    width: 100%;
    height: 56px;
    min-height: 56px;
    box-sizing: border-box;
    padding: 16px;
    border: 0;
    border-radius: 12px;
    outline: none;
    background: #F2F4F8;
    color: #161821;
    font: inherit;
    font-size: 18px !important;
    font-weight: 400;
    line-height: 24px;
    appearance: none;
    -webkit-appearance: none;
    max-width: 100%;
}

.registration-extra-select__button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    cursor: pointer;
}

.registration-extra-select__button::after {
    width: 9px;
    height: 9px;
    content: "";
    flex: none;
    margin-left: 12px;
    border-right: 2px solid #777777;
    border-bottom: 2px solid #777777;
    transform: rotate(45deg);
}

.registration-extra-select__button.is-placeholder {
    color: #828282;
}

.registration-extra-field input:focus,
.registration-extra-field select:focus {
    box-shadow: 0 0 0 2px rgba(144, 39, 142, 0.18);
}

.registration-extra-children {
    display: grid;
    gap: 10px;
}

.registration-extra-children__list {
    display: grid;
    gap: 8px;
}

.registration-extra-child {
    display: grid;
    grid-template-columns: 1fr 150px 36px;
    gap: 10px;
    align-items: center;
}

.registration-extra-child__remove {
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: #F2F4F8;
    color: #4B4F5C;
    font-size: 22px;
    cursor: pointer;
}

.registration-extra-child__add {
    justify-self: start;
    border: 0;
    padding: 4px 0;
    background: transparent;
    color: #90278E;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.registration-extra-popup__error {
    min-height: 18px;
    margin: 0;
    padding: 0 24px;
    color: #D62845;
    font-size: 13px;
}

.registration-extra-popup__actions {
    flex: none;
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 8px 24px 24px;
    border-top: 0;
    background: #FFFFFF;
}

.registration-extra-popup__button {
    width: 100%;
    min-height: 56px;
    border: 0;
    border-radius: 12px;
    padding: 16px;
    font: inherit;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
}

.registration-extra-popup__button--later {
    background: #F2F4F8;
    color: #333640;
}

.registration-extra-popup__button--submit {
    background: #90278E;
    color: #FFFFFF;
}

.registration-extra-popup__button:disabled {
    cursor: wait;
    opacity: 0.58;
}

body:has(.registration-extra-overlay) {
    overflow: hidden;
}

body.theme-dark .registration-extra-popup {
    background: #0A0C14 !important;
    color: #FFFFFF;
}

body.theme-dark .registration-extra-overlay {
    background: #0A0C14 !important;
}

body.theme-dark .registration-extra-popup__header {
    border-color: rgba(255, 255, 255, 0.12);
}

body.theme-dark .registration-extra-popup__actions {
    border-color: rgba(255, 255, 255, 0.12);
    background: #0A0C14;
}

body.theme-dark .registration-extra-popup__title,
body.theme-dark .registration-extra-field__label {
    color: #FFFFFF;
}

body.theme-dark .registration-extra-popup__text {
    color: rgba(255, 255, 255, 0.66);
}

body.theme-dark .registration-extra-popup__close,
body.theme-dark .registration-extra-child__remove,
body.theme-dark .registration-extra-popup__button--later {
    color: #FFFFFF;
}

body.theme-dark .registration-extra-popup__button--later {
    background: #1A2030;
}

body.theme-dark .registration-extra-field input,
body.theme-dark .registration-extra-field select,
body.theme-dark .registration-extra-select__button {
    background: #111522;
    color: #FFFFFF;
}

.registration-extra-sheet {
    position: fixed;
    inset: 0 0 var(--bottom-nav-height, 0) 0;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 0 16px 16px;
    background: rgba(0, 0, 0, 0.42);
    z-index: 2147483001;
}

.registration-extra-sheet__panel {
    width: 100%;
    max-width: 540px;
    overflow: hidden;
    border-radius: 24px;
    background: #FFFFFF;
    box-shadow: 0 -12px 32px rgba(0, 0, 0, 0.16);
}

.registration-extra-sheet__title {
    padding: 18px 20px 10px;
    font-size: 16px;
    font-weight: 700;
    color: #282B35;
}

.registration-extra-sheet__option {
    width: 100%;
    min-height: 54px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 0;
    border-top: 1px solid #ECEEF3;
    padding: 14px 20px;
    background: transparent;
    color: #161821;
    font: inherit;
    font-size: 18px;
    text-align: left;
}

.registration-extra-sheet__option.is-selected::after {
    content: "";
    width: 10px;
    height: 18px;
    border-right: 3px solid #90278E;
    border-bottom: 3px solid #90278E;
    transform: rotate(45deg);
}

.registration-extra-sheet__cancel {
    width: 100%;
    min-height: 54px;
    border: 0;
    border-top: 8px solid #F2F4F8;
    background: #FFFFFF;
    color: #90278E;
    font: inherit;
    font-size: 16px;
    font-weight: 600;
}

body.theme-dark .registration-extra-sheet__panel,
body.theme-dark .registration-extra-sheet__cancel {
    background: #111522;
}

body.theme-dark .registration-extra-sheet__title,
body.theme-dark .registration-extra-sheet__option {
    color: #FFFFFF;
}

body.theme-dark .registration-extra-sheet__option {
    border-color: rgba(255, 255, 255, 0.12);
}

@media screen and (max-width: 600px) {
    .registration-extra-popup__header {
        padding-top: 34px;
    }

    .registration-extra-popup__title {
        font-size: 20px !important;
    }

    .registration-extra-popup__fields,
    .registration-extra-popup__actions {
        padding-left: 24px;
        padding-right: 24px;
    }

    .registration-extra-field input,
    .registration-extra-field select,
    .registration-extra-select__button {
        min-width: 0;
        width: 100%;
        font-size: 18px !important;
    }

    .registration-extra-child {
        grid-template-columns: 1fr 44px;
    }

    .registration-extra-child input[type="date"] {
        grid-column: 1 / -1;
        grid-row: 2;
    }

    .registration-extra-child__remove {
        grid-column: 2;
        grid-row: 1;
    }
}
