/* PBJ V4.0.1 — Global Number & Currency Formatter */
.pbj-number-shell {
    position: relative;
    display: block;
    width: 100%;
    min-width: 0;
}

.pbj-number-shell > .pbj-number-raw {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    width: 1px !important;
    height: 1px !important;
    min-width: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
    overflow: hidden !important;
    z-index: -1 !important;
}

.pbj-number-display {
    width: 100%;
    font-variant-numeric: tabular-nums;
    letter-spacing: .01em;
}

.pbj-number-display.pbj-number-invalid {
    border-color: #c62828 !important;
    box-shadow: 0 0 0 2px rgba(198, 40, 40, .10) !important;
}

.pbj-number-popover {
    position: fixed;
    z-index: 10050;
    max-width: min(340px, calc(100vw - 16px));
    padding: 7px 10px;
    border: 1px solid #b8d5e8;
    border-radius: 8px;
    background: #083b68;
    color: #fff;
    box-shadow: 0 8px 22px rgba(7, 36, 61, .20);
    font-size: 11px;
    font-weight: 700;
    line-height: 1.35;
    pointer-events: none;
}

.pbj-number-popover.is-error {
    border-color: #e4a4a4;
    background: #9e1b1b;
}

.pbj-number-popover[hidden] {
    display: none !important;
}

html[data-theme="dark"] .pbj-number-popover {
    border-color: #315f82;
    background: #0d2f4c;
}

/* Table / compact forms keep the proxy from overflowing its cell. */
td .pbj-number-shell,
.form-grid .pbj-number-shell,
.simple-form-grid .pbj-number-shell,
.pbj-form-grid .pbj-number-shell,
.compact-form .pbj-number-shell {
    max-width: 100%;
}
