:root {
  /*モーダルの間隔*/  
  --modalMarginTop:15px;
}

body.no-scroll{
  overflow: hidden;
}

.body-wrapper.no-scroll{
  overflow: auto;
  scrollbar-gutter: stable;
}

/*モーダルのリセットCSS*/
:where(dialog) {
  width: unset;
  max-width: unset;
  height: unset;
  max-height: unset;
  padding: unset;
  color: unset;
  background-color: unset;
  border: unset;
  overflow: unset;
}
dialog[open]{
  display: block;
}

/*イベント欄削除によるスタイル修正*/
#sidenavi_index .sidenaviService .boxBanner{
  &:first-of-type{
    margin-top: 0;
  }
}

/*お知らせ部*/

/*スタイル修正に伴う既存スタイルのリセットここから*/
#leftBox_index .newsBox h2{
  margin: 0;
}

#leftBox_index .newsBox .newsBox_txt dl{
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 28px;
  margin: 0;
  padding-block: 10px;
}

#leftBox_index .newsBox .newsBox_txt .newsBox_modal-button{
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 5px;
}

#leftBox_index .newsBox .newsBox_txt .newsBox_modal-button .news-title{
  padding-inline-start: 5px;
  text-align: left;
  text-decoration: underline;
}

#leftBox_index .newsBox .newsBox_txt dt{
  width: 70px;
  position: static;
}

#leftBox_index .newsBox .newsBox_txt dd{
  padding-inline: 0;
}
/*スタイル修正に伴う既存スタイルのリセットここまで*/


.newsBox_modal-button{
    /*ボタンのリセットCSS*/
    background-color: transparent;
    border: none;
    cursor: pointer;
    outline: none;
    padding: 0;
    color: inherit;
    font-style: inherit;
    font-family: inherit;
    font-size: inherit;
    font-weight: inherit;
    appearance: none;
    /*ここまで*/

    /*フォーカス*/
    &:has(.new-information):focus{
      .new-information{
        border: 1px solid #333;
      }
    }

    &:focus{
      .news-title{
        filter: opacity(.7);
      }
    }

    /*ホバー*/
    &:hover{
      filter: opacity(.7);
      .news-title{
        text-decoration: none !important;
      }
    }
}

.modal-button--green{
  padding: 5px 10px;
  color: #fff;
  background-color: #5BAC2C;
  border-radius: 50px;
  line-height: 1lh;
  font-weight: bold;
  text-decoration: none;
  word-break: keep-all;
}

#header,.container,#footer{
  &:where(.news-modal[open]){
    padding: 0 var(--scrollbar-width) 0 0;
  }
}

/*モーダルのスタイルここから*/
.news-modal{
  width: 100%;
}

.modal-wrapper{
  position: fixed;      
  top: 50%;
  left: 50%;
  width: fit-content;
  max-height: 500px;
  max-width: calc(250px * 3 + 20px * 2);
  margin-inline: 20px;
  padding: 30px 20px;
  background-color: #fff;
  border:2px solid #75B92C;
  border-radius: 5px;
  transform: translate(-50%,-50%);
  overflow-x: scroll;
}

.news-modal-title{
  position: relative;
  padding-inline-start: 15px;
  --defaultFontSize:26px;
  font-size: var(--defaultFontSize);
  outline: none;
}

.news-modal-title:before{
    position: absolute;
    content: "";
    top: 0;
    left: 0;
    display: block;
    width: 5px;
    height: 100%;
    background-color: #5BAC2C;
  }

  .news-modal-date{
    margin-block-start: 10px;
    font-weight: bold;
  }

.news-modal-description{
  margin-block-start: var(--modalMarginTop);

  .paragraph{
    &:not(:first-of-type){
      margin-block-start: 10px;
    }
    &:is(.heading){
      margin-block-start: 20px;
      font-weight: bold;
    }
    /*見出し風*/
    .row-head{
      display: inline-block;
      min-width: 50px;
      width: 50px;
      vertical-align: top;
    }

    /*内容*/
    .content{
      display: inline-block;
    }
  }
}

.news-modal-image-wrap{
  display: grid;
  grid-template-columns: repeat(auto-fit,250px);
  justify-content: start;
  align-items: center;
  gap: 10px;
  width: 100%;
  max-width: calc(250px * 3 + 10px * 2);
  margin-block-start: var(--modalMarginTop);

  img{
    display: inline-block;
    width: 100%;
    height: auto;
    max-width: 300px;
    object-fit: cover;
  }
}

.news-modal-button-close{
    /*リセットCSS*/
  background-color: transparent;
  border: none;
  cursor: pointer;
  outline: none;
  padding: 0;
  appearance: none;
    /*リセットCSSここまで*/

  display: block;
  margin-block-start: var(--modalMarginTop);
  margin-inline: auto;
  padding: 5px 10px;
  color: #fff;
  background-color: #5BAC2C;
  font-size: 1rem;
  font-weight: bold;
  border-radius: 50px;

  /*フォーカス*/
  &:focus{
    border:1px solid #333;
  }

  /*ホバー*/
  &:hover{
    filter: opacity(.7);
  }
}
/*モーダルのスタイルここまで*/