.tabby {
  position: relative;
  padding: 70px 0 55px 0;
}

.tabby__title {
  font: var(--demi);
  font-weight: 700;
  letter-spacing: .9px;
  text-transform: uppercase;
  margin-bottom: 60px;
  text-align: center;
}

.tabby__items {
  max-width: var(--max-width);
  margin: 0 auto;
}

.tabby__items-inner {
  display: flex;
  flex-wrap: wrap;
  padding: 0 var(--offset-x);
  box-sizing: border-box;
  row-gap: 35px;
}

.tabby__item__tab {
  text-transform: uppercase;
  cursor: pointer;
  color: rgba(104,150,168,.5);
  transition: color .25s;
  width: 100%;
}

.tabby__item__tab::after {
  content: '';
  display: inline-block;
  height: 3px;
  width: 0;
  background-color: var(--pen);
  vertical-align: middle;
  margin-left: 25px;
  transition: width .25s;
  border-top-left-radius: 3px;
  border-top-right-radius: 3px;
  border-bottom-left-radius: 3px;
  border-bottom-right-radius: 3px;
}

input:checked + .tabby__item__tab {
  color: var(--pen);
}

input:checked + .tabby__item__tab::after {
  animation: circleToLine 5s linear forwards;
}

.tabby__item__content {
  display: none;
  order: 99;
  width: 100%;
  margin: 30px 0;
}

.tabby__item__texts {
  display: grid;
  align-content: start;
  counter-reset: keys;
}

.tabby__item__text {
  font: var(--tall);
  min-height: 122px;
}

.tabby__item__text span {
  display: block;
  padding-top: 20px;
}

.tabby__item__text::before {
  font-weight: 700;
  counter-increment: keys;
  content: counter(keys, decimal-leading-zero);
  border-top: 2px solid var(--pen);
  padding: 5px 0;
}

.tabby__item__link {
  margin-top: 60px;
}

input:checked + label + .tabby__item__content {
  display: block;
}

@media (max-width: 1024px) {
  .tabby__item__texts {
    row-gap: 50px;
  }

  .tabby__item__tab {
    font: var(--tall);
    font-weight: 700;
  }
}

@media (max-width: 650px) {
  .tabby__item__tab {
    font: var(--petit);
    font-weight: 700;
  }
}

@media (min-width: 651px) and (max-width: 1024px) {
  .tabby__items-inner {
    width: 65%;
  }

  .tabby__item__content::before {
    width: 35%;
  }
}

@media (min-width: 651px) {
  .tabby__items-inner {
    margin-left: auto;
  }

  .tabby__item__content::before {
    content: '';
    display: block;
    height: 100%;
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    background-color: var(--background-color);
    clip-path: polygon(0% 0%, 75% 0%, 100% 50%, 75% 100%, 0% 100%);
  }
}

@media (min-width: 1025px) {
  .tabby__item__texts {
    grid-template-columns: 1fr 1fr;
    row-gap: 95px;
    column-gap: 10px;
  }

  .tabby__item__content::before {
    width: 45%;
  }

  .tabby__item__tab {
    font: var(--grande);
  }

  .tabby__items-inner {
    width: 54%;
  }
}

@media (min-width: 1440px) {
  .tabby__item__tab {
    width: 50%;
  }
}

@keyframes circleToLine {
  0% {
    width: 3px;
  }
  10% {
    width: 3px;
  }
  100% {
    width: 80px;
  }
}