// wrapper
.footer__wrapper {
  @include font-style('body--m');
  padding-bottom: $baseline * 4;
  padding-top: $baseline * 2.5;
}

// grid
.footer__grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;

  &:first-child {
    padding-bottom: $spacing--l;
  }
}

// collapsible
.footer__column {
  width: 100%;
}

// info
.footer__info {
  margin-bottom: $spacing--m;
  order: 2;
  width: 100%;

  p:last-child {
    margin-bottom: 0;
  }
  // prevent blue color for auto-generated phone number hyperlinks
  a[href^='tel'] {
    color: inherit;
    text-decoration: inherit;
  }

  svg {
    margin-right: 5px;
  }
}

// bottom navigation
.footer__bottom-nav {
  margin-bottom: 0;
  order: 3;
  width: 100%;

  li {
    margin-bottom: $spacing--xs;
  }
}

// social media
.footer .social__list {
  order: 1;
  margin-bottom: $spacing--m;
  width: 100%;

  svg {
    transition: fill $transition-duration--fast ease-out;
  }
}

// footer small
.footer--s {
  .footer__wrapper {
    padding-bottom: $baseline * 4;
    padding-top: $baseline * 4;
  }

  .footer__grid:first-child {
    border-bottom: 0;
    padding-bottom: 0;
  }
}

// viewport s/m
@include viewport--l('inversed') {
  .footer {
    &__grid.divider {
      border-bottom: 0;
    }
  }
}

// viewport l
@include viewport--l {
  // wrapper
  .footer__wrapper {
    padding-bottom: $spacing--l;
    padding-top: $spacing--xl;
  }

  // grid
  .footer__grid {
    & + & {
      margin-top: $spacing--m;
    }
  }

  // collapsible
  .footer__column {
    width: grid-columns(3, 12);

    .collapsible__button {
      display: none;
    }
  }

  // social media
  .footer .social__list {
    flex-wrap: wrap;
  }

  // info
  .footer__info p {
    margin-bottom: $spacing--m;
    width: 100%;
  }

  // bottom navigation
  .footer__bottom-nav {
    ul {
      display: flex;
      flex-wrap: wrap;
      margin-bottom: -($spacing--xs);

      li {
        margin-top: 0;
        margin-right: 30px;
      }
    }
  }

  // footer small
  .footer--s .footer__wrapper {
    padding-bottom: $spacing--l;
    padding-top: $spacing--l;
  }
}

// override width
.footer__column .extensive-link-list__item {
  width: 100%;
}

// background mappings
@include footer-background-mapping;
