@import "./modern-normalize.css";

@font-face {
  font-family: 'Asap';
  font-style: normal;
  font-weight: 400;
  font-display: 'swap';
  src: local(''),
       url('/fonts/asap-v24-latin-regular.woff2') format('woff2') 
}
/* asap-700 - latin */
@font-face {
  font-family: 'Asap';
  font-style: normal;
  font-weight: 700;
  font-display: 'swap';
  src: local(''),
       url('/fonts/asap-v24-latin-700.woff2') format('woff2')
}

:root {
  --JELLY_BEAN: #2977b3;
  --LIGHTNING_YELLOW: #f7bf23;
  --BURNT_SIENNA: #ec624e;
  --BIG_STONE: #152734;
}

.visually-hidden {
  position: absolute !important;
  height: 1px;
  width: 1px;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}

html {
  line-height: 1.2;
  font-size: 16px;
  font-weight: 400;
  overflow: hidden;
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
  font-family: "Asap", sans-serif;
  overflow: auto;
  height: 100%;
  color: #3c3d3e;

  &.bg-image {
    background: #3c3d3e;
    background-image: url(/images/bg-smaller.jpg);
    background-size: cover;
    background-position: center;
    color: white;

    @media screen and (min-width: 768px) {
      background-image: url(/images/bg.jpg);
    }
  }

  &:before {
    content: "";
    display: block;
    position: absolute;
    top: 0;
    height: 10px;
    width: 100%;
    background-image: linear-gradient(
      to right,
      var(--JELLY_BEAN),
      var(--JELLY_BEAN) 33.333%,
      var(--LIGHTNING_YELLOW) 33.333%,
      var(--LIGHTNING_YELLOW) 66.666%,
      var(--BURNT_SIENNA) 66.666%
    );

    @media screen and (min-width: 480px) {
      height: 15px;
    }
  }
}

header {
  padding: 30px 50px;
  display: flex;
  justify-content: center;
  align-items: center;

  @media screen and (min-width: 768px) {
    justify-content: flex-start;
  }
}

main {
  width: 100%;
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding-bottom: 80px;

  @media screen and (min-width: 768px) {
    padding-top: 40px;
  }

  @media screen and (min-width: 1024px) {
    padding-bottom: 100px;
  }
}

.screenshots {
  overflow: auto;
  display: flex;
  gap: 20px;
  padding: 0 20px 40px;

  @media screen and (min-width: 480px) {
    gap: 40px;
    padding-left: 40px;
    padding-right: 40px;
  }
}

.screenshot {
  max-height: 60vh;

  @media screen and (min-width: 1024px) {
    animation: slide 40s infinite;
    opacity: 0;
    max-height: none;
    position: absolute;
    top: 10%;
    right: 10%;
    max-width: 400px;
    opacity: 0;

    &:nth-child(2) {
      animation-delay: 10s;
    }

    &:nth-child(3) {
      animation-delay: 20s;
    }

    &:nth-child(4) {
      animation-delay: 30s;
    }
  }

  @media screen and (min-width: 1300px) {
    transform: rotate(-10deg);
    max-width: none;
  }

  @media screen and (min-width: 1400px) {
    transform: rotate(-20deg);
  }
}

.photo-credit {
  position: absolute;
  bottom: 10px;
  right: 10px;
  color: #777;
  font-size: 12px;

  & a {
    color: inherit;
  }
}

.content {
  margin: 0 auto;
  width: 100%;
  max-width: 1400px;
  padding-left: 20px;
  padding-right: 20px;

  @media screen and (min-width: 1080px) {
    padding-left: 100px;
    padding-right: 100px;
  }
}

.content-inner {
  width: 100%;
  max-width: 500px;
  position: relative;
}

.highlight {
  color: var(--LIGHTNING_YELLOW);
}

h1 {
  font-size: 34px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.98;

  @media screen and (min-width: 480px) {
    font-size: 44px;
  }

  @media screen and (min-width: 768px) {
    font-size: 70px;
  }
}

h1,
p {
  margin: 0 0 26px;
  display: block;
}

ul,
ol {
  margin: 0 0 20px 20px;
  padding: 0;

  &.custom-bullets {
    list-style: none;
  }
}

ol {
  list-style-type: none;
  counter-reset: item;
  margin: 0;
  padding: 0;
}

ol > li {
  display: table;
  counter-increment: item;
  margin-bottom: 0.6em;
}

ol > li:before {
  content: counters(item, ".") ". ";
  display: table-cell;
  padding-right: 0.6em;    
}

li ol > li {
  margin: 0;
}

li ol > li:before {
  content: counters(item, ".") " ";
}

li::marker {
  font-family: 'Asap';
}

li {
  &:not(:last-child) {
    margin-bottom: 20px;
  }
}

p,
li {
  font-size: 20px;
  line-height: 1.4;
  font-weight: 700;

  .small-print & {
    font-size: 16px;
  }
}

a {
  color: inherit;
}

.emoji {
  margin-right: 10px;
}

.app-store-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 20px;
  margin: 40px auto 0;

  & img {
    display: block;
  }
}

footer {
  width: 100%;
  flex-shrink: 0;
  background: var(--BURNT_SIENNA);
  position: relative;

  @media screen and (min-width: 768px) {
    padding: 30px 56px 34px;
  }
}

.links {
  padding: 25px 28px 35px;
  display: flex;
  justify-content: space-between;

  @media screen and (min-width: 768px) {
    padding: 0;
    margin-bottom: 22px;
  }
}

.social {
  display: flex;
  align-self: flex-end;

  & a {
    color: white;
    transition: color 0.2s ease-in-out;

    &:hover {
      color: var(--LIGHTNING_YELLOW);
    }
  }

  & svg {
    width: 18px;
    height: 18px;
    display: block;
    margin-right: 20px;
    fill: currentColor;
  }
}

.footer-logo {
  width: 86px;
  height: 39px;

  @media screen and (min-width: 768px) {
    width: 118px;
    height: 54px;
  }
}

@media screen and (min-width: 768px) {
  .footer-logo-link {
    position: absolute;
    bottom: 34px;
    right: 56px;
  }
}

small {
  background: white;
  display: block;
  padding: 14px 28px;
  text-align: center;
  font-size: 10px;
  line-height: 1.5;

  @media screen and (min-width: 768px) {
    background: none;
    text-align: left;
    font-size: 14px;
    color: white;
    padding: 0;
    margin-right: 128px;
  }

  & a {
    color: black;
    text-decoration: underline;

    &:hover {
      color: var(--LIGHTNING_YELLOW);
    }

    @media screen and (min-width: 768px) {
      color: white;
    }
  }
}

@keyframes slide {
  10% {
    opacity: 1;
  }
  20% {
    opacity: 1;
  }
  30% {
    opacity: 0;
  }
}