/* Keep the Bioreactor at 37 °C (CHE7403)
   Layout only - every colour comes from the model-shell palette at runtime. */

.brc-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: 0.9rem;
  align-items: start;
}

.brc-layout > * {
  min-width: 0;
}

/* Elements with their own display value would otherwise ignore the hidden attribute. */
.brc-layout [hidden] {
  display: none !important;
}

.brc-stage {
  display: block;
  width: 100%;
  height: 420px;
}

/* The verdict is the most important thing on the page, so it is the largest text. */
.brc-verdict {
  margin: 0.5rem 0 0.4rem;
  padding: 0.5rem 0.8rem;
  border: 3px solid;
  border-radius: 10px;
}

.brc-verdict-main {
  display: block;
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1.2;
}

.brc-verdict-sub {
  display: block;
  font-size: 1.05rem;
  margin-top: 0.15rem;
}

.brc-stats {
  list-style: none;
  margin: 0.2rem 0 0.4rem;
  padding: 0;
}

.brc-stats li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.2rem 0;
  font-size: 1.02rem;
}

.brc-swatch {
  flex: 0 0 auto;
  width: 1.1rem;
  height: 1.1rem;
  border: 2px solid;
  border-radius: 3px;
}

.brc-swatch--dot {
  border-radius: 50%;
}

.brc-eq-scroll {
  overflow-x: auto;
  padding-bottom: 0.2rem;
}

.brc-eq {
  display: grid;
  grid-auto-flow: column;
  grid-template-rows: auto auto auto;
  justify-content: start;
  align-items: center;
  column-gap: 0.55rem;
  row-gap: 0.15rem;
  width: max-content;
  margin-top: 0.3rem;
}

.brc-eq:empty {
  display: none;
}

.brc-eq-head {
  font-size: 0.85rem;
  font-weight: 700;
  text-align: center;
  align-self: end;
}

.brc-eq-sym {
  font-size: 1.3rem;
  text-align: center;
  white-space: nowrap;
}

.brc-eq-val {
  font-size: 1.05rem;
  text-align: center;
  white-space: nowrap;
}

.brc-eq-res {
  font-weight: 800;
}

.brc-frac {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  vertical-align: middle;
}

.brc-frac > span:first-child {
  border-bottom: 1.5px solid currentColor;
  padding: 0 0.2rem;
}

.brc-frac > span:last-child {
  padding: 0 0.2rem;
}

.brc-foot {
  margin: 0.3rem 0 0;
  font-size: 0.9rem;
}

.brc-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.8rem;
}

.brc-tab {
  flex: 1 1 8rem;
  font: inherit;
  font-weight: 800;
  font-size: 0.92rem;
  padding: 0.45rem 0.5rem;
  border: 2px solid;
  border-radius: 999px;
  cursor: pointer;
}

.brc-sub {
  margin: 0 0 0.3rem;
  font-weight: 700;
}

.brc-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-bottom: 0.8rem;
}

.brc-chip {
  font: inherit;
  font-size: 0.9rem;
  padding: 0.3rem 0.65rem;
  border: 2px solid;
  border-radius: 999px;
  cursor: pointer;
}

.brc-slider {
  display: grid;
  grid-template-columns: 7.2rem minmax(0, 1fr) 8.6rem;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}

.brc-slider label {
  font-weight: 800;
}

.brc-slider input {
  width: 100%;
}

.brc-val {
  font-weight: 800;
  text-align: right;
  white-space: nowrap;
}

.brc-guide {
  margin: 0.4rem 0 0.6rem;
  line-height: 1.5;
}

.brc-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.4rem;
}

.brc-strong {
  font-weight: 800;
}

.brc-go {
  display: block;
  width: 100%;
  margin-top: 0.9rem;
  padding: 0.55rem 0.8rem;
  font: inherit;
  font-weight: 800;
  border: 2px solid;
  border-radius: 999px;
  cursor: pointer;
}

.brc-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.brc-progress {
  display: flex;
  gap: 0.3rem;
  flex-wrap: wrap;
}

.brc-dot {
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  border: 2px solid;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0;
  cursor: pointer;
}

.brc-dot[aria-current="true"] {
  outline: 3px solid currentColor;
  outline-offset: 2px;
}

.brc-score {
  font-weight: 800;
  font-size: 0.9rem;
}

.brc-task {
  margin: 0.6rem 0 0.2rem;
  font-size: 1.1rem;
  font-weight: 800;
}

.brc-intro {
  margin: 0 0 0.5rem;
  line-height: 1.5;
}

.brc-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 0.7rem;
}

.brc-table th,
.brc-table td {
  padding: 0.3rem 0.4rem;
  border-bottom: 1px solid;
  text-align: left;
}

.brc-table td {
  font-weight: 700;
}

.brc-answer {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.brc-answer label {
  font-weight: 800;
}

.brc-answer input {
  font: inherit;
  font-size: 1.1rem;
  width: 7rem;
  padding: 0.25rem 0.4rem;
}

.brc-hint {
  margin: 0.3rem 0 0;
  font-size: 0.85rem;
}

.brc-feedback {
  margin: 0.6rem 0 0;
  min-height: 2.6em;
  line-height: 1.45;
}

@media (max-width: 820px) {
  .brc-layout {
    grid-template-columns: minmax(0, 1fr);
  }
  .brc-verdict-main {
    font-size: 1.35rem;
  }
}

@media (max-width: 480px) {
  .brc-slider {
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-areas: "label value" "input input";
    row-gap: 0.2rem;
  }
  .brc-slider label {
    grid-area: label;
  }
  .brc-slider input {
    grid-area: input;
  }
  .brc-val {
    grid-area: value;
  }
}

/* Additions for the bioreactor lesson */
.brc-swatch--dash {
  border-style: dashed;
}

.brc-swatch--line {
  height: 0;
  border-width: 3px 0 0;
  border-radius: 0;
}

.brc-swatch--line.brc-swatch--dash {
  border-top-style: dashed;
}

.brc-swatch--line.brc-swatch--dot {
  border-top-style: dotted;
  border-radius: 0;
}

.brc-reaction {
  margin: 0.5rem 0 0.3rem;
  font-size: 1rem;
}

.brc-details {
  margin-top: 0.6rem;
  font-size: 0.95rem;
}

.brc-details summary {
  cursor: pointer;
  font-weight: 700;
}

.brc-details p {
  margin: 0.35rem 0;
}

.brc-task--first {
  margin-top: 0;
}

.brc-predict {
  margin: 0 0 0.8rem;
  padding: 0.5rem 0.6rem;
  border: 2px solid;
  border-radius: 8px;
}

.brc-predict p {
  margin: 0 0 0.4rem;
  line-height: 1.45;
}

.brc-note {
  margin: 0.3rem 0 0.5rem;
  font-size: 0.9rem;
  line-height: 1.45;
}

.brc-result {
  margin: 0.6rem 0 0;
  line-height: 1.5;
}

.brc-result:empty {
  display: none;
}

.brc-check {
  display: block;
  margin: 0.3rem 0 0.5rem;
  font-weight: 700;
}

.brc-check--small {
  font-weight: 400;
  font-size: 0.9rem;
}

.brc-table-scroll {
  overflow-x: auto;
}

.brc-compare th,
.brc-compare td {
  font-size: 0.9rem;
  white-space: nowrap;
}

.brc-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  list-style: none;
  margin: 0.5rem 0 0.6rem;
  padding: 0;
}

.brc-steps li {
  padding: 0.15rem 0.6rem;
  border: 2px solid;
  border-radius: 999px;
  font-size: 0.85rem;
  white-space: nowrap;
}

.brc-steps li[aria-current="step"] {
  font-weight: 800;
  outline: 2px solid currentColor;
  outline-offset: 1px;
}

.brc-answer label {
  flex-basis: 100%;
}
