/* Reset */

*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  font-size: inherit;
  font-style: inherit;
  font-weight: inherit;

  padding: 0;  
  margin: 0;
}

html {
  min-height: 100vh;
}

body {
  display: flow-root; /* prevent margin collapse */

  min-height: 100vh;
}

/* Styles */

body {
  font-family: Helvetica, sans-serif;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Modak', Helvetica, sans-serif;
  font-weight: normal;

  margin: 1rem 0;

  line-height: 1;
}

p {
  margin-bottom: 1rem;
}

ul {
  margin-left: 1rem;

  line-height: 1.5;
}

header {
  --background-width: min(calc(1600px - 10vw), 100vw);
  --height: calc(var(--background-width) * 0.25 + 4rem);

  background: #00a1fe;
  background-image: url('images/header-dice.png');
  background-size: var(--background-width) auto;
  background-position: bottom;
  background-repeat: no-repeat;

  color: white;

  height: var(--height);

  h1 {
    --font-size: calc(var(--height) * 0.3);
    font-size: var(--font-size);
   
    margin: 0;
    padding-top: 0.5em;

    text-align: center;

    @supports (-webkit-text-stroke: 1px black) {
      -webkit-text-fill-color: white;
      -webkit-text-stroke: calc(1em * 0.07) black;
    }
  }
}

footer {
  max-width: 1600px;

  padding: 0 4rem;

  text-align: center;
}

section {
  max-width: 1600px;

  margin: 0 auto 2rem;
  padding: 0 5vw;

  h2 {
    font-size: 3rem;
  }

  h3 {
    font-size: 2rem;
  }

  h2, h3 {
    @supports (-webkit-text-stroke: 3px black) {
      -webkit-text-fill-color: white;
      -webkit-text-stroke: calc(1em * 0.07) black;
    }
  }
}

section.subheader {
  display: flex;
  flex-direction: column;
  justify-content: center;

  padding-top: 4rem;

  font-size: 1.5rem;
  text-align: center;
}

.playdate-screenshot {
  position: relative;
  display: inline-block;

  padding: 20px;

  background: black;
  border-radius: 10px;

  max-width: 100%;

  /* This method of simulating a Playdate screenshot comes from the Playdate Catalog website */
  &::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #948a78;
    opacity: 34%;
    border-radius: 10px;
  }
}

section.screenshots {
  .screenshots-list {
    .playdate-screenshot {
      margin: 0 1rem 1rem 0;

      img {
        max-width: 100%;
      }
    }
  }
}

table {
  thead {
    vertical-align: bottom;

    font-weight: bold;
  }

  tbody tr:nth-child(odd) {
    background: #eee;
  }

  th, td {
    padding: 0.5em 0.5em;

    text-align: center;
  }
}
/* devanagari */
@font-face {
  font-family: "Modak";
  font-style: normal;
  font-weight: 400;
  font-stretch: normal;
  src: url("fonts/modak-normal-400-devanagari.woff2") format("woff2");
  unicode-range: U+0900-097F, U+1CD0-1CF9, U+200C-200D, U+20A8, U+20B9, U+20F0, U+25CC, U+A830-A839, U+A8E0-A8FF, U+11B00-11B09;
  font-display: swap;
}

/* latin-ext */
@font-face {
  font-family: "Modak";
  font-style: normal;
  font-weight: 400;
  font-stretch: normal;
  src: url("fonts/modak-normal-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
  font-display: swap;
}

/* latin */
@font-face {
  font-family: "Modak";
  font-style: normal;
  font-weight: 400;
  font-stretch: normal;
  src: url("fonts/modak-normal-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
  font-display: swap;
}
