@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700;900&display=swap');

*{
    box-sizing: border-box;
    padding: 0;
    margin: 0;
    font-family: 'Roboto', sans-serif;
}
body{
    line-height: 1.4;
}
.main-wrapper img{
    width: 100%;
    display: block;
}
.main-wrapper a{
    color: #000;
    text-decoration: none;
}
.main-wrapper ul li{
    list-style-type: none;
}
.navbar{
    background: #fafafa;
    padding: 0 1rem;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    max-height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 10;
    align-items: normal;
}
.brand-and-icon{
    display: flex;
    justify-content: space-between;
    padding: 1rem 0;
    border-bottom: 1px solid #ddd;
    align-items: center;
}
.navbar-brand{
    font-size: 1.8rem;
    letter-spacing: 3px;
    font-weight: 700;
}
.navbar-toggler{
    display: block;
    border: none;
    background: transparent;
    font-size: 1.8rem;
    cursor: pointer;
    padding: 0.2rem 0.5rem;
    transition: all 0.4s ease;
    border: 2px solid #000;
    border-radius: 4px;
    padding: 2px solid #DDD;
    max-height: 50px;
    margin-right: 1rem;
}
.navbar-toggler:hover{
    opacity: 0.7;
}
/*  可連到 anchor 版
    .navbar-collapse{
    overflow-y: auto;
    display: none;
} */
.navbar-collapse{
    display: none;
}

.navbar-nav > li > a{
    text-transform: uppercase;
    font-size: 1.1rem;
    font-weight: 700;
    display: block;
    padding: 0.6rem 0;
    margin: 0.2rem 0;
    border-bottom: 1px solid #ddd;
    border-radius: 1px;
    position: relative;
    transition: all 0.4s ease;
}
.drop-icon{
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
}
.navbar-nav > li > a:hover{
    opacity: 0.7;
}
.sub-menu h4{
    text-transform: capitalize;
    font-size: 1rem;
    padding: 0.5rem 0;
}
.sub-menu ul li{
    text-transform: capitalize;
    padding: 0.2rem 0;
    margin: 0.2rem 0;
    font-size: 0.95rem;
}
.sub-menu ul li a{
    opacity: 0.8;
    transition: all 0.5s ease;
}
.sub-menu ul li a:hover{
    padding-left: 14px;
    opacity: 0.9;
}

h4 .sub-menu {
    text-transform: capitalize;
    font-size: 1rem;
    padding: 0.5rem 0;
}

.sub-menu a:hover h4 {
    text-transform: capitalize;
    padding: 0.5rem 0;
    text-shadow: 0 0 0.2em #000, 0 0 0.2em #000, 0 0 0.2em #000;
    color: #DDD;
    transition: all 1s ease;
}
.sub-menu ul a li {
    opacity: 0.8;
    transition: all 0.5s ease;
}
.sub-menu ul a li:hover{
    padding-left: 14px;
    opacity: 0.9;
}

.sub-menu{
    display: none;
}

.sub-menu-item{
    padding-left: 1.2rem;
}
/* dropdown menu 樣式 */
.header-dropdown {
    margin-left: auto;
    margin-right:auto;
    position: relative;
    display: inline-block;
    font-size: 1rem;
    font-weight: 700;
  }
  
  .header-dropdown-button {
    font-size: 1.1rem;
    font-weight: 700;
    background-color: #fafafa;
    padding: 20px;
    border: none;
    cursor: pointer;
  }
  .header-dropdown-button:focus{
    outline: none;
}
  
  /* 隱藏下拉內容 */
  .header-dropdown-content {
    display: none;
    position: absolute;
    background-color: #f9f9f9;
    min-width: 170px;
    /* box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2); */
    border-bottom: 1px solid #ddd;
    z-index: 1;
  }
  
  .header-dropdown-content a {
    color: #6d6d6d;
    padding: 12px 16px 12px 18px;
    text-decoration: none;
    display: block;
  }
  
  .header-dropdown-content a:hover {
    color: #1785C0;
  }
  
  /* 顯示下拉菜單 */
  .header-dropdown:hover .header-dropdown-content {
    display: block;
  }

  /* 手機版手風琴 */
  .header-accordion-item{
    border-bottom: 1px solid #ddd;
  }

  .accordion-item-header {
    font-size: 1.1rem;
    font-weight: 700;
    background-color: #fafafa;
    padding: 15px;
    width: 100%;
    text-align: left;
    border: none;
    cursor: pointer;
    transition: color 0.3s ease;
}
.accordion-item-header:focus{
    outline: none;
}
.accordion-item-header:hover {
   color: #1785C0;
}
.accordion-item-body {
    font-size: 1.1rem;
    font-weight: 700;
    padding: 0 30px;
    background-color: #fafafa;
    display: none;
}

.accordion-item-body a{
    color: #6d6d6d;
    display: block;
    width: 100%;
}

.accordion-item-body li:hover a{
    color: #1785C0;
}

.header-accordion-item.open .accordion-item-body {
    display: block;
}

/*
.sub-menu-item:nth-child(3){
    background: #ddd;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding-top: 2rem;
    padding-bottom: 2rem;
}
.sub-menu-item:nth-child(3) h2{
    text-transform: capitalize;
    margin: 1.5rem 0;
}
.sub-menu-item:nth-child(3) .btn{
    border: 1px solid #000;
    text-transform: uppercase;
    font-size: 0.9rem;
    padding: 0.6rem 1rem;
    cursor: pointer;
    background: #000;
    color: #fff;
    transition: all 0.5s ease;
}
.sub-menu-item:nth-child(3) .btn:hover{
    background: transparent;
    color: #000;
}
.sub-menu-item:nth-child(4){
    width: 50%;
    margin: 0 auto;
    padding: 2rem 0;
}
*/

/* header */
.header{
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)), url(https://source.unsplash.com/g-kNBpqMIs4/1920x1400) center/cover no-repeat;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.header h2{
    margin: 1rem;
    font-size: 3rem;
    font-weight: 900;
    color: #fff;
    letter-spacing: 2px;
}
.header p{
    margin: 1rem auto;
    color: #fff;
    width: 60%;
    opacity: 0.8;
    font-weight: 300;
    font-size: 1.2rem;
    text-align: center;
}
.header button{
    margin: 1rem;
    font-size: 1rem;
    text-transform: uppercase;
    background: #000;
    color: #fff;
    border: none;
    padding: 0.8rem 1.5rem;
    transition: all 0.5s ease;
    cursor: pointer;
}
.header button:hover{
    background: #fff;
    color: #000;
}
@media screen and (max-width: 1199px){
    .header-dropdown{
        font-size: 0.73rem;
    }
    .header-dropdown-button{
        font-size: 0.7rem;
    }
}

/* Media Queries */
@media screen and (min-width: 992px){
    .navbar{
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        border-bottom: 1px solid #ddd;
        padding: 0 5rem;
        position: fixed;
    }
    .navbar-toggler{
        display: none;
    }
    .brand-and-icon{
        flex: 0 0 200px;
        border-bottom: none;
        padding: 0;
    }
    /*  可連到 anchor 版 
        .navbar-collapse{
        display: block!important;
        overflow-y: hidden;
        flex: 1 0 auto;
        } */

    .navbar-nav{
        flex-direction: row;
        display: flex;
        align-items: center;
        justify-content: space-evenly;
    }
    .navbar-nav > li > a{
        border-bottom: none;
        margin: 0 0.4rem;
        padding: 1.7rem 1.8rem 1.7rem 0.8rem;
        font-size: 0.8rem;
    }
    .sub-menu{
        position: absolute;
        left: 0;
        width: 100%;
        top: 100%;
        background: #f8f8f8;
        min-height: 100px;
    }
    .navbar-nav > li:hover .sub-menu{
        display: grid!important;
        grid-template-columns: repeat(4, 1fr);
        padding: 0 5rem;
        transition-delay: 250ms;
    }
    .navbar-nav > li{
        border-bottom: 2px solid transparent;
        transition: border-bottom 0.4s ease;
    }
    .navbar-nav > li:hover{
        border-bottom-color: #000;
    }
    .sub-menu-item{
        padding: 5px auto 5px 0;
    }
    /*
    .sub-menu-item:nth-child(3){
        padding-left: 2rem;
        padding-right: 2rem;
    }*/
    .sub-menu-item:first-child {
        border-left: none;
    }

    /* header */
    .header{
        height: calc(100vh - 75px);
    }
    .header h2{
        font-size: 6rem;
    }
    .header p{
        width: 40%;
    }
}

