/**
 ******************************************************
 ******************************************************
 * {LESS} :: SANTANDER TOTTA :: (upplication, 2018)
 ******************************************************
  *****************************************************
 */

// (common) VARS in "Santander Totta"
// -----------------------------------------------
/* (common) "Upplication" color vars goes to "Santander" corporative ones! */
@main-green: @santander;
@accept-btn: @santander;
@accept-btn-hover: lighten(@santander, 5%);
@santander-main-text: #303030;
@santander-light-text: lighten(@santander-main-text, 30%);
@dark-lilac: @santander-main-text;
@santander-bg: #f5f5f5;
@santander-grey: #eee;

// (common) MIXINS in "Santander Totta"
// ------------------------------------
// main Text mixin with default values (overwrite default ones!)
.main-text(@size: 15px, @weight: 300) {
  font-family: "Roboto", sans-serif;
  font-size: @size;
  letter-spacing: .02em;
  font-weight: @weight;
}

// (common) CUSTOM SCROLL BAR in "Santander Totta"
// -----------------------------------------------
::-webkit-scrollbar {
  background: @santander-grey;
}
::-webkit-scrollbar-thumb {
  background: @santander;
  height: 3.45em;
}

// (common) COOKIES advise in "Santander Totta"
// --------------------------------------------
#cookies {
  background-color: rgba(0, 0, 0, 0.5);
  border-top: 1px solid @santander-main-text;

  p a:hover {
    color: @santander;
  }
}

// main HEADER in "Santander Totta"
// --------------------------------
.top-header {
  height: 135px;
  background-color: transparent;
  border: none;

  // 0. Overwrite default values:
  .container {
    position: relative;
    @media (min-width: 769px) {
      padding-left: 15px;
      padding-right: 15px;
    }

    // common ones for both!
    .logo,
    .top-nav {
      display: inline-block;
      a {
        display: inline-block;
        text-decoration: none;
      }
    }

    .logo {
      width: ~"calc(100% - 340px)";
      @media only screen and (max-width: 768px) {
        width: ~"calc(100% - 75px)";
        position: absolute;
        z-index: 1;
      }
    }

    .top-nav {
      width: 340px;
      z-index: 2;
      /*
      @media only screen and (max-width: 768px) {
        width: 80px;
      }
      */

      .top-nav-list {
        width: 100%;
        // responsive behaviour
        // (carefully cause erase this code will affect to mobile dorpdown top menu)
        @media (min-width: 769px) {
          display: flex;
          justify-content: flex-end;
        }

        // each top main navbar items!!
        li {
          &.contact-info {
            .contact-info-grids {
              min-width: inherit;
              .contact-info-left {
                width: 100%;
                .chat {
                  @media (max-width: 768px) {
                    margin-bottom: 10px;
                  }
                }
                // (Responsive) "Contact-info"
                @media only screen and (max-width: 980px) {
                  .chat {
                    display: inherit;
                  }
                }
              }
            }
            // (Responsive) "Contact-info"
            @media only screen and (max-width: 875px) {
              display: inherit;
            }
          }

          &.phone-support-pt {
            font-family: "Lato", sans-serif;
          }

          a {
            max-width: inherit;
          }

          // (Responsive) in hamburguer top main menu
          @media only screen and (max-width: 768px) {
            &.enter-btn,
            &.contact-info,
            &.phone-support-pt {
              width: 90%;
              margin: 1% 5%;
            }
            &.phone-support-pt {
              text-align: center;
              background-color: @santander-grey;
              margin-bottom: 0.5%;
            }
            &.enter-btn a {
              margin: 0;
            }
          }
          @media only screen and (max-width: 320px) {
            padding: 0;
          }
        }
      }
    }

  }

  // 1. "Santander" premain navbar Top Header
  .santander-totta {
    width: 100%;
    height: 20px;
    background-color: @santander;
    .anim(height, 0.3s, ease);
  }

  // 2. "Upplication" main navbar Top Header
  .upplication {
    width: 100%;
    height: 80px;
    background-color: @header-bg;
    border-bottom: 1px solid @header-border;
    .anim(height, 0.3s, ease);

    .container .logo a {
      &.bst:last-child {
        position: relative;
        bottom: 6px;
      }
      // each corp. logo
      img {
        position: relative;
        .anim(all, 0.3s, ease);

        &.bst-upplication {
          width: 143px;
          height: 54px;
          margin-right: 20px;
        }
        &.bst-advance-empresas {
          width: 216px;
          height: 41px;
        }
      }
    }
  }

  /* ... Main Header shrink when you scrolls down ... */
  &.thiny-top-header {
    height: 90px;

    // 1. "Upplication" main navbar Top Header
    .santander-totta {
      height: 10px;
    }

    // 2. "Upplication" main navbar Top Header
    .upplication {
      height: 60px;

      .container .logo a img {
        top: 8px;

        &.bst-upplication {
          width: 127px;
          height: 40px;
        }
        &.bst-advance-empresas {
          width: 134px;
          height: 25px;
        }
      }
    }
  }
}

/* -- Responsive behaviour HEADER -- */
// to overwrite (common) styles by default
@media only screen and (max-width: 1030px) {
  .top-header .container .logo a img {
    width: 240px;
    height: 45px;
    padding-top: 0;
  }
}

@media (max-width: 768px) {
  .top-header {
    .upplication {
      height: 65px;
    }
    //
    .santander-totta .container .logo a img {
      top: 5px;
    }
  }
}

@media (max-width: 480px) {
  .top-header,
  .top-header.thiny-top-header {
    .upplication,
    .santander-totta {
      .container .logo a img {
        &.bst-upplication {
          width: 86px;
          height: 32px;
        }
        &.bst-advance-empresas {
          width: 132px;
          height: 24px;
        }
      }
    }
  }
  .top-header {
    .upplication,
    .santander-totta {
      .container .logo {
        top: 16px;
      }
    }
    &.thiny-top-header {
      .upplication,
      .santander-totta {
        .container .logo {
          top: 8px;
        }
      }
    }
  }
}


// (common) FOOTER in "Santander Totta"
// ------------------------------------
footer.page-footer {
  background-color: transparent; /* overwrite color by default */
  @media (max-width: 768px) {
    padding-top: 0;
  }

  .footer-copyright {

    a {
      &.by {
        pointer-events: none;
        cursor: default;
        // current year
        #js-current-year {
          color: @white;
          &::before {
            content: ",";
            padding-right: 5px;
            display: inline-block;
          }
        }
      }
      &.legal {
        padding-left: 0;
        text-decoration: underline;
        &:hover {
          color: @accept-btn-hover;
        }
      }
    }
    /* responsive behaviour (overwrite color by default) */
    @media only screen and (max-width: 810px) {
      .container span {
        padding-left: 0;
        margin-top: 0;
      }
    }
    @media only screen and (max-width: 420px) {
      span {
        display: inline-block;
      }
      a.legal {
        display: block;
        padding: 10px 0;
      }
    }
  }
}

// RESPONSIVE BEHAVIOUR (media queries)
// overwrite Common Values "Santander Totta"
// --------------------------------------------
.container {
  @media only screen and (min-width: 1451px) {
    width: 70%; // 92% in "Upplication"
  }
  @media (min-width: 1271px) and (max-width: 1450px) {
    width: 80%; // 92% in "Upplication"
  }
  @media (min-width: 1121px) and (max-width: 1270px) {
    width: 90%; // 92% in "Upplication"
  }
  @media (min-width: 1081px) and (max-width: 1120px) {
    width: 95%; // 92% in "Upplication"
  }
  @media (min-width: 769px) and (max-width: 1080px) {
    width: 100%; // 92% in "Upplication"
  }
}

// TODO: to hide "Marketing App" course Modal (dialog)
/* -- MARKETING APP eBook -- */
html div#om-gylasdx7iwcdo5a40ykm,
html div#om-gylasdx7iwcdo5a40ykm-holder,
#om-gylasdx7iwcdo5a40ykm,
#om-gylasdx7iwcdo5a40ykm-holder,
  // (custom) Class to hide DOM elements
.hidden-modal {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
}
