.text-input {
    position: relative;
    grid-column: span 4;
    /* padding-bottom: 22px; */
    margin-top: 20px;
    min-height: 49px;
}

.text-input textarea {
    margin: 0;
}

.text-input.full-span {
    grid-column: 1 / -1;
}

.text-input .input {
    background-color: transparent;
    width: 100%;
    border: none;
    border-bottom: 1px solid var(--noninteractive-border-secondary);
    color: var(--interactive-text-selected);
    padding: 0 0 2px;
}

.text-input:hover .input,
.input:not(:placeholder-shown) {
    border-bottom: 1px solid var(--interactive-border-inactive);
}

.input:not(:placeholder-shown)+.label {
    color: var(--noninteractive-text-secondary);
}

.text-input .label {
    position: absolute;
    left: 0;
    top: 0;
    color: var(--interactive-text-secondary-inverse);
    pointer-events: none;
}

.text-input ::placeholder {
    opacity: 0;
}

.error-msg {
    position: absolute;
    bottom: 0;
    left: 0;
    color: #F33122 !important;
    display: none;
}

/* FOCUS */
.text-input .input:focus-visible {
    border-bottom: 1px solid var(--interactive-border-inactive);
}

.input:focus-visible+.label {
    color: var(--interactive-border-inactive);
}

/* KEYBOARD FOCUS */
.keyboard-focus .input {
    border-bottom: 2px solid #4078F9 !important;
}

.keyboard-focus .label {
    color: #4078F9 !important;
}

/* ERROR */

.text-input .input:user-invalid,
.text-input .input.error {
    border-bottom: 2px solid #F33122 !important;
}

.text-input .input:user-invalid+.label,
.text-input .input.error+.label {
    color: #F33122 !important;
}

.text-input .input.error+.label+.error-msg,
.text-input .input:user-invalid+.label+.error-msg {
    display: block;
}

@media (max-width: 768px) {
    .text-input {
        margin-top: 14px;
        min-height: 42px;
    }
}