    .domain-input-wrapper {
        display: flex;
        align-items: center;
    }

    .domain-label-group {
        display: flex;
        align-items: center;
        white-space: nowrap;
        width: 420px;
        /* <--- Set a fixed width for the label area instead of using a large margin */
        flex-shrink: 0;
        margin-right: 15px;
        /* <--- Exact distance between the question mark and the input */
    }

    .domain-label {
        font-weight: 600;
    }

    .custom-input-wrapper {
        /* position: relative; */
        /* display: flex; */
        align-items: center;
        width: 100%;
    }

    .tooltip-container {
        margin-left: 10px;
        /* Space between the word "Name" and the question mark */
        position: relative;
        cursor: pointer;
        color: #0d6efd;
        transition: color 0.2s ease;
    }

    .tooltip-container:hover {
        color: #6c757d;
    }

    .tooltip-text {
        visibility: hidden;
        width: 250px;
        background-color: #333;
        color: #fff;
        text-align: center;
        border-radius: 6px;
        padding: 8px 12px;
        position: absolute;
        z-index: 999;
        bottom: 125%;
        left: 50%;
        transform: translateX(-50%);
        opacity: 0;
        transition: opacity 0.3s;
        font-size: 0.85rem;
        font-weight: normal;
        white-space: normal;
        line-height: 1.4;
    }

    .tooltip-container:hover .tooltip-text {
        visibility: visible;
        opacity: 1;
    }

    @media (max-width: 1400px) {
        .domain-input-wrapper {
            flex-direction: column;
            align-items: stretch;
            gap: 8px;
        }

        .domain-label-group {
            width: 100%;
            /* Full width on mobile */
            margin-right: 0;
        }
    }

    /* When an error wrapper triggers, stack the input and feedback vertically */
.custom-input-wrapper.has-error-wrapper {
    flex-direction: column;
    align-items: stretch;
}

/* Style and position the error message directly underneath */
.custom-invalid-feedback {
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875em;
    color: #dc3545;
    display: block;
}

/* Apply Bootstrap's error border to the input rendered inside the wrapper */
.custom-input-wrapper.has-error-wrapper input,
.custom-input-wrapper.has-error-wrapper textarea,
.custom-input-wrapper.has-error-wrapper select {
    border-color: #dc3545 !important;
}

@media (max-width: 1000px) {
    .hide-on-mobile {
        display: none !important;
    }
}