section {
  margin-bottom: var(--pico-block-spacing-vertical);
  padding: var(--pico-block-spacing-vertical) var(--pico-block-spacing-horizontal);
  border-radius: var(--pico-border-radius);
  background: var(--pico-card-background-color);
  box-shadow: var(--pico-card-box-shadow)
}

input[type="submit"], [role="button"] {
  @media only screen and (max-width: 576px) {
    width: 50%;
  }
  @media only screen and (min-width: 577px) and (max-width: 1024px) {
    width: 30%;
  }
  @media only screen and (min-width: 1025px) {
    width: 20%;
  }
}

.grid [role="button"] {
  width: auto;
}

/* Colors: https://www.design-seeds.com/2024/05/mineral-blues.html
   But when you need warning reds, maybe https://www.design-seeds.com/2024/04/nouveau-hues.html */
:root {
  /* scheme colors */
  --scheme-sand: hsl(35, 57%, 78%);
  --scheme-sand-lightened: hsl(35, 57%, 97%);
  --scheme-dark-blue: hsl(219, 30%, 23%);
  --scheme-dark-blue-lightened: hsl(219, 30%, 33%);
  --scheme-blue: hsl(217, 46%, 42%);
  --scheme-blue-lightened: hsl(217, 46%, 47%);
  --scheme-blue-very-lightened: hsl(217, 46%, 77%);
  --scheme-bright-blue: hsl(198, 51%, 47%);
  --scheme-bright-blue-lightened: hsl(198, 51%, 52%);
  --scheme-red: hsl(354, 46%, 43%);
  --scheme-orange: hsl(27, 62%, 80%);
  --scheme-green: hsl(169, 46%, 42%);

  /* fonts */
  --pico-font-family: Inter, sans-serif;
  --header-font: Newsreader, serif;

  /* semantic colors */
  --text-color: var(--scheme-dark-blue);
  --text-color-light: var(--scheme-dark-blue-lightened);
  --button-color-primary: var(--scheme-blue);
  --button-color-primary-light: var(--scheme-blue-lightened);
  --background-color: var(--scheme-sand-lightened);
}

html, body {
  height: 100%;
}

body {
  background-color: var(--background-color);
  color: var(--text-color);
}

body > header {
  border-bottom: var(--scheme-dark-blue) 1px solid;
  margin-bottom: 0.5rem;
  background-color: var(--scheme-dark-blue-lightened);
  padding-block-end: 0.5rem;
  padding-block-start: 0.5rem;
}

header strong {
  font-size: 2rem;
  color: var(--scheme-sand-lightened);
  font-family: var(--header-font);
}

header #menu li {
  padding: var(--pico-nav-element-spacing-horizontal);
  margin-left: 0.25rem;
}

header #menu li:hover {
  background-color: var(--scheme-sand-lightened);
  color: var(--scheme-dark-blue-lightened);
}

header #menu li:hover a {
  text-decoration: none;
}


h1 {
  font-family: var(--header-font);
  --pico-font-weight: 600;
  --pico-color: var(--text-color);
}

fieldset legend, header #menu li {
  font-weight: 600;
  color: var(--scheme-dark-blue-lightened);
  background-color: white;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  border-color: var(--scheme-dark-blue-lightened);
  border-style: solid;
}

[role="button"], button, input[type="submit"] {
  --pico-primary-background: var(--button-color-primary);
  --pico-background-color: var(--button-color-primary);
}

[role="button"]:hover, button:hover, input[type="submit"]:hover {
  --pico-primary-background: var(--button-color-primary-light);
  --pico-background-color: var(--button-color-primary-light);
}

input:active {
  border-color: var(--scheme-bright-blue);
}

#autocomplete-container .autocomplete__input--focused {
  outline-color: var(--scheme-bright-blue);
}

a[role="!button"] {
  color: var(--scheme-bright-blue);
}

a[role="!button"]:hover {
  color: var(--scheme-bright-blue-lightened);
  text-decoration-color: var(--scheme-bright-blue-lightened);
}

.message-success {
  border: var(--scheme-green) 1px solid;
  background-color: hsl(from var(--scheme-green) h s calc(l + 40));
}

.message-info {
  border: var(--scheme-blue) 1px solid;
  background-color: hsl(from var(--scheme-blue) h s calc(l + 40));
}

.message-warning {
  border: hsl(from var(--scheme-orange) h s calc(l - 40)) 1px solid;
  background-color: var(--scheme-orange);
}

.message-error {
  border: var(--scheme-red) 1px solid;
  background-color: hsl(from var(--scheme-red) h s calc(l +  40));
}

.margin-top-only {
  margin-top: var(--pico-typography-spacing-vertical);
  margin-bottom: 0;
}

label summary span {
  border-radius: 50%;
  width: 1rem;
  height: 1rem;
  padding: 0 .5px;

  background: var(--scheme-blue-very-lightened);
  border: var(--scheme-dark-blue);
  color: var(--scheme-dark-blue);
  text-align: center;

  vertical-align: middle;
  margin-right: -0.5rem;
}

details {
  float: left;
  vertical-align: middle;
  margin-bottom: auto;
  padding: 0.25rem 0;
}

details summary::after {
  display: inline;
  float: left;
}

label span {
  float: left;
  margin-right: 0.5rem;
  vertical-align: middle;
}

label {
  min-height: 1.5rem;
  margin-top: 0.5rem;
}

article header {
  font-weight: bold;
}

.grid article a[role="button"] {
  width: 100%;
}
