/*
  Josh's Custom CSS Reset
  https://www.joshwcomeau.com/css/custom-css-reset/
*/
*, *::before, *::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

html {
  scroll-behavior: smooth;
}

html, body {
  min-height: 100vh;
}

body {
  line-height: 1.5;
  text-rendering: optimizeSpeed;
  -webkit-font-smoothing: antialiased;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
  margin: 0;
  padding: 0;
}

p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

a {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

address {
  font-style: normal;
}

.sr-only {
  position: absolute;
  width: 0.0625rem;
  height: 0.0625rem;
  padding: 0;
  margin: -0.0625rem;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

:root {

  /* primary colors */
  --white: hsl(0, 0%, 100%);
  --black: hsl(204, 15%, 13%);
  --text_black: hsl(208, 14%, 36%);

  /* neutral colors */
  --soft_black: hsl(205, 20%, 78%);
  --line: hsl(210, 27%, 94%);

  /* box-shadows */
  --btn_shadow: 0px 3px 0px 0px var(--black);
  --btn_shadow--hover: 0px 1px 0px 0px var(--black);

  /* font-families */
  --heading: 'Montserrat', sans-serif;
  --paragraph: 'Hind', sans-serif;

  /* font-weights */
  --regular: 400;
  --medium: 500;
  --bold: 700;

}

body {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 5rem 1rem;
  background-color: var(--white);
}

main {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5rem;
}

.form {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1.5rem;
  width: 100%;
  max-width: 750px;
  border: 2px solid var(--black);
  border-radius: 10px;
}

.form__field {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  width: 100%;
  padding: 0;
  border: none;
}

.form__input-container:has(#bookName) {
  flex-grow: 1;
  flex-shrink: 1;
  flex-basis: auto;
}

.form__inner {
  flex-grow: 1;
  flex-shrink: 1;
  flex-basis: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.form__inner > .form__input-container {
  flex-grow: 1;
  flex-shrink: 1;
  flex-basis: auto;
}

.form__input, .form__options {
  font-family: var(--paragraph);
  font-size: 1rem;
  font-weight: var(--regular);
  width: 100%;
  height: 40px;
  padding-inline: 10px;
  border: 1px solid var(--black);
  border-radius: 5px;
}

.form__input::placeholder, select:invalid, select option[value=""] {
  color: var(--text_black);
}

.form__btn {
  width: 100%;
  height: 40px;
  font-family: var(--heading);
  font-size: 1rem;
  font-weight: var(--medium);
  background: none;
  border: 2px solid var(--black);
  border-radius: 5px;
  box-shadow: var(--btn_shadow);
  transition: all 0.2s ease 0s;
}

.form__btn:is(:hover, :focus-visible, :active) {
  box-shadow: var(--btn_shadow--hover);
  transform: translateY(2px);
}

.table {
  width: 100%;
  max-width: 750px;
  border-collapse: collapse;
}

.table th, .table td {
  width: 40%;
}

.table tr {
  text-align: center;
}

.table__head {
  font-family: var(--heading);
  font-size: 1.3rem;
  font-weight: var(--bold);
}

.table__head th {
  padding-inline: 5px;
  border-bottom: 2px solid var(--black);
  border-right: 2px solid var(--black);
}

.table__head th:last-of-type {
  border-right: 0px solid var(--black);
}

.table__body {
  font-family: var(--paragraph);
  font-size: 1rem;
}

.table__body td {
  border-top-width: 0;
  border-bottom: 1px solid var(--soft_black);
  border-right: 2px solid var(--black);
}

.table__body td:last-of-type {
  border-right-width: 0;
}

.table__body tr:last-of-type td {
  border-bottom-width: 0;
}
