@font-face {
  font-family: 'Montserrat';
  src: url('fonts/Montserrat-Bold.woff2') format('woff2');
  font-weight: 700;
  font-display: swap;
  font-style: normal;
}

:root {
  /* Colors */
  --gray-blue-900: hsl(232 13% 33%);
  /* Darkened color to pass AA contrast ratio */
  --gray-blue-600: hsl(233 13% 48%);
  --gray-blue-150: hsl(234 14% 74%);
  --gray-blue-100: hsl(240 78% 98%);
  /* Darkened color to pass AA contrast ratio */
  --purple-blue: hsl(237 63% 60%);
  --white: hsl(0 0% 100%);

  /* Border, Gradient, Radius */
  /* Darkened color to pass AA contrast ratio */
  --gradient: linear-gradient(135deg, #6c70b4 0.06%, #6167db 100.06%);
  --gradient-hover: linear-gradient(135deg, #a2a7f0, #a6a6e7);
  --radius-s: 0.375rem;
  --radius-m: 0.625rem;
  --shadow: 0px 20px 40px 0px rgba(212, 210, 244, 0.5);
  --stroke-width: 1px;
  --stroke-solid: var(--stroke-width) solid rgba(109, 112, 141, 0.2);
  --stroke-inverted: var(--stroke-width) solid
    rgba(255, 255, 255, 0.25);
  --stroke-hover: var(--stroke-width) solid var(--purple-blue);
  --stroke-inverted-hover: var(--stroke-width) solid var(--white);
  --stroke-dotted: var(--stroke-width) dotted var(--gray-blue-900);
  --stroke-dotted-inverted: var(--stroke-width) dotted var(--white);

  /* Spacing */
  --space-xxxs: 0.75rem;
  --space-xxs: 1rem;
  --space-xs: 1.5rem;
  --space-s: 1.875rem;
  --space-m: 2rem;
  --space-l: 2.5rem;
  --space-xl: 3.5rem;
  --space-xxl: 4rem;
  --space-xxxl: 5rem;

  /* Typography */
  --font-base: 'Montserrat', sans-serif;
  --leading-micro: 0.9;
  --leading-fine: 1.2;
  --leading-standard: 1.8;
  --text-xl: 4.5rem;
  --text-large: 2.5rem;
  --text-medium: 2rem;
  --text-small: 1.125rem;
  --text-xs: 0.9375rem;
  --text-xxs: 0.8125rem;
}

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

html {
  -moz-text-size-adjust: none;
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
}

body,
h1,
h2,
h3,
p,
ul,
fieldset,
legend {
  margin: 0;
  padding: 0;
}

fieldset {
  border: none;
}

a {
  text-decoration: underline;
  color: currentColor;
}

a:hover {
  color: var(--purple-blue);
  text-decoration: none;
}

a:focus {
  outline: var(--stroke-dotted);
  outline-offset: 2px;
}

/* Screen reader styles */
.sr-only {
  border: 0;
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

body {
  background-color: var(--gray-blue-100);
  color: var(--gray-blue-600);
  font-family: var(--font-base);
  font-size: var(--text-xs);
  line-height: var(--leading-standard);
  min-height: 100vh;
}

.multi-bg {
  background-image: url('images/bg-top.svg');
  background-repeat: no-repeat;
  background-size: 29.5rem 47.3125rem;
  background-position: top -3rem right -15rem;

  @media (min-width: 75rem) {
    background-image: url('images/bg-top.svg'),
      url('images/bg-bottom.svg');
    background-repeat: no-repeat, no-repeat;
    background-size: 29.5rem 47.3125rem, 22rem 18rem;
    background-position: top right, bottom left;
  }
}

h2 {
  font-size: var(--text-medium);
  line-height: var(--leading-fine);
  padding-block-start: var(--space-xxl);
  padding-block-end: var(--space-l);
  text-align: center;
}

.annual-plan {
  text-align: right;
}

.radio-switch {
  display: grid;
  justify-content: center;
  align-items: center;
  grid-template-columns: 1fr 56px 1fr;
  column-gap: var(--space-xs);
  margin-block-end: var(--space-xxxl);

  label {
    cursor: pointer;
  }

  input[type='radio'] {
    cursor: pointer;
    display: inline-block;
    margin-inline-end: -2px;
    height: 100%;
    opacity: 0;
    position: relative;
    width: 50%;
    z-index: 1;

    &:focus ~ .radio-switch__background {
      outline: var(--stroke-dotted);
      outline-offset: 2px;
    }

    &:hover ~ .radio-switch__background {
      background: var(--gradient-hover);
    }
  }
}

.radio-switch__wrapper {
  display: inline-block;
  height: 2rem;
  position: relative;
  width: 3.5rem;
}

.radio-switch__circle {
  background-color: var(--white);
  border-radius: 50%;
  height: 1.5rem;
  position: absolute;
  top: 4px;
  left: 4px;
  right: 100%;
  transition: all 0.1s ease-out;
  width: 1.5rem;
  z-index: 2;
}

.radio-switch__background {
  background: var(--gradient);
  border-radius: 15px;
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  z-index: 0;
}

#monthly:checked ~ .radio-switch__circle {
  right: 0;
  left: 28px;
}

.tier {
  background-color: var(--white);
  border-radius: var(--radius-m);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin-block-end: var(--space-m);
  width: 20.5rem;
  padding-block: var(--space-m);
  padding-inline: var(--space-m);
  text-align: center;

  @media (min-width: 75rem) {
    width: 21.875rem;
  }
}

.tier__feature-list {
  list-style-type: none;
  margin-block-end: var(--space-m);
}

.tier__title {
  font-size: var(--text-small);
  margin-block-end: var(--space-xs);
}

.tier__feature-list li {
  border-bottom: var(--stroke-solid);
  padding-block: var(--space-xs);
}

.tier__feature-list li:first-child {
  color: var(--gray-blue-900);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xxxs);
  font-size: var(--text-xl);
  letter-spacing: -2.16px;
  line-height: var(--leading-micro);
  padding-block-start: 0;
  padding-block-end: var(--space-m);
  width: 100%;
}

.tier__feature-list li:first-child::before {
  content: '\0024';
  font-size: var(--text-large);
}

:has(#monthly:checked) .basic-price::after {
  content: '19.99';
}

:has(#annually:checked) .basic-price::after {
  content: '199.99';
}

:has(#monthly:checked) .professional-price::after {
  content: '24.99';
}

:has(#annually:checked) .professional-price::after {
  content: '249.99';
}

:has(#monthly:checked) .master-price::after {
  content: '39.99';
}

:has(#annually:checked) .master-price::after {
  content: '399.99';
}

.inverted {
  background: var(--gradient);
  color: var(--white);

  @media (min-width: 75rem) {
    padding-block-start: var(--space-xl);
    padding-block-end: var(--space-xl);
  }
}

.inverted ul li {
  border-bottom: var(--stroke-inverted);
}

.inverted ul li:first-child {
  color: var(--white);
}

.button {
  background: var(--gradient);
  border-radius: var(--radius-s);
  border: var(--stroke-width) solid transparent;
  color: var(--white);
  font-size: var(--text-xxs);
  letter-spacing: 1.393px;
  padding-block: calc(var(--space-xxxs) + 0.125rem);
  text-decoration: none;
  text-transform: uppercase;
  transition: all 0.2s ease-out;
}

.btn:active {
  transform: scale(99%);
}

.button:hover {
  background: var(--white);
  border: var(--stroke-hover);
  color: var(--purple-blue);
}

.button:focus {
  outline: var(--stroke-dotted);
  outline-offset: 2px;
}

.inverted .button {
  background: var(--white);
  border: var(--stroke-inverted);
  color: var(--purple-blue);
}

.inverted .button:hover {
  background: none;
  border: var(--stroke-inverted-hover);
  color: var(--white);
}

.inverted .button:focus {
  outline: var(--stroke-dotted-inverted);
}

.wrapper {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;

  @media (min-width: 75rem) {
    flex-direction: row;
  }
}

.attribution {
  text-align: center;
  a {
    text-wrap: nowrap;
  }
}
