/* CSS reset */

*, *::before, *::after {
  box-sizing: border-box;
}

*:not(dialog) {
  margin: 0;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    interpolate-size: allow-keywords;
  }
}

body {
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

p {
  text-wrap: pretty;
}

h1, h2, h3, h4, h5, h6 {
  text-wrap: balance;
}

#root, #__next {
  isolation: isolate;
}


/* Actual styles */
body    {
    font-family: Arial, Helvetica, sans-serif;
    padding: 1em 1.25em;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    justify-content: space-between;
}

form    {
    display: flex;
    flex-direction: column;

    > * + * {
        margin-top: 0.5em;
    }
}

textarea    {
    font-family: monospace;
    width: 80%;
    min-height: 16rem;
    padding: 0.5em;
}


@media (max-width: 1023px)   {
    textarea    {
        width: 100%;
    }
}

button[type="submit"]    {
    border-radius: 0.5em;
    corner-shape: squircle;
    padding: 0.25em 1em;
    background: darkslategray;
    border: none;
    color: white;
    cursor: pointer;

    &[disabled] {
        opacity: 0.5;
        cursor: not-allowed;
    }
}

.data-submitted {

    margin-top: 1em;
    color: darkslategrey;
    font-weight: bold;

    &:not(.show)    {
        display: none;
    }
}

.hint   {
    font-size: 0.9em;
    color: #444;
    margin-bottom: 1.5em;
}

.cipher-check   {
    max-width: 100%;
    word-wrap: break-word;
}

a[href] {
    color:darkslategray;
    &:hover {
        color: black;
    }
}

h1  {
    font-weight: normal;
    margin-bottom: 0.5em;

    span    {
        color:darkslategrey;
        font-weight: bold;
        font-style: italic;
    }
}

ul  {

    margin-left: 0.5em;
    list-style: none;
    padding-left: 0;

    li  {
        position: relative;
        padding-left: 1.25em;

        &::before   {
            position: absolute;
            left: 0;
            content: '–';
        }

        margin-top: 0.25em;
    }
}

footer  {
    text-align: center;
    font-size: 0.8em;
    opacity: 0.3;
    pointer-events: none;
    user-select: none;
}