/* App-specific additions to the Wolbis theme.
   Kept separate so the vendor stylesheet (style.css) stays untouched. */

/* Full-width rows inside the two-column registration grid */
.regForm .formContent .formItem.wide {
    width: 100%;
}

.regForm .formContent .formItem.wide .btnContainer {
    transform: none;
}

/* Helper text under a field */
.formItem .fieldNote {
    margin-top: 6px;
    font-size: 12px;
    line-height: 16px;
    color: #868a9d;
}

/* Arithmetic captcha: question box next to the answer input */
.captchaQuestion {
    display: flex;
    align-items: center;
    gap: 12px;
}

.captchaQuestion .captchaSum {
    flex-shrink: 0;
    padding: 0 18px;
    height: 56px;
    display: flex;
    align-items: center;
    border-radius: 11px;
    background-color: #f0f0f0;
    font-size: 16px;
    font-weight: 500;
    color: #020b4e;
    white-space: nowrap;
    -webkit-user-select: none;
    user-select: none;
}

.captchaQuestion .inputContainer {
    flex: 1;
}

/* Account-type chips (multi-select) */
.accountTypes {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.accountTypes .typeChip input {
    display: none;
}

.accountTypes .typeChip label {
    display: inline-flex;
    align-items: center;
    padding: 9px 18px;
    border-radius: 999px;
    border: 1px solid #d5d8e2;
    font-size: 14px;
    line-height: 20px;
    color: #868a9d;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s, background-color 0.2s;
}

.accountTypes .typeChip label:hover {
    color: #020b4e;
    border-color: #868a9d;
}

.accountTypes .typeChip input:checked + label {
    border-color: #020b4e;
    background-color: #020b4e;
    color: #fff;
}

/* Recovery-code toggle on the 2FA challenge */
.authForm .linkToggle {
    margin-top: 14px;
    background: none;
    border: 0;
    padding: 0;
    font-size: 14px;
    color: #020b4e;
    text-decoration: underline;
    cursor: pointer;
}

/* Account insights panel: stack sections, spread the metrics across the row */
.insightsPanel .panelInner {
    display: block;
}

.insightsPanel .downStat {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-bottom: 18px;
}

.insightsPanel .downStat .paramItem {
    flex: 1 1 160px;
    display: block;
}

.insightsPanel .alert {
    margin-bottom: 10px;
}

/* Account insight meters on the investor dashboard */
.insightMeter {
    margin-top: 8px;
    height: 6px;
    border-radius: 6px;
    background: #eef1f6;
    overflow: hidden;
}

.insightMeter span {
    display: block;
    height: 6px;
    border-radius: 6px;
    background: #1d3f72;
}

/* Loading state for buttons and action links, and the post-registration notice */
.is-loading {
    pointer-events: none;
    opacity: .8;
}

.is-loading:not(.btnMain) {
    position: relative;
}

.is-loading:not(.btnMain) > * {
    visibility: hidden;
}

/* Theme buttons draw their background on .btnInner, so keep it and swap only
   the label for the spinner; the spinner takes the variant's text colour */
.btnMain.is-loading .btnInner {
    position: relative;
    -webkit-text-fill-color: transparent;
}

.btnMain.is-loading .btnInner::after,
.is-loading:not(.btnMain)::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 18px;
    height: 18px;
    margin: -9px 0 0 -9px;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    visibility: visible;
    animation: btnSpin .6s linear infinite;
}

.redirectNotice {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 16px 0;
}

.redirectNotice p {
    margin: 0;
}

.spinner {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    border: 2px solid #1d3f72;
    border-right-color: transparent;
    border-radius: 50%;
    animation: btnSpin .6s linear infinite;
}

@keyframes btnSpin {
    to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
    .is-loading::after,
    .spinner {
        animation-duration: 2s;
    }
}

/* Initials shown in place of a profile photo */
.avaInitials {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #1f4176;
    color: #fff;
    font-weight: 600;
    font-size: 15px;
    line-height: 1;
    letter-spacing: .02em;
}

.avaSettings .avaInitials {
    font-size: 34px;
}

.avaInitials[style*="background-image"] > span {
    display: none;
}

/* The theme hides these inputs with display:none, which stops the browser
   pointing at a required one that is empty; keep them invisible but focusable */
.proofUpload input[type=file],
.radioItem input,
.checkInput input {
    display: block;
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.proofUpload,
.radioItem,
.checkInput {
    position: relative;
}

.proofPicker {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 56px;
    padding: 8px 8px 8px 20px;
    border-radius: 11px;
    background-color: #f0f0f0;
    cursor: pointer;
}

.proofPicker .fileName {
    margin: 0;
    overflow: hidden;
    color: #868a9d;
    font-size: 15px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.proofBrowse {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 9px;
    background-color: #1f4176;
    color: #fff;
    font-size: 13px;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.proofPicker:hover .proofBrowse {
    background-color: #061927;
}

.proofUpload .preview {
    display: none;
    position: relative;
    height: 180px;
    margin-top: 12px;
    overflow: hidden;
    border-radius: 11px;
    background-color: #eef1f6;
}

.proofUpload .preview:has(.previewImage[style*="background-image"]) {
    display: block;
}

.proofUpload .previewImage {
    position: absolute;
    inset: 0;
    background: no-repeat center / contain;
}

/* Notifications: bulk actions and per-item delete */
.notificationActions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
}

.notificationDelete {
    position: absolute;
    top: 50%;
    right: 27px;
    transform: translateY(-50%);
}

.notificationDelete button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 9px;
    background-color: #dfe3f8;
    color: #1f4176;
    font-size: 16px;
    cursor: pointer;
    transition: background-color .2s, color .2s;
}

.notificationDelete button:hover {
    background-color: #e22f32;
    color: #fff;
}
