.content-main {
  box-shadow: none;
  overflow: clip;
}

h2 {
  font-family: 'Comfortaa';
  margin-top: 0px;
}

.subtitle {
  margin-bottom: 10px;
}

.options-content {
  background-color: #fdfdfd;
  border: 1px solid #38398b;
  border-bottom: transparent;
  margin: auto;
  padding-top: 0px;
}

.section-wrapper {
  padding: 20px 2.5%;
}

textarea {
  outline: none;
}

input, select {
  background-color: #ffffff;
}

input:disabled, select:disabled {
  background-color: #e9e9ed;
}

#back_to_top {
  background-color: #38398b;
  border: solid 2px #38398b;
  border-radius: 50%;
  bottom: 20px;
  color: #ffffff;
  cursor: pointer;
  font-size: 25px;
  height: 50px;
  padding-bottom: 8px;
  position: fixed;
  right: 20px;
  width: 50px;
  z-index: 1;
}

/* TOP BAR */

.top-bar h1 {
  color: #ffffff;
  float: left;
  font-size: 2.2em;
  font-family: 'Comfortaa';
  margin-left: 30px;
  margin-top: 10px;
}

.top-bar {
  background-color: #38398b;
  border: 1px solid #38398b;
  box-sizing: border-box;
  height: 90px;
  max-width: 1250px;
  padding: 20px;
  padding-left: 15px;
  padding-right: 15px;
  position: sticky;
  text-align: right;
  top: 0;
  width: 100%;
  z-index: 9999;
}

.nav-button {
  background-color: #38398b;
  border: 3px solid;
  border-radius: 8px;
  box-sizing: border-box;
  cursor: pointer;
  font-size: 15px;
  font-weight: 400;
  height: 100%;
  margin: auto 20px;
  margin-left: 0px;
  vertical-align: middle;
  width: 100px;
}

.nav-button-submit {
  border-color: #FFFFFF;
  color: #FFFFFF;
}

.nav-button-submit:hover {
  background-color: #FFFFFF;
  color: #38398b;
}

.nav-button-reset {
  border-color: #FFFFFF;
  color: #FFFFFF;
}

.nav-button-reset:hover {
  background-color: #FFFFFF;
  color: #38398b;
}

@media all and (max-width: 1100px) {
  .nav-button {
    margin: auto 2%;
  }
}

@media all and (max-width: 768px) {
  .nav-button {
    margin: auto 1%;
  }

  .top-bar {
    padding: 20px 10px;
  }
}

@media all and (max-width: 678px) {
  .nav-button  {
    height: 85%;
    margin-top: 5px;
    text-align: center;
  }

  .top-bar {
    height: 72px ;
    padding: 8px;
  }

  .top-bar h1 {
    margin: 10px;
    text-align: center;
  }
}

@media all and (max-width: 600px) {
  .nav-button {
    width: 40px;
    height: 75%;
    margin-top: 7px;
    padding-left: 7px;
  }

  .hidden-mobile {
    display: none;
    padding-right: 5px;
  }
}

@media all and (max-width: 550px) {
  .top-bar h1 {
    font-size: 1.6em;
    margin-top: 14px;
  }
}

@media all and (max-width: 400px) {
  .option-label {
    font-size: 13px;
  }

  .options-wrapper-input-field label {
    font-size: 14px;
  }

  h2 {
    font-size: 1.2em;
  }
}

@media all and (max-width: 350px) {
  .top-bar h1 {
    font-size: 1.4em;
    margin-top: 17px;
  }

  h2 {
    font-size: 1.3em;
  }
}

@media all and (max-width: 310px) {
  .top-bar h1 {
    font-size: 1.2em;
  }

  .nav-button {
    font-size: 1.2em;
  }

  .option-label {
    font-size: 10px;
  }

  .structure-parameters-input label {
    font-size: 14px;
  }

  .options-wrapper-input-field label {
    font-size: 14px;
  }
}

/* NAVTAB CONTAINER */

.navtab-container {
  display: flex;
  flex-wrap: wrap;
  margin-top: 25px;
  padding-bottom: 30px;
}

.navtab-container .navtab-content-container {
  background-color: #ffffff;
  box-sizing: border-box;
  display: none;
  height: 100%;
  margin-left: auto;
  order: 2;
  width: 100%;
}

.navtab-container input[type='radio'] {
  display: none;
}

.navtab-container label {
  background-color: #ffffff;
  border: solid 1px #38398b;
  border-radius: 8px 8px 0 0;
  box-sizing: border-box;
  cursor: pointer;
  display: flex;
  flex-grow: 1;
  flex-basis: 25%;
  margin-bottom: -1px;
  margin-top: -5px;
  min-width: 150px;
  order: 0;
  padding: 10px 15px;
}

.navtab-container button ~ label {
  flex-basis: 22%;
}

.navtab-container label:first-of-type:nth-last-of-type(-n + 3),
.navtab-container label:first-of-type:nth-last-of-type(-n + 3) ~ label {
  flex-grow: 0;
}

.navtab-container label:first-of-type:nth-last-of-type(n + 5):nth-last-of-type(-n + 6),
.navtab-container label:first-of-type:nth-last-of-type(n + 5):nth-last-of-type(-n + 6) ~ label {
  flex-basis: 30%;
}

@media all and (max-width: 768px) {
  .navtab-container label {
    flex-grow: 1 !important;
  }

  .navtab-container button ~ label {
    flex-basis: 35% !important;
  }

  .navtab-container label:first-of-type:nth-last-of-type(3),
  .navtab-container label:first-of-type:nth-last-of-type(3) ~ label {
    flex-grow: 1;
  }
}

@media all and (max-width: 400px) {
  .navtab-container label {
    min-width: unset;
    padding: 10px;
  }
}

.navtab-container label span {
  display: flex;
  margin: auto;
}

.navtab-container input[type='radio']:not(:checked) + label:hover {
  background-color: #eff0ff;
  border-color: #eff0ff;
  border-bottom: none;
}

.navtab-container input[type='radio']:checked + label {
  background-color: #38398b;
  color: #ffffff;
}

.navtab-container input[type='radio']:checked + label + .navtab-content-container {
  display: unset;
}

.navtab-container hr {
  order: 1;
  width: 100%;
}

.navtab-container button {
  background-color: #38398b; 
  border-radius: 8px 8px 0 0;
  border: 1px solid #38398b;
  color: white;
  cursor: pointer;
  font-size: 1em;
  font-weight: bold;
  margin: -5px 0 -1px auto;
  order: 1;
  padding: 10px 15px;
}

@media all and (max-width: 400px) {
  .navtab-container button {
    padding: 10px;
  }
}

.tab-baseline {
  background: #38398b;
  border: none;
  height: 5px;
  margin: unset;
}

.x-btn {
  color: #D42322;
  cursor: pointer;
  margin: auto 2px auto 10px;
  width: auto;
}

.x-btn:hover {
  color: #FF2F2F;
}

/* STRUCTURE INPUT */

.input-style {
  background-color: #FFF;
  border:solid 1px;
  border-color: #EEE;
  border-top-left-radius: 0px !important;
  border-top-right-radius: 0px !important;
  box-sizing: border-box;
  display: block;
  font-size: 15px;
  margin: 0;
  max-width: 100%;
  min-height: 400px;
  padding: 10px 15px;
  width: 100%;
}

#magnetic_moment {
  display: grid;
  grid-column: 3 / span 2;
  grid-column-gap: 5px;
  grid-template-columns: repeat(2,1fr);
  width: 100%;
}

#magnetic_moment input {
  border-radius: 3px;
  box-sizing: border-box;
  font-size: 20px;
  font-weight: bold;
  height: 100%;
  width: 100%;
}

#structure_parameters {
  display: grid;
  grid-column-gap: 20px;
  grid-row-gap: 20px;
  grid-template-columns: repeat(4, 1fr);
}

.structure-parameters-input {
  display: grid;
}

.structure-parameters-input  label {
  color: #38398b;
  font-family: 'Comfortaa';
  font-weight: bold;
}

.structure-parameters-input select {
  border-radius: 3px;
  font-weight: bold;
  height: 80%;
  width: 100%;
}

@media all and (max-width: 768px) {
  #magnetic_moment {
    grid-column: 1 / span 4;
  }

  #output_type {
    grid-column: 1 / span 2;
  }

  #output_type select {
    height: 175%;
  }

  #structure_parameters {
    display: grid;
    grid-column-gap: 5px;
    grid-template-columns: repeat(4, 1fr);
  }

  #symmetry_tolerance {
    grid-column: 3 / span 2;
  }

  #symmetry_tolerance select {
    height: 175%;
  }
}

/* OPTIONS */

.container {
  display: grid;
  grid-column-gap: 20px;
  grid-row-gap: 20px;
  grid-template-columns: repeat(2, 1fr);
}

@media all and (max-width: 768px) {
  .container {
    grid-template-columns: 1fr;
  }
}

.options-wrapper {
  border: 2px solid #38398b;
  border-radius: 7px;
  box-sizing: border-box;
}

.options-wrapper-input-field {
  align-items: center;
  display: grid;
  grid-column-gap: 5px;
  grid-template-areas:
    "a b"
    "a c";
  grid-template-columns: 50%;
  grid-template-rows: 50% 50%;
  padding: 5px;
  width: 100%;
}

.options-wrapper-input-field .option,
.options-wrapper-input-field .option-optional {
  grid-area: a;
}

.options-wrapper-input-field label {
  font-weight: 300;
  text-align: center;
}

.options-wrapper-input-field > label {
  grid-area: b;
}

.options-wrapper-input-field select {
  border-radius: 3px;
  font-weight: bold;
  height: 100%;
  width: 100%;
}

.options-wrapper-input-field input {
  border-radius: 3px;
  box-sizing: border-box;
  font-weight: bold;
  height: 100%;
  width: 100%;
}

.options-wrapper-input-field > input,
.options-wrapper-input-field > select {
  grid-area: c;
}

.options-wrapper-input-field .label-wrapper {
  display: grid;
  grid-area: b;
  grid-column-gap: 5px;
}

.options-wrapper-input-field .input-wrapper {
  display: grid;
  grid-area: c;
  grid-column-gap: 5%;
}

.options-wrapper-no-field {
  width: 100%;
}

.options-wrapper-no-field .option,
.options-wrapper-no-field .option-optional {
  border: none;
}

.options-wrapper-full-row {
  grid-column: 1 / span 2;
  padding: 5px;
  width: 100%;
}


@media all and (max-width: 768px) {
  .options-wrapper-full-row {
    grid-column: 1;
    grid-template-columns: 1fr;
  }
}

.option, .option-optional {
  align-items: center;
  border: solid 1px;
  border-radius: 5px;
  box-sizing: border-box;
  color: #38398b;
  cursor: pointer;
  display: flex;
  font-weight: bold;
  height: 100%;
  min-height: 60px;
  text-align: center;
  width: 100%;
}

.option-label {
  float: left;
  font-family: 'Comfortaa';
  padding: 5px;
  text-align: center;
  width: 100%;
}

.unselected {
  background-color: #ffffff;
  border-color: #38398b;
}

.unselected:hover{
  background-color: #EFF0FF;
  border-color: #EFF0FF;
  cursor: pointer;
}

.selected {
  background-color: #38398b;
  border-color: #38398b;
  color: #ffffff;
}

/* TOOLTIP */

.info-btn {
  color: #e75113;
  cursor: pointer;
  font-size: 17px;
  margin-top: 0px;
}

.info-btn:hover {
  color: #e75113;
}

.selected .info-btn {
  color: #FFFFFF;
}

.tooltip {
  float: right;
  margin-right: 2%;
  position: relative;
  text-align: center;
  width: 10%;
}

.tooltip .tooltiptext {
  background-color: #FFFFFF;
  border: solid #e75113 2px;
  border-radius: 6px;
  bottom: 120%;
  color: #4b4b4d;
  float: right;
  font-weight: 400;
  left: 50%;
  margin-left: -190px;
  opacity: 0;
  padding: 5px;
  position: absolute;
  text-align: center;
  transition: opacity 1s;
  visibility: hidden;
  z-index: 1;
}

.tooltip:hover .tooltiptext {
  opacity: 1;
  visibility: visible;
}

.tooltiptext a {
  color: #373889;
}

.tooltip .tooltiptext::after {
  border-color: #e75113 transparent transparent transparent;
  border-style: solid;
  border-width: 5px;
  content: " ";
  left: 190px;
  margin-left: -6px;
  position: absolute;
  top: 100%;
}

/* CCE */

#cce_wrapper {
  display: grid;
  grid-column-gap: 2%;
  grid-row-gap: 10px;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: auto auto;
}

@media all and (max-width: 768px) {
  #cce_wrapper {
    grid-template-columns: unset;
  }
}

#cce_wrapper input {
  border-width: 2px;
  font: inherit;
}

.cce-column {
  grid-row: 2;
}

.cce-label {
  font-weight: bold;
  grid-row: 1;
  margin-left: 5px;
  margin-top: 5px;
}

@media all and (max-width: 768px) {
  .cce-column {
    grid-column: 1 !important;
    grid-row: auto;
  }

  .cce-label {
    grid-column: 1 !important;
    grid-row: auto;
  }
}

.functional-output {
  align-items: center;
  border: solid #38398b 1px;
  border-radius: 5px;
  display: flex;
  font-weight: bold;
  margin-bottom: 5px;
  min-height: 40px;
  text-align: center;
}

.functional-output input {
  box-sizing: border-box;
  margin: 0 5%;
  width: 90%;
}

/* OUTPUT */

.output-container {
  margin-top: 0;
}

.output-container .navtab-content-container {
  border: 1px solid #eeeeee;
  height: 500px;
  overflow-y: scroll;
  padding-left: 10px;
}

.output-container img {
  height: 300px;
}
