@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;700&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

ul {
  list-style: none;
}

body {
  font-family: "Inter", sans-serif;
  display: grid;
  grid-template-columns: 200px 1fr;
}

body > header {
  background-color: black;
  color: white;
  padding: 1rem;
  display: flex;
  text-align: right;
}

body > header section {
  position: sticky;
  top: 1rem;
}

body > header h1 {
  margin-bottom: 2rem;
}


body > header ul {
  flex-grow: 1;
}

body > header ul li a {
  color: white;
  display: block;
  padding: 0.25rem 0.5rem;
}

body > main {
  padding: 1rem;
}

section.edition h1 {
  font-size: 2rem;
  padding-bottom: 1rem;
  text-align: center;
}

section.edition > section.search {
  background-color: lightgray;
  padding: 1rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
}

section.edition > section.search input {
  padding: 0.25rem;
  flex-grow: 1;
  margin-left: 0.5rem;
}

ul.instances > li {
  border-bottom: 1px solid lightgray;
  gap: 1rem;
}

ul.instances > li details summary {
  padding: 1rem 1rem 1rem 4rem;
  background-image: url("/static/img/plus.svg");
  background-size: 2rem;
  background-repeat: no-repeat;
  background-position: 1rem center;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
}

ul.instances > li details[open] summary.empty {
  background-color: red;
  opacity: 0.75;
  color: white;
  background-image: none;
  padding: 0.5rem;
  font-size: 0.75rem;
  pointer-events: none;
}

ul.instances > li details[open] summary.empty h2 {
  font-size: 0.75rem;
}

ul.instances > li details[open] summary {
  background-image: url("/static/img/minus.svg");
  background-color: lightgray;
}

ul.instances > li details summary h2 {
  font-size: 1.25rem;
}

ul.participants {
  background-color: white;
  padding: 1rem;
}

ul.participants li {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid gray;
  border-left: 4px solid white;
  padding-left: 4px;
}

ul.participants li:hover {
  border-left: 4px solid gray;
}

ul.participants li header {
  display: flex;
}

ul.participants li header h3 {
  flex-grow: 1;
  font-size: 1.25rem;
}

ul.participants li header section.info {
  text-align: right;
  font-family: monospace;
  font-size: 1rem;
}

ul.participants table {
  margin-top: 1rem;
  width: 100%;
  font-size: 0.85rem;
  font-family: monospace;
}

ul.participants table th {
  text-align: left;
  background-color: lightgray;
  padding: 0.5rem;
}

ul.participants table td {
  padding: 0.5rem;
}

ul.instances > li details.empty {
  background-color: red;
}

section.login {
  max-width: 20rem;
  margin: 0 auto;
  padding: 1rem;
}

.error {
  color: red;
  margin-top: 1rem;
}

form fieldset {
  margin-bottom: 1rem;
  border: none;
}

form fieldset:last-of-type {
  margin-bottom: 2rem;
}

form label {
  display: block;
  margin-bottom: .5rem;
}

input {
  width: 100%;
  padding: .5rem;
}

button {
  width: 100%;
  padding: 1rem;
  background-color: #000;
  color: white;
  border: none;
}

a.logout {
  display: inline-block;
  margin-bottom: 1rem;
  padding: .5rem;
  margin-top: 2rem;
  background: white;
  color: black;
  text-decoration: none;
}
