@charset "UTF-8";

@import "vars";
@import "colors";

.breadcrumbs-container {
  
  margin-top: 20px;
  margin-bottom: 75px;
  font-size: 14px;
  
  @media (max-width: $break-medium) {
    margin-bottom: 15px;
  }
  
  .breadcrumb-item {
    text-transform: uppercase;    
    color: #464646;
    
    &:last-child {
      text-transform: none;
    }
   
    &:before {
      content: '››';
    }
   
    &:first-child {
      color: $musta;
    }
  
    &:first-child::before {
      content: '';
    }
  }
 
}

.page-container {
  
  @media (min-width: $break-large) { 
    max-width: 1200px;
  }
  
  .btn-menu {
    background-color: $musta;
    border-color: $musta;
    position: absolute;
    top: -2px;
    right: 15px;
    z-index: 9999;
    
    &:active:focus {
      background-color: $orvokki;
      border-color: $orvokki;
    }
  }
  
}

.banner-container {
  position: relative;
 
  .banner {
    height: 250px;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
  }
 
  .banner-border-top,
  .banner-border-bottom {
    height: 8px;
    background-repeat: no-repeat;
    background-image: url("/gfx/layout/mikkeli-banner-border.png");
  }

}

.page-content {
  font-size: 95%;
  margin-bottom: 45px;

  
  &:focus {
    outline: thin dotted #808080;
  }

  .phone-contact {
    @include font-y13();
    color: $meri;
  }

  label {
    font-weight: bold;
    margin-bottom: 0;
  }

  h1 {
    color: $kallio;
    @include font-ultra(40px);
    
    @media (max-width: $break-small) {
      font-size: 26px;
      margin-right: 50px;
      word-wrap: break-word;
    }
    
  }
 
  h2,
  h3 {
    @include font-h13();
    padding-bottom: 10px;
  }
  
  h4 {
    @include font-h8();
  }
  
  h5 {
    @include font-y13();
  }
 
  p {
    @include font-h11();
  }
  
  a {
    @include font-h9();
    color: $mustikka;
  }
  
  ul {
    padding-left: 25px;

    li {
      @include font-h11();
      margin-top: 8px;
      margin-bottom: 8px;
      list-style-type: none;
      position: relative;
      margin-left: 10px;
      
      &::before {
        content: "\2022";
        display: block;
        position: absolute;
        left: -15px;

        //margin-right: 5px;
      }
      
    }
  }

  .electronic-service-channel-link {
    margin-bottom: 0.5em;
  }

  .featured-image {
    margin-top: 25px;
    margin-bottom: 30px;
    height: 285px;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
  }
  
  .accessibility-sentences {

    .p-info {
      border-bottom: 0.5px solid #d3d3d3;
      padding-bottom: 15px;
      padding-top: 5px;
    }

    .accessibility-sentence {
      border-bottom: 0.5px solid #d3d3d3;
      margin-bottom: 10px;
    
      button {
        display: flex;
        flex: 1;
        flex-direction: row;
        background-color: transparent;
        border: 0;
        text-align: left;
        margin-bottom: 10px;
      }

      .button-text {
        color: $tummakallio;
        font-weight: 700;
      }
      
      .open {
        &::before {
          content: "";
          width: 34px;
          height: 24px;
          background-image: url("/gfx/layout/mikkeli-menu-open.png");
          background-position: center;
          background-repeat: no-repeat;
        }
      }
      
      .closed {
        &::before {
          content: "";
          width: 34px;
          height: 24px;
          background-image: url("/gfx/layout/mikkeli-menu-closed.png");
          background-position: center;
          background-repeat: no-repeat;
        }
      }

    }

    .hidden {
      display: none;
    }

  }
 
}

.open-folder,
.leaf-page {
  padding-right: 10px;
  position: absolute;
  margin-left: -15px;
  
  &:hover, 
  &:focus {
    text-decoration: none;
  }
}

.open > .child-pages > li {
  display: block;
}

.page-nav {
  margin-bottom: 15px;

  .nav-folder-title {
    @include font-ultra(14px);    
    text-transform: uppercase;
    margin-bottom: 8px;
  }
  
  h3 {
    @include font-ultra(14px);    
    text-transform: uppercase;
  }
  
  ul {
    margin-bottom: 0;
  }
  
  .open-folder {
    position: absolute;
    right: 0;
    width: 34px;
    height: 24px;
    background-image: url("/gfx/layout/mikkeli-menu-closed.png");
    background-position: center;
    background-repeat: no-repeat;
    background-color: transparent;
    border: 0;
  }
  
  .open {
      
    > .open-folder {
      background-image: url("/gfx/layout/mikkeli-menu-open.png");
    }
    
    > .child-pages {
      padding-top: 5px; 
    }
    
  }
  
  .active {
    > .open-folder {
      background-image: url("/gfx/layout/mikkeli-menu-closed-active.png");
      height: 32px;
    }
    
    &.open > .open-folder {
      background-image: url("/gfx/layout/mikkeli-menu-open-active.png");
    }
    
    > .child-pages {
      padding-top: 0; 
    }
  }
  
  .loading > .open-folder {
    background-image: url("/gfx/load-2.svg");
    background-size: 21px 21px;
  }
  
  .page-nav-item {
    display: block;
    padding-top: 5px;
    padding-bottom: 5px;
    color: #363636;
    position: relative;
    border-top: 1px solid $menu-border-color;
    
    @media (max-width: $break-medium) {
      margin-right: 50px;
    }
    
    a {
      color: $kallio;
    }
    
    &.active {
      padding-top: 0;
      padding-bottom: 0;
      
      > a {        
        color: $valkoinen;
        background-color: $marjapuuro;
        display: block;
        padding: 5px 10px;
        margin-left: -10px;
      }

    }
    
    &.has-children {
      > a.page-nav-link {        
        padding-right: 28px;
      }
    }
    
    &.open {
      padding-bottom: 0;
    }
  }
  
  > .page-nav-item:first-of-type {
    border-top: 0;
  }
   
}
    
.hidden-lg-up {
  
  .page-nav {
    margin-top: 50px;
  }
  
  .page-nav-item {
    width: 100%;
  }
  
}

.child-pages {
  padding-left: 10px;
  
  > li {
    display: none;
  }
}

.sidebar {
  background: #edeef2;
  margin-bottom: 45px;
  padding-top: 15px;
  padding-bottom: 15px;
  word-wrap: break-word;

  @media (max-width: $break-medium) {
    padding-top: 45px;
    padding-bottom: 35px;
  }

  img {
    max-width: 100%;
  }

  .sidebar-block {
    font-family: "Titillium Web", sans-serif;
  
    a {
      @include font-h9();
      color: $mustikka;
    }
    
    h2,
    h3 {
      @include font-h9();
      text-transform: uppercase;
      padding-top: 5px;
      padding-bottom: 0;
      margin-top: 15px;
      margin-bottom: 0;
    }
    
    h4 {
      @include font-h9();
      color: $musta;
      padding-top: 5px;
      padding-bottom: 0;
      margin-top: 15px;
      margin-bottom: 0;
    }

    .service-location-channel-link {
      padding-top: 5px;
      padding-bottom: 0;
      margin-top: 15px;
      margin-bottom: 0;
    }
    
    p, 
    small {
      @include font-h9n();
    }
  }
}

.kunta-api-news-list {
  width: 100%;
  padding-right: 15px;
  
  .row {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-between;
  }

  .news-article.text-article {

    width: 100%;
    border-bottom: 1px solid #aaa;
    padding-top: 7px;
    padding-bottom: 7px;

    .date {
      @include font-h9();
      float: left;
      width: 15%;
      background: $musta;
      color: $valkoinen;
      padding-top: 8px;
      padding-bottom: 8px;
      text-align: center;
    }

    .title {
      float: left;
      width: 83%;
      padding-left: 12px;
      
      a {
        color: #373a3c;
        text-decoration: none;
        font-family: "Cairo", sans-serif;
        font-weight: 600;
        font-size: 20px;
        line-height: 21px;
        letter-spacing: 0;
          
        &:hover {
          text-decoration: underline;
        }
      }
    }

    @media (max-width: $break-medium) {
      .date {
        width: 20%;
      }

      .title {
        width: 78%;
      }
    }

    @media (max-width: $break-small) {
      .date {
        width: 25%;
      }
      
      .title {
        width: 73%;
      }
    }

  }
    
  .news-article.thumb-article {
    overflow: hidden;
    box-sizing: border-box;
    margin: 10px 0;
    width: 30%;
    
    .details {
      width: 100%;
      background: $news-details-background-color;
      padding-top: 20px;
      padding-right: 20px;
      padding-bottom: 10px;
      padding-left: 20px;
    }

    .date {
      @include font-h9();
      background: $musta;
      color: $valkoinen;
      padding-top: 8px;
      padding-bottom: 8px;
      width: 100%;
      text-align: center;
    }

    .title {
      a {
        @include font-h6();
        color: $musta;
        text-decoration: none;

        &:hover {
          text-decoration: underline;
        }
      }
    }

    .news-article-image {
      min-height: 160px;
      background-size: cover;
    }

    &.thumb-article {
      margin-bottom: 15px;
      position: relative;

      .details {
        min-height: 80px;
        padding-top: 6px;
      }
      
      .date {
        margin-top: -43px;
        position: absolute;
        left: 0;
      }

      .title {
        padding: 20px 5px;
      }
    }

  }
}

@media screen and (max-width: $break-x-small) {
  .kunta-api-news-list {
    
    .news-article {
      width: 46%;
    }
  }
}