:root {
  --primary: #1d4289;
  --background: #ffffff;
  --foreground: #282828;
  --error: crimson;
  --success: #d4fbc9;
  --muted: #6c757d;
}

html {
  -webkit-text-size-adjust: 100%;
  -moz-tab-size: 4;
  tab-size: 4;
  box-sizing: border-box;
}

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: inherit;
}

*:focus-visible {
  outline: cornflowerblue solid 3px;
  outline-offset: 2px;
}

h1 + *,
h2 + *,
h3 + *,
p + * {
  margin-top: 1rem;
}

hr {
  height: 0;
  color: inherit;
}

/**
Add the correct text decoration in Chrome, Edge, and Safari.
*/
abbr[title] {
  text-decoration: underline dotted;
}

/**
Add the correct font weight in Edge and Safari.
*/
b,
strong {
  font-weight: bolder;
}

/**
1. Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
2. Correct the odd 'em' font sizing in all browsers.
*/
code,
kbd,
samp,
pre {
  font-family:
    ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 1em;
}

/**
Add the correct font size in all browsers.
*/
small {
  font-size: 80%;
}

/**
Prevent 'sub' and 'sup' elements from affecting the line height in all browsers.
*/
sub,
sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}

sub {
  bottom: -0.25em;
}

sup {
  top: -0.5em;
}

/**
1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)
2. Correct table border color inheritance in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)
*/
table {
  text-indent: 0;
  border-color: inherit;
}

/**
1. Change the font styles in all browsers.
2. Remove the margin in Firefox and Safari.
*/
button,
input,
optgroup,
select,
textarea {
  font-family: inherit;
  font-size: 100%;
  line-height: 1.15;
}

button,
select {
  text-transform: none;
}

/**
Correct the inability to style clickable types in iOS and Safari.
*/
button,
[type="button"],
[type="reset"],
[type="submit"] {
  -webkit-appearance: button;
}

/**
Remove the additional ':invalid' styles in Firefox.
See: https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737
*/
:-moz-ui-invalid {
  box-shadow: none;
}

/**
Add the correct vertical alignment in Chrome and Firefox.
*/
progress {
  vertical-align: baseline;
}

/**
Correct the cursor style of increment and decrement buttons in Safari.
*/
::-webkit-inner-spin-button,
::-webkit-outer-spin-button {
  height: auto;
}

/**
1. Correct the odd appearance in Chrome and Safari.
2. Correct the outline style in Safari.
*/
[type="search"] {
  -webkit-appearance: textfield;
  outline-offset: -2px;
}

/**
Remove the inner padding in Chrome and Safari on macOS.
*/
::-webkit-search-decoration {
  -webkit-appearance: none;
}

/**
1. Correct the inability to style clickable types in iOS and Safari.
2. Change font properties to 'inherit' in Safari.
*/
::-webkit-file-upload-button {
  -webkit-appearance: button; /* 1 */
  font: inherit; /* 2 */
}

/*
Add the correct display in Chrome and Safari.
*/
summary {
  display: list-item;
}

html {
  background: var(--background);
  color: var(--foreground);
  font-family:
    system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif,
    "Apple Color Emoji", "Segoe UI Emoji";
  font-size: 125%;
}

body {
  line-height: 1.5;
  display: grid;
  grid-template-columns: 1fr min(45rem, 90%) 1fr;
  grid-template-rows: auto 1fr auto;
  min-height: 100vh;
  margin: 0;
  background-image: url("/images/bubble_chamber-666x2048.webp");
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
  background-attachment: fixed;
}

/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Content sectioning
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: bold;
  margin-top: 1.5em;
  margin-bottom: 1.25em;
  text-align: center;
}

h1 {
  font-size: 2rem;
}

h2 {
  font-size: 1.75rem;
}

h3 {
  font-size: 1.5rem;
}

nav {
  margin: 0 auto;
  max-width: min(45rem, 90%);
}
nav menu {
  display: flex;
  flex-direction: row;
  justify-content: space-around;
  align-items: baseline;
  list-style: none;
  margin: 0;
  padding: 0;
  list-style: none;
}
nav a {
  text-decoration: none;
  color: var(--foreground);
}
nav a:hover {
  text-decoration: underline;
  color: var(--foreground);
}
nav a:visited {
  color: var(--foreground);
}

/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Text block content
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/* Overall styling, e.g. vertical spacing */
p,
ol,
ul,
pre,
blockquote,
figure,
hr,
dl {
  margin: 0.75em 0;
}

ol,
ul {
  padding-left: 2em;
}

li {
  margin: 1.2em 0;
}

/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Inline text semantics
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
a {
  color: var(--primary);
}

a:visited {
  color: var(--primary);
}

/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Embedded content
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}

/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Forms
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
label {
  display: block;
  margin: 0.4em 0 0.2em;
}

/* Overall styling, e.g. vertical spacing */
input,
textarea,
select,
button {
  border-radius: 0.25rem;
}

/* `textarea` and `input` elements that share a similar look and similar styling
capabilities */
/* - common styling */
textarea,
input[type="text"],
input[type="password"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="search"],
input[type="url"],
input[type="date"],
input[type="datetime-local"],
input[type="month"],
input[type="week"],
input[type="time"] {
  border: 1px solid var(--muted);
  padding: 0.4em;
  max-width: 100%;
  box-shadow: inset 0px 1px 4px var(--muted);
}
@media (max-width: 640px) {
  textarea,
  input[type="text"],
  input[type="password"],
  input[type="email"],
  input[type="tel"],
  input[type="number"],
  input[type="search"],
  input[type="url"],
  input[type="date"],
  input[type="datetime-local"],
  input[type="month"],
  input[type="week"],
  input[type="time"] {
    width: 100%;
  }
}

textarea {
  width: 100%;
}

.anchor-btn,
button,
input[type="submit"] {
  display: block;
  width: fit-content;
  cursor: pointer;
  border: none;
  border-radius: 0.25rem;
  background-color: var(--primary);
  color: var(--background);
  text-decoration: none;
  padding: 0.5rem 1rem;
  margin: 0.5rem 0;

  &:visited {
    color: var(--background);
  }

  &:hover {
    filter: opacity(0.9);
  }

  &:disabled {
    background-color: var(--muted);
    color: var(--foreground);
    cursor: not-allowed;
  }
}

.feature-list {
  padding: 0;
  margin-bottom: 4em;

  li + li {
    margin-top: 3em;
  }

  & li {
    list-style: none;
    text-align: center;
    & hgroup {
      display: flex;
      font-weight: bold;
      justify-content: center;
      align-items: center;

      & img {
        max-height: 6rem;
        margin: 1rem;
      }
    }
  }
}

.hidden {
  display: none;
}
