/**
 * Licensed to the Apache Software Foundation (ASF) under one
 * or more contributor license agreements.  See the NOTICE file
 * distributed with this work for additional information
 * regarding copyright ownership.  The ASF licenses this file
 * to you under the Apache License, Version 2.0 (the
 * "License"); you may not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *
 *   http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing,
 * software distributed under the License is distributed on an
 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 * KIND, either express or implied.  See the License for the
 * specific language governing permissions and limitations
 * under the License.
 */
@import "colors";
@import "media";

footer {
  min-height: unset;

  .footer-section {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;

    span {
      @extend .bodytext__medium--white;
    }

    &__media-section {
      padding: 60px 60px 30px;
      background-color: map-get($colors, greyish-brown);

      &--link {
        margin-right: 30px;
      }

      &--button-with-text {
        display: flex;
        align-items: center;
      }

      &--text {
        margin-right: 20px;
      }
    }

    &__policies-section {
      padding: 30px 60px;
      background-color: map-get($colors, slate-grey);
      font-size: 12px;
      flex-direction: column !important;

      span {
        font-size: 12px;
      }

      &--policies {
        display: flex;
      }

      &--policy-item {
        &::before {
          content: "\00a0\00a0";
        }

        &::after {
          content: "\00a0\00a0|";
          color: white;
        }

        &:last-of-type {
          &::after {
            content: "\00a0\00a0|\00a0\00a0";
          }
        }
      }

      &--disclaimer {
        display: block;
        max-width: 600px;
        color: map-get($colors, very-light-pink) !important;
        margin-top: 16px;

        @media (min-width: $fullhd) {
          max-width: 800px;
        }
      }
    }
  }

  .dropdown-toggle {
    &::after {
      color: white;
      vertical-align: middle;
    }
  }
}

@media (max-width: $tablet) {
  footer {
    .footer-section {
      flex-direction: column-reverse;
      align-items: flex-start;

      span {
        font-size: 14px !important;
        line-height: 1.57 !important;
      }

      &__media-section {
        padding: 30px 40px;

        svg {
          height: 31px;
          width: auto;
        }

        &--link {
          margin-right: 20px;
        }

        &--button-with-text {
          flex-direction: column;
          align-items: flex-start;
          margin-bottom: 47px;
        }

        &--text {
          margin-right: 0;
          margin-bottom: 16px;
        }
      }

      &__policies-section {
        padding: 30px 40px;

        &--policies {
          flex-direction: column;
        }

        &--policy-item, &--policy-item:last-of-type {
          &::before, &::after {
            content: "";
          }
        }

        &--language-toggle {
          margin: 17px 0 35px;
        }
      }
    }
  }
}
