/*
 * Selectors are doubled up with the .bmcr root on purpose: the theme and the
 * Elementor kit style bare inputs and buttons with higher specificity than a
 * single class.
 */

.bmcr {
    --bmcr-accent: var(--e-global-color-secondary, #3fa6ad);
    --bmcr-text: var(--e-global-color-text, #414141);
    --bmcr-field-background: #d9d9d9;
    --bmcr-placeholder: rgba(65, 65, 65, 0.66);
    --bmcr-error: #b3261e;

    color: var(--bmcr-text);
    font-family: var(--e-global-typography-text-font-family, "Poppins"), sans-serif;
    font-size: 1.1rem;
    line-height: 1.5;
}

.bmcr [hidden] {
    display: none !important;
}

.bmcr .bmcr-field {
    margin: 0 0 30px;
    padding: 5px 0;
}

/* The placeholder acts as the visible label; this one is for screen readers. */
.bmcr .bmcr-label {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

.bmcr .bmcr-input {
    display: block;
    box-sizing: border-box;
    width: 100%;
    min-height: 42px;
    margin: 0;
    padding: 8px 16px;
    border: 0;
    border-radius: 25px;
    background-color: var(--bmcr-field-background);
    box-shadow: none;
    color: #000;
    font: inherit;
}

.bmcr .bmcr-input::placeholder {
    color: var(--bmcr-placeholder);
    opacity: 1;
}

.bmcr select.bmcr-input:invalid {
    color: var(--bmcr-placeholder);
}

.bmcr select.bmcr-input option {
    color: #000;
}

.bmcr .bmcr-input:focus-visible,
.bmcr .bmcr-checkbox input:focus-visible,
.bmcr .bmcr-submit:focus-visible,
.bmcr .bmcr-back-button:focus-visible {
    outline: 2px solid var(--bmcr-accent);
    outline-offset: 2px;
}

.bmcr .bmcr-input[aria-invalid="true"] {
    box-shadow: inset 0 0 0 2px var(--bmcr-error);
}

.bmcr .bmcr-error {
    margin: 6px 16px 0;
    color: var(--bmcr-error);
    font-size: 0.8em;
}

.bmcr .bmcr-hp {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.bmcr .bmcr-note {
    margin: 0 0 14px;
    font-size: 0.85em;
}

.bmcr .bmcr-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    /* The theme sets line-height 1 on labels, which squeezes wrapped lines. */
    line-height: 1.5;
    cursor: pointer;
}

.bmcr .bmcr-checkbox input {
    flex: none;
    width: 16px;
    height: 16px;
    margin: 0.3em 0 0;
    accent-color: var(--e-global-color-primary, #363887);
}

.bmcr .bmcr-checkbox a {
    color: inherit;
    text-decoration: underline;
}

.bmcr .bmcr-field--checkbox .bmcr-error {
    margin-left: 26px;
}

.bmcr .bmcr-message {
    margin: 0 0 20px;
    padding: 12px 16px;
    border-radius: 12px;
    background-color: #fdecea;
    color: var(--bmcr-error);
}

.bmcr .bmcr-submit,
.bmcr .bmcr-back-button {
    display: inline-block;
    margin: 0;
    padding: 20px 35px;
    border: 2px solid var(--bmcr-accent);
    border-radius: 50px;
    background-color: transparent;
    color: var(--bmcr-text);
    font: inherit;
    cursor: pointer;
    transition: background-color 0.3s, border-color 0.3s, color 0.3s;
}

.bmcr .bmcr-submit:hover,
.bmcr .bmcr-submit:focus,
.bmcr .bmcr-back-button:hover,
.bmcr .bmcr-back-button:focus {
    border-color: var(--bmcr-accent);
    background-color: var(--bmcr-accent);
    color: #fff;
}

.bmcr .bmcr-submit[disabled] {
    opacity: 0.6;
    cursor: progress;
}

.bmcr .bmcr-back {
    margin: 0 0 30px;
}

.bmcr .bmcr-back-button {
    padding: 12px 25px;
}

.bmcr .bmcr-success:focus {
    outline: none;
}

.bmcr .bmcr-success-title {
    margin: 0 0 12px;
}

.bmcr .bmcr-success-text {
    margin: 0 0 30px;
}

/*
 * Inside the app the page is shown edge to edge, so it has to keep clear of
 * notch, status bar and home indicator itself. The app provides the top and
 * bottom insets as custom properties; env() is the fallback.
 */
html.bmcr-is-app body {
    padding-top: var(--safe-area-inset-top, env(safe-area-inset-top, 0px));
    padding-right: env(safe-area-inset-right, 0px);
    padding-bottom: var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px));
    padding-left: env(safe-area-inset-left, 0px);
}
