/* CSS Reset, based on https://www.joshwcomeau.com/css/custom-css-reset/ */

*, *::before, *::after {
  box-sizing: border-box;
}
*:not(dialog) {
  margin: 0;
}
body {
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
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;
}

/* Color palette from https://coolors.co/dad6d6-92bfb1-f4ac45-694a38-a61c3c */
:root {
    --main-bg-color: #694A38;
    --main-fg-color: #DAD6D6;
    --main-highlight: #A61C3C;
    --secondary-highlight: #F4AC45;
    --secondary-bg-color: #92BFB1;
}

/* Fonts */
@font-face {
    font-family: 'Carattere-Regular';
    src: url('./Carattere-Regular.ttf');
}

@font-face {
    font-family: "Aileron";
    src: url("Aileron-Regular.otf");
}
@font-face {
    font-family: "Aileron";
    src: url("Aileron-Bold.otf");
    font-weight: bold;
}
@font-face {
    font-family: "Aileron";
    src: url("Aileron-Italic.otf");
    font-style: italic;
}

/* General layout */
@supports (display: flex) {
  @media screen and (min-width: 900px) {
      #container {
        display: flex;
        justify-content: center;
        align-items: stretch;
        gap: 30px;
      }
      main {
            max-width: 1000px;
            padding: 15px;
            flex-grow: 1;
        }

        nav {
                flex-grow: 1;
                max-width: 300px;
                padding: 15px;
        }
  }
}

@media all and (max-width: 900px){
    main {
        max-width: 90%;
        padding: 15px;
        margin: auto;
    }
    nav {
        max-width: 90%;
        padding: 15px;
        margin: auto;
    }
}

/* Everything else */

body {
    background-color: var(--main-bg-color);
    color: var(--main-fg-color);
    font-family: Aileron, sans-serif;

    a {
        color: var(--main-highlight);
        border: 1px var(--main-highlight) dashed;
        padding: 1px;
    }

    p {
        margin-bottom: 8px;
    }

    .hl {
        color: var(--secondary-highlight);
    }

    header {
        border-bottom: 5px var(--secondary-highlight) solid;
        font-family: 'Carattere-Regular', cursive;
        text-align: center;
        padding: 15px;
        width: 90%;
        margin: 15px auto;
        font-size: 1.4em;
    }

    #container {
        main {
            background: rgba(0, 0, 0, 0.5);
            box-shadow: -4px -4px 2px var(--main-highlight);
        }

        nav {
                background: rgba(0, 0, 0, 0.5);
                box-shadow: -4px -4px 2px var(--main-highlight);
                h2 {
                    font-family: "Carattere-Regular", cursive;
                    font-size: 2em;
                }
                ul {
                    padding: 0px;
                    li {
                        margin-bottom: 5px;
                        list-style-type: none;
                    }
                }
        }
    }

    footer {
        width: 100%;
        margin: auto;
        padding: 15px;
        border-top: 3px var(--main-highlight) solid;
        text-align: center;
        position: fixed;
        background: rgba(0, 0, 0, 0.5);
        bottom: 0px;
    }
}
