/* ============================================================================
   06-COMPONENTS -> #FORM-TEXT
   ========================================================================= */

/**
 * Prefixes an input with an additional label.
 */


//
// SCSS imports
//

@use '../01-settings' as *;
@use '../02-tools' as *;


/**
 * Form text
 */

.form-text {
    --form-text-bg: var(--bg-tertiary);
    --form-text-border-color: var(--form-input-border-color);
    --form-text-border-radius: var(--form-input-border-radius);
    --form-text-border-width: var(--form-input-border-width);
    --form-text-color: var(--form-input-color);
    --form-text-padding-x: var(--form-input-padding-x);
    --form-text-padding-y: var(--form-input-padding-y);

    align-items: center;
    background-color: var(--form-text-bg);
    border: var(--form-text-border-width) solid var(--form-text-border-color);
    border-bottom-left-radius: var(--form-text-border-radius);
    border-top-left-radius: var(--form-text-border-radius);
    color: var(--form-text-color);
    display: flex;
    padding: var(--form-input-padding-y) var(--form-input-padding-x);
    user-select: none;

    & + .input,
    & + .select {
        border-bottom-left-radius: 0;
        border-top-left-radius: 0;
        flex: 1 1 auto;
        margin-left: calc(var(--form-input-border-width) * -1);
        min-width: 0;
        width: 1%;
    }
}