/* Colors */
:root {
  --color-lilac: #d8c9e2;
  --color-blue: #22589a;
  --color-aqua: #31b1e3;
  --color-black: #000000;
  --color-white: #fff;
  --color-offwhite: #f9f9f9;

  --color-text: black;
  --color-text-light: hsla(0, 0%, 0%, 0.5);
}

.scheme-dark {
  --color-bg: var(--color-black);
  --color-text: white;
  --color-text-light: hsla(0, 0%, 100%, 0.5);
}

.scheme-blue {
  --color-bg: var(--color-blue);
  --color-text: white;
  --color-text-light: hsla(0, 0%, 100%, 0.5);
}

.scheme-aqua {
  --color-bg: var(--color-aqua);
  --color-text: black;
  --color-text-light: hsla(0, 0%, 0%, 0.5);
}

/* Spacing */
:root {
  --banner-height: 40px;
  --nav-height: 75px;
  --header-height: calc(var(--banner-height) + var(--nav-height));

  @media (min-width: 900px) {
    --banner-height: 28px;
  }
}

/* Typography */
:root {
  --font-s-size: 10px;
  --font-s-height: 12px;

  --font-b-size: 12px;
  --font-b-height: 14px;

  --font-m-size: 24px;
  --font-m-height: 28px;

  --font-l-size: 32px;
  --font-l-height: 36px;

  --font-xl-size: 48px;
  --font-xl-height: 52px;

  --cap-letter-spacing: 0.04em;

  @media (min-width: 600px) {
    --font-l-size: 40px;
    --font-l-height: 46px;

    --font-xl-size: 72px;
    --font-xl-height: 76px;
  }
}

body {
  font-family: "Supreme", sans-serif;
  font-size: var(--font-b-size);
  line-height: var(--font-b-height);
  color: var(--color-text);
  background-color: var(--color-offwhite);
}

section {
  color: var(--color-text);
}

.text-cap {
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.text-small {
  font-size: var(--font-s-size);
  line-height: var(--font-s-height);
}

.text-medium {
  font-size: var(--font-m-size);
  line-height: var(--font-m-height);
}

.text-large {
  font-size: var(--font-l-size);
  line-height: var(--font-l-height);
}

.text-extra-large {
  font-size: var(--font-xl-size);
  line-height: var(--font-xl-height);
}

.text-light {
  color: var(--color-text-light);
}

.typeset {
  > * {
    max-width: 55ch;
  }
  > *:not(:last-child) {
    margin-bottom: 1em;
  }
}

.prose {
  > * {
    max-width: 55ch;
    /* margin-inline: auto; */
  }
  > *:not(:first-child) {
    margin-top: 1em;
  }

  h1 {
    font-size: var(--font-xl-size);
    line-height: var(--font-xl-height);
  }

  h2 {
    font-size: var(--font-l-size);
    line-height: var(--font-l-height);
  }

  h3 {
    font-size: var(--font-m-size);
    line-height: var(--font-m-height);
  }

  p {
  }
}

.icon {
  height: 0.75em;
}

/* UI */

.call-to-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;

  transition: all 0.2s ease;

  .icon {
    height: 1em;
    transition: all 0.2s ease;
  }

  &:hover {
    .icon {
      transform: translateX(2px);
    }
  }
  &:active {
    color: var(--color-text-light);
    transform: scale(0.97);
  }
}

.text-input {
  /* transition: border-color 0.2s ease; */
  /* border-bottom: 1px solid var(--color-text-light); */
  padding-bottom: 4px;
  width: 100%;
  position: relative;

  /* &:focus {
    border-color: var(--color-text);
  } */

  &::placeholder {
    color: var(--color-text-light);
  }
}

.text-input-wrapper {
  position: relative;

  &::before {
    background-color: var(--color-text-light);
    bottom: 0;
    content: "";
    height: 1px;
    left: 0;
    position: absolute;
    transform: scaleX(1);
    transform-origin: bottom right;
    transition: transform 0.25s ease-out;
    width: 100%;
  }

  &::after {
    background-color: var(--color-text);
    bottom: 0;
    content: "";
    height: 1px;
    left: 0;
    position: absolute;
    transform: scaleX(0);
    transform-origin: bottom right;
    transition: transform 0.5s ease-out;
    width: 100%;
  }

  &:focus::after,
  &:focus-within::after {
    transform: scaleX(1);
    transform-origin: bottom left;
  }
}

/* Utils */

.bg-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fill-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar {
  width: 150px;
  max-width: 75%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 100%;
}

.alert.success {
}

.alert.error {
}
