@layer reset, page, utility;

@import "../node_modules/@acab/reset.css/index.css" layer(reset);

:root {
  color-scheme: dark;
  --system-sans: system-ui, sans-serif;
  --system-serif: Charter, "Bitstream Charter", "Sitka Text", Cambria, serif;
  --color-accent: light-dark(#c627be, #d845d1);
  --color-background: light-dark(#f7f3f0, #0d0d0d);
  --color-surface: light-dark(#f7f3f0, #161616);
  --color-text: light-dark(#2d2a29, #f7f3f0);
  --color-text-reduced: light-dark(#2d2a29, #c9c5c2);
  --opacity-text-reduced: 0.7;
  --border-container: 1px solid
    color-mix(in hsl, var(--color-surface), var(--color-accent) 20%);
}

html {
  background: linear-gradient(180deg, #0d0a0d 0%, #160914 100%);
}

body {
  color: var(--color-text);
  font-family: var(--system-sans);
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100dvh;
  padding: 24px;
}

.body-large {
  font-size: 20px;
  font-style: normal;
  font-weight: 510;
}

a,
a:visited {
  color: var(--color-accent);
}

.button {
  text-decoration: none;
  border: var(--border-container);
  padding: 8px 16px;
  border-radius: 12px;
  width: fit-content;
  font-weight: 650;
  transition: all 180ms;

  &:hover {
    scale: 1.03;
  }
  &:active {
    scale: 0.97;
  }

  &:is(.primary) {
    background-color: var(--color-accent);
    color: var(--color-background);
  }
}

main {
  width: 100%;
  max-width: 960px;
  text-wrap: balance;
}

main:is(.homepage) {
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 40px;
  padding: 64px 0;

  .appicon {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
    font-size: 20px;
    font-style: normal;
    font-weight: 590;

    img {
      width: 56px;
      max-width: 100px;
      aspect-ratio: 1;
    }
  }

  .intro {
    text-align: center;
    align-items: center;
    display: flex;
    flex-direction: column;
    gap: 8px;

    .button {
      margin-top: 12px;
    }
  }

  .preview {
    width: 500px;
    max-width: 100%;
  }

  .bento {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;

    div {
      background: #170f16;
      border-radius: 24px;
      display: flex;
      flex-direction: column;
      align-items: center;
      text-align: center;
      padding: 32px 48px;

      &:nth-child(1) {
        padding-bottom: 0;
        justify-content: flex-end;

        @media screen and (max-width: 600px) {
          order: 2;
        }
      }

      &:nth-child(2) {
        padding-top: 0;
        justify-content: flex-start;
      }
    }

    @media screen and (max-width: 600px) {
      grid-template-columns: 100%;
    }
  }

  h1 {
    font-size: 32px;
    line-height: 1;
    letter-spacing: -0.26px;

    span {
      font-style: italic;
      color: var(--color-accent);
    }
  }
}

main:is(.legal) {
  padding: 24px 0;

  *:not(br) {
    margin-bottom: 1.5rem;
  }
}

main:is(.support) {
  padding: 64px 0;
  h1 {
    margin-bottom: 16px;
  }
}

#faq {
  margin: 32px 0;
  display: grid;
  gap: 8px;
  width: 100%;

  details {
    width: 100%;
    padding: 16px;
    border: var(--border-container);
    border-radius: 12px;

    &[open] {
      p {
        margin-top: 12px;
      }
    }
  }

  summary {
    font-weight: bold;
  }
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--system-sans);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.26px;
}

p {
  color: var(--color-text-reduced);
  line-height: 1.5;
}

header {
  position: sticky;
  top: 8px;
  width: 100%;
  max-width: 960px;
  padding: 16px;
  border: var(--border-container);
  background: #100a0fbf;
  backdrop-filter: blur(10px);
  border-radius: 999px;

  .logo {
    display: flex;
    gap: 4px;
    color: var(--color-text);

    img {
      width: 24px;
      height: 24px;
    }
  }

  nav {
    width: 100%;
    max-width: 960px;
    padding: 0 8px;
    display: flex;
    gap: 12px;
    justify-content: space-between;
    align-items: center;

    a {
      font-weight: bold;
      text-decoration: none;

      &:hover {
        text-decoration: underline;
      }
    }

    ul {
      list-style: none;
      display: flex;
      gap: 16px;
    }
  }
}

footer {
  margin-top: 32px;
  display: flex;
  color: var(--color-text);
  gap: 16px;
  font-size: 14px;

  div {
    opacity: 0.6;
    text-align: center;
  }

  a {
    opacity: var(--opacity-text-reduced);
    color: inherit !important;
  }

  @media screen and (max-width: 500px) {
    flex-direction: column;
    align-items: center;
  }
}
