The alignment of the bootstrap-table is having difficulty shifting to the right

I am having trouble aligning my table to the right of my invoice page, similar to this:

https://i.sstatic.net/cDS8S.png

Even though I have placed these two tables in the same row and into two columns, it's not displaying as expected. I want the second table to be positioned on the highlighted blue section of the page.

Here is the snippet of my code:

 <div class="row">

      <div class="col-4 col-md-4 col-sm-5 " >
        <table class="table table-bordered ">
        <th><strong> Payment Received </strong></th>
        <tbody>
          <tr style="page-break-after: always;">
            <td class="left">
              Payment Method: xxxxxx
            </td>       
          </tr>
          <tr>
            <td class="left">
              Reference No: 2192012
            </td>       
          </tr>
          <tr>
            <td class="left">
              Amount Paid: RM10,000.00 
            </td>       
          </tr>
          <tbody>
     </table>
 <div>

    <div class="col-4 col-md-4 col-sm-5 mr-auto ">
        <table class="table table-clear">
        <tbody>
        <tr>
        <td class="left">
        <strong>Subtotal</strong>
        </td>
        <td class="right">8.497,00</td>
        </tr>
        <tr>
        <td class="left">
        <strong>Transportation(Klang Valley)</strong>
        </td>
        <td class="right">1,699,40</td>
        </tr>
        <tr>
        <td class="left">
         <strong>Transportation(Outstation)</strong>
        </td>
        <td class="right">679,76</td>
        </tr>
        <tr>
        <td class="left">
        <strong> Grand Total</strong>
        </td>
        <td class="right">
        <strong>7.477,36</strong>
        </td>
        </tr>
        <tr>
          <td class="left">
          <strong> Discount</strong>
          </td>
          <td class="right">
          20%
          </td>
          </tr>
          <tr>
            <td class="left">
            <strong> Amount Paid</strong>
            </td>
            <td class="right">
            7.477,36
            </td>
            </tr>
            <tr>
              <td class="left">
              <strong> Balance Due</strong>
              </td>
              <td class="right">
              <strong>7.477,36</strong>
              </td>
              </tr>
        </tbody>
        </table>

        </div>
      </div>

I can't seem to figure out why the alignment to the right isn't working, even though they are in the same row. What could be the issue?

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Concealing the cursor inactivity through JavaScript

Is there a way to utilize JavaScript to change the cursor attribute to none after a period of mouse inactivity, like five seconds, and then revert it back to auto once the mouse becomes active again? EDIT: I am aware that none is not an official value for ...

Utilizing JavaScript or PHP to assign a uniform class to dynamically generated elements

Hello! In my online shop, each category has a page with all subcategories and a table of products. I want each product row in the table to have the same color as its corresponding sorting button for the subcategory. This must be done dynamically as I hav ...

The button can only be edited using Internet Explorer

My webpage features a button that displays correctly in Chrome, but the text inside the button gets cut off when viewed in IE (see image). Can you provide guidance on what might be causing this issue and how to resolve it? Bootstrap version 4.0.0 is also b ...

How to effectively handle submenus within a Bootstrap 4 mobile menu?

I am currently updating our website from Bootstrap 3.3.7 to Bootstrap 4. The header contains a navigation bar with dropdown items. https://i.sstatic.net/n2P6U.png <header> <nav class="navbar fixed-top navbar-expand-lg navbar-light bg-white bg- ...

prettyPhoto popup exceeds maximum width and height limitations

I am currently using the most up-to-date version from No Margin for Errors and I have set allow_resize to true. However, the size of the display is still too large. Is there a way to set a maximum width/height? I have already configured the viewport as fo ...

Only horizontal Webkit Scrollbar Buttons visible

My custom webkit scrollbars have been styled using CSS, everything is displaying correctly except for the arrow increment/decrement buttons on the vertical scrollbar. When I removed "horizontal" from the ::-webkit-scrollbar-button line to make both horiz ...

Using Ajax with Bootstrap's typeahead feature

I've been struggling to implement typeahead on my website, and here's what I've attempted so far. Here is my HTML and code: <html> <head> <title>typeahead</title> <link href="//maxcdn.bootstrapcdn.com/ ...

trouble with padding on cards using vue-bootstrap

I have been working on creating a card component with Vue Bootstrap, but I've run into an issue. The card header and body seem to have excessive padding around them. If I remove the b-card element and only use b-card-header and b-card-body, it looks l ...

Options for regular expressions in CSS: match letters regardless of case and search for all occurrences

Here is the HTML I am working with: <div> <img class="hi" src="http://i.imgur.com/f9WGFLj.png"></img> <img class="HI" src="http://i.imgur.com/f9WGFLj.png"></img> </div> Additionally, I have the following CSS co ...

Bundlings in MVC 4 do not render correctly once hosted on IIS

I successfully hosted an MVC 4 application on IIS, which was developed using the .Net 4.5 framework. However, I encountered an issue where the CSS and JS files were not rendering properly in IE11, although they worked perfectly in Chrome. Here is the code ...

An innovative tool for discovering how different colors will complement each other

Design may not be my strong suit, but there are times when I need to add a border line or a shade of gray to a background color. Is there a tool available where I can specify background color: #343434 color: #asdfgh and visually see how it will look wit ...

Incorporating a dynamic image map with the power of three.js

I am a beginner with HTML image maps and three.js objects. I have successfully resized the image map as the window resizes, but I am struggling to insert additional JavaScript code for optimizing the performance. Although there are existing threads on thi ...

Ways to ensure two stacked divs have equal height

I'm in the process of designing a card with two stacked divs. The upper section of the card contains an image, while the lower part consists of text. How can I ensure that both the top and bottom divs have equal heights? I am hesitant to specify fixed ...

Upgrading to Bootstrap 5 and customizing the collapse button text upon click

I've spent a lot of time searching for a solution to my problem, but all the advice I found is for bootstrap 3 and 4, not version 5. Below is the code I am currently using: <div class="p-3">9 Members Online <a class="p-1 btn ...

Guide to implementing multiple CSS files in Django template inheritance

Seeking a solution for incorporating multiple CSS files for different templates using Django template inheritance. Currently, I have extended my base.html template with another app's template. Now, I want to use separate CSS files for each app's ...

What is the method to restrict the coverage of the background color within a specific region in HTML?

I am still fairly new to html so I apologize if this is a very basic question for you. Here is the css file that is causing me trouble: .sidepanel-list{ margin-left: 10px; background-color:lightgray; Whenever I run the code, the background color s ...

Aligning a list of items vertically inside a div container

Struggling to align inline list elements vertically within a div, but unable to figure out why it's not working. Here is the CSS I have included: .nav li{ display: inline; display: table-cell; vertical-align: middle; } .nav ul { v ...

Allow a nested element to overlap its container instead of displacing it

As a CSS newbie writing a React app, this question may be the easiest one in the history of stackoverflow. I'm trying to make the image element overlap the header instead of pushing it down. In this basic HTML example, the cat image is stretching the ...

The power of the HTML image tag and the versatility of the srcset

I am feeling a bit puzzled about how to properly use the srcset attribute within the HTML img tag. Despite reading multiple tutorials online, it seems that things are not functioning as described in those resources. Let's begin with a simple example: ...

Utilizing a fresh stance when transitioning to a stable position

How can I make an element on my page scroll with the page until a certain point, and then switch to fixed position when another moving element interacts with it? The issue I'm facing is that when it switches to fixed position, it jumps down to its ori ...