:root {
  --page-color: white;
  --panel-color: #FAFAFA;
  --line-color: #D5D5D5;
  --font-color: black;
}

body, html {
  margin: 0 !important;
  padding: 0 !important;
  /* Imported by layout.erb */
  font-family: "Host Grotesk", sans-serif;
  font-optical-sizing: auto;
  font-weight: 300;
  font-style: normal;
  background-color: var(--page-color);
  color: var(--font-color);
}

#logo-heading {
  display: flex;
  flex-direction: row;
  gap: 30px;
  align-items: center;
}
#logo-heading img {
  height: 70px;
}
#logo-heading h1 {
  margin: 0;
}

#title-bar {
  width: 100%;
  box-sizing: border-box;
  padding: 20px;
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  gap: 50px;
  align-items: center;
}
#title-bar.already-in-padded-container {
  padding: 0;
  padding-bottom: 20px;
}
#title-bar #home-link img {
  height: 60px;
  display: block;
}
#title-bar h1 {
  margin-block: 0;
}
#title-bar #assembly-variant-selector {
  font-size: 25px;
}

#revision-info {
  display: block;
  margin-top: 40px;
  color: #aaa;
}

#content {
  padding: 20px;
  box-sizing: border-box;
}
#content.centred {
  max-width: 800px;
  margin: 0 auto;
}

#filter-view {
  display: flex;
  flex-direction: row;
  gap: 10px;
  justify-content: space-around;
}
@media screen and (max-width: 767px) {
  #filter-view {
    flex-direction: column;
  }
}
#filter-view #filter-view-divider {
  position: sticky;
  align-self: flex-start;
  top: 20px;
  height: calc(100vh - 40px);
  width: 1px;
  background-color: #eee;
}
@media screen and (max-width: 767px) {
  #filter-view #filter-view-divider {
    display: none;
  }
}

#static-panel {
  flex: 1;
  height: calc(100vh - 40px);
  top: 20px; /* So it immediately becomes sticky */
  position: sticky;
  align-self: flex-start; /* Fixes sticky not sticking in flexbox */
  display: flex;
  flex-direction: column;
}
@media screen and (max-width: 767px) {
  #static-panel {
    position: static;
    align-self: unset;
  }
}
#static-panel #filter-panel {
  flex: 1;
  overflow: hidden;
  margin: 0 10px;
  border-radius: 20px;
  background-color: var(--panel-color);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
}
@media screen and (max-width: 767px) {
  #static-panel #filter-panel {
    /* Fixes panel being invisible on Safari */
    flex: unset;
  }
}
#static-panel #filter-panel #top-filter-panel {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
}
#static-panel #filter-panel #inner-filter-panel {
  padding: 15px;
  height: 100%;
  overflow-y: auto;
}
#static-panel #filter-panel #inner-filter-panel > :last-child {
  margin-bottom: 30px;
}
#static-panel #filter-panel #input-mnemonic-filter {
  width: 100%;
  box-sizing: border-box;
  padding: 5px;
  border: 1px solid var(--line-color);
  border-radius: 5px;
}

#filter-results {
  flex: 3;
}
#filter-results #filter-results-divider {
  display: none; /* Changed by media query */
  border: 0;
  height: 0;
  border-top: 1px solid var(--line-color);
  margin-top: 20px;
  margin-bottom: 20px;
}
@media screen and (max-width: 767px) {
  #filter-results #filter-results-divider {
    display: block;
  }
}
#filter-results .result-card {
  padding: 15px;
  margin: 0 10px;
  margin-bottom: 30px;
  border-radius: 20px;
  background-color: var(--panel-color);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
}
#filter-results .result-card.notice {
  background-color: #ffc488;
}
#filter-results .result-card.error {
  background-color: #fa7a90;
}
#filter-results .result-card .header {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 10px;
}
#filter-results .result-card .assembly-format {
  font-size: 20px;
}
#filter-results .result-card ul {
  margin-block: 0;
}

.filter-table {
  margin: 0 auto;
  border-collapse: collapse;
}
.filter-table.full-width {
  width: 100%;
}
.filter-table tr {
  border-bottom: 1px solid var(--line-color);
}
.filter-table .checkbox-cell {
  width: 60px;
  text-align: center;
}
.filter-table .label-cell {
  padding-right: 10px;
}
.filter-table .label-cell.align-end {
  text-align: end;
}

.result-operand-table {
  border-collapse: collapse;
}
.result-operand-table tr, .result-operand-table th {
  border-bottom: 1px solid var(--line-color);
}
.result-operand-table tr.quiet, .result-operand-table th.quiet {
  border-bottom: 0;
  color: gray;
}
.result-operand-table th {
  padding-top: 15px;
  text-align: left;
}
.result-operand-table .label-cell {
  text-align: end;
  padding-right: 10px;
  padding-left: 20px;
}

.predicate-labels {
  display: flex;
  flex-direction: row;
  gap: 20px;
}
.predicate-labels span {
  display: inline-block;
  padding: 5px;
  margin-top: 15px;
  margin-bottom: 5px;
  font-size: 14px;
  border: 1px solid black;
  background-color: white;
  border-radius: 5px;
}

span.validation-error {
  color: red;
}

input.validation-error {
  outline: 3px solid red !important;
}

/* For operand highlighting */
mark {
  display: inline-block;
  padding: 1px 3px;
  border-radius: 3px;
  /* default colour - almost always overridden */
  background-color: white;
}