form { display: grid; grid-template-columns: [label] max-content [input] max-content; } form label { margin: 1ex 0.5em; grid-column-start: label; justify-self: end; } form input, form select { margin: 1ex 0.5em; grid-column-start: input; } form button { padding: 1ex 2em; width: 7em; justify-self: end; grid-column-start: input; } #output { display: grid; grid-template-columns: max-content; margin-top: 1ex; } #download { justify-self: end; } #output table { margin-top: 1ex; border-collapse: collapse; } #output table thead { font-weight: bold; } #output table tr { // border-bottom: 1px solid black; } #output table td { padding: 0.5ex 0.5em; border: 1px solid black; }