:root {
    --main-cl: #15A05C;
    --heightHeader: 64px;
}

header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    margin: 0 auto;
    transition: all 0.3s ease;
    z-index: 99;
}
header li {
     list-style: none;
}
header h1 {
    margin: 0;
}

    .menu__list li > a .fa{
        font-size: 20px;
    }

.hd__frame {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
    border-radius: 0 0 32px 32px;
    padding: 0 24px 0 8px;
}
.hd__menu ul {
    display: flex;
}
.hd__menu ul > li,
.hd__menu ul a {
    color: #fff;
}
.hd__menu ul > li {
    position: relative;
    z-index: 1;
}
.hd__menu ul > li > a {
    display: block;
    font-weight: normal;
    padding: 20px 14px;
}
.hd__menu--sub {
    display: unset;
    position: absolute;
    top: 0;
    left: calc(100% - 24px);
    min-width: 224px;
    background-color: #fff;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -2px rgba(0, 0, 0, 0.1);
    opacity: 0;
    pointer-events: none;
    transition: 0.35s;
}
.hd__call {
    display: flex;
    gap: 10px;
    align-items: center;
}
.hd__call > svg {
    font-size: 32px;
    color: #fff;
}
.hd__call--num > p {
    font-size: 12px;
    line-height: 18px;
    color: #a3a3a3;
    margin-bottom: 0;
}
.hd__call--num > a {
    font-size: 14px;
    line-height: 20px;
    color: #fff;
    font-weight: 600;
}
.menu__list {
    display: flex;
    height: 100%;
    margin-bottom: 0;
}
.menu__list > li > a {
    color: #fff;
}
.menu__list > li > p::before,
.menu__list > li > a::before {
    content: "";
    position: absolute;
    background-color: #007bff;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    right: 0;
    margin: auto;
    z-index: -1;
    transition: width 0.2s linear;
}

.menu__list li > p,.menu__list li > a {
    font-size: 15px;
    font-weight: 500;
    line-height: 1.6em;
    margin-bottom: 0;
    display: flex;
    height: 100%;
    align-items: center;
    padding: 10px 20px;
    letter-spacing: 0.005em;
    position: relative;
    z-index: 1;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.dropdown {
    position: relative;
}

.menu__sub {
    background-color: #fff;
}
.menu__sub a {
    padding: 10px 16px !important;
    display: block;
    font-weight: 500;
    color: #262626;
}
.menu__sub a::before {
    content: "";
    position: absolute;
    width: 2px;
    height: 0;
    top: 0;
    bottom: 0;
    right: 0;
    margin: auto;
    background-color: #007bff;
    z-index: -1;
    transition: height 0.2s linear;
}
.phone-ring {
    animation-name: ring;
    animation-duration: 1.5s;
    animation-iteration-count: infinite;
    animation-timing-function: linear;
}
header .hd__frame * {
    color: #898989;
}
header .menu__list a {
    color: #808081;
}
@keyframes ring {
    0% {
        transform: rotate(0deg);
    }
    20%,
    32%,
    44%,
    56%,
    68% {
        transform: rotate(0deg);
    }
    23%,
    35%,
    47%,
    59%,
    71% {
        transform: rotate(15deg);
    }
    26%,
    38%,
    50%,
    62%,
    74% {
        transform: rotate(0deg);
    }
    29%,
    41%,
    53%,
    65%,
    77% {
        transform: rotate(-15deg);
    }
    80% {
        transform: rotate(0deg);
    }
}

/* Only for hover */
@media screen and (hover: hover) {
    header .menu__list > li:hover::after {
        background-color: #262626;
    }
    .menu__list .menu__tt:hover {
        color: #007bff;
    }
    .dropdown:hover > .menu__sub {
        transform: translateY(0);
        pointer-events: auto;
        opacity: 1;
        visibility: visible;
        z-index: 1;
    }
    .menu__sub a:hover {
        color: #fff;
        background-color: #007bff;
    }
    .menu__sub a:hover {
        color: #007bff;
        background-color: #e5f0ff;
        border-color: #007bff;
    }
    .menu__sub a:hover::before {
        height: 100%;
    }
    .menu__list li > p:hover,
    .menu__list li > a:hover {
        color: #007bff;
        text-decoration: none;
    }
    .menu__list li > p:hover i,
    .menu__list li > a:hover i {
        color: #007bff;
    }
    .menu__list > li:hover::before,
    .menu__list > li:hover::after {
        opacity: 1;
        visibility: visible;
    }
    .menu__list > li:hover::before {
        height: 10px;
    }
    .menu__list > li:hover::after {
        height: 15px;
    }
    .hd__call .num:hover  {
        color: #007bff;
        text-decoration: none;
    }
}


/* Responsive header only PC -> tablet */
@media (width >= 769px) {
    .sp {
        display: none !important;
    }
    header {
        top: 0;
    }
    header .hd__frame {
        background-color: #fff;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
            0 2px 4px -2px rgba(0, 0, 0, 0.1);
    }
    .menu-list .menu-tt:hover {
        color: #007bff;
    }
    .dropdown:hover > .sub-menu {
        transform: translateY(0);
        pointer-events: auto;
        opacity: 1;
        visibility: visible;
        z-index: 1;
    }
    .sub-menu {
        position: absolute;
        top: 100%;
        left: 0;
        min-width: 200px;
        transition: all 0.3s ease;
        transform: translateY(10px);
        pointer-events: none;
        opacity: 0;
        visibility: hidden;
        box-shadow: 10px 10px 30px rgba(0, 0, 0, 0.16);
    }
    .sub-menu a:hover {
        color: #fff;
        background-color: #007bff;
    }
    .menu__sub {
        position: absolute;
        top: 100%;
        left: 0;
        min-width: 224px;
        transition: all 0.3s ease;
        transform: translateY(10px);
        pointer-events: none;
        opacity: 0;
        visibility: hidden;
        box-shadow: 10px 10px 30px rgba(0, 0, 0, 0.16);
    }
    .menu__list > li {
        position: relative;
        z-index: 1;
    }
    .menu__list > li.active a,.menu__list > li.active a i {
        color: #007bff;
        text-decoration: none;
        background: radial-gradient(#eef3ff, transparent);
        border-radius: 10px;
    }
    .menu__list > li.active::before {
        height: 10px;
    }
    .menu__list > li.active::after {
        background-color: #262626;
        height: 15px;
    }
    .menu__list > li.active::before, 
    .menu__list > li.active::after {
        opacity: 1;
        visibility: visible;
    }
    .menu__list > li::before,
    .menu__list > li::after {
        content: "";
        position: absolute;
        bottom: 0;
        left: 50%;
        transform: translateX(-50%);
        opacity: 0;
        visibility: hidden;
        height: 0;
        transition: all 0.5s ease;
    }
    .menu__list > li::before {
        width: 12px;
        border-left: 2px solid #007bff;
        border-right: 2px solid #007bff;
    }
    .menu__list > li:after {
        width: 2px;
        background-color: #fff;
    }
}

@media (769px <= width <= 992px) {
    header .container {
        width: 100% !important;
        max-width: 100%;
    }
    .menu__list li > p, .menu__list li > a {
        font-size: 14px;
    }
    .menu__list li > p, .menu__list li > a {
        padding: 10px;
    }
    .hd__call {
        gap: 5px;
    }
    .hd__call svg {
        font-size: 25px;
    }
}

/* End PC only */

/* Responsive header only Smart Phone */
@media (width <= 768px) {

    .menu__list li > a .fa{
        font-size: 20px;
    }

    .pc {
        display: none !important;
    }
    header {
        padding: 11px 0;
        height: 58px;
        background-color: #fff;
        top: unset !important;
        bottom: 0;
        filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.3));
        border-radius: 16px 16px 0 0;
    }
    header h1 {
        display: none;
    }
    header .container {
        height: 100%;
    }
    .hd__frame {
        padding: 0;
        height: 100%;
    }
    #header .container {
        padding: 0 5px;
        max-width: 100%;
    }
    .menu__list {
        display: grid;
        grid-template-columns: repeat(5, 1fr);
        gap: 6px;
        flex: 1 1;
        align-items: center;
        padding-left: 0;
    }
    .menu__list li > p,.menu__list li > a {
        padding: 0;
        position: relative;
        z-index: 1;
        --max-screen: 768;
        --max-value: 16;
        --min-screen: 320;
        --min-value: 14;
        --value: max(min(calc((var(--max-value) - var(--min-value)) * ((100vw - var(--min-screen) * 1px) / (var(--max-screen) - var(--min-screen))) + calc(var(--min-value) * 1px)), calc(var(--max-value) * 1px)), calc(var(--min-value) * 1px));
        font-size: var(--value);
        justify-content: center;
        letter-spacing: -0.03em;
        height: auto;
        color: #898989;
        text-align: center;
        gap: 5px;
    }
    .menu__list li > p i,
    .menu__list li > a i {
        height: 14px;
    }
    .menu__list li > p::before,
    .menu__list li > a::before {
        content: "";
        position: absolute;
        z-index: -1;
        top: 0;
        bottom: unset;
        left: 0;
        right: 0;
        margin: auto;
    }
    .menu__list li.menu-news > p::before,
    .menu__list li.menu-news > a::before {
        background: url("../../img/ic-news.svg") center no-repeat;
        background-size: cover;
        width: 24px;
        height: 18px;
    }
    .menu__list li.menu-introduce > p::before,
    .menu__list li.menu-introduce > a::before {
        background: url("../../img/ic-introduce.svg") center no-repeat;
        background-size: cover;
        width: 24px;
        height: 24px;
        top: -3px;
    }
    .menu__list li.menu-findroom > p::before,
    .menu__list li.menu-findroom > a::before {
        background: url("../../img/ic-findroom.svg") center no-repeat;
        width: 24px;
        height: 24px;
        top: -3px;
    }
    .menu__list li.menu-recruitment > p::before,
    .menu__list li.menu-recruitment > a::before {
        background: url("../../img/ic-recruitment.svg") center no-repeat;
        background-size: cover;
        width: 20px;
        height: 20px;
        top: -3px;
    }
    .menu__list li.menu-link > p::before,
    .menu__list li.menu-link > a::before {
        background: url("../../img/ic-link.svg") center no-repeat;
        background-size: cover;
        width: 24px;
        height: 22px;
        top: 0;
    }
    .menu__list li.menu-top {
        position: relative;
        z-index: 1;
        white-space: nowrap;
    }
    .menu__list li.menu-top a {
        /* font-size: 14px; */
    }
    /* .menu__list li.menu-top::before {
        content: "";
        position: absolute;
        top: -143%;
        width: 28px;
        height: 28px;
        background-color: rgba(0, 0, 0, 0);
        border-radius: 50%;
        left: calc(50% - 56px);
        box-shadow: 12px 18px #fff;
    }
    .menu__list li.menu-top::after {
        content: "";
        position: absolute;
        top: -140%;
        width: 28px;
        height: 28px;
        background-color: rgba(0, 0, 0, 0);
        border-radius: 50%;
        right: calc(50% - 54px);
        box-shadow: -12px 18px #fff;
    } */
    .menu__list li.menu-top a {
        color: #007bff;
        padding-top: 17px;
    }
    .menu__list li.menu-top > p::before,
    .menu__list li.menu-top > a::before {
        background: url("../../img/logo.png") center no-repeat;
        background-size: cover;
        width: 58px;
        height: 58px;
        top: -43px;
        left: 50%;
        z-index: 2;
        border: 5px solid #fff;
        border-radius: 50%;
        transform: translate(-50%, 0);
    }
    /* .menu__list li.menu-top > p::after,
    .menu__list li.menu-top > a::after {
        content: "";
        position: absolute;
        background-color: #fff;
        width: 62px;
        height: 62px;
        top: -50px;
        left: 50%;
        transform: translate(-50%, 0);
        border-radius: 50%;
        z-index: -1;
    } */
    .menu__sub {
        position: fixed;
        bottom: 0;
        z-index: 200;
        display: flex;
        flex-direction: column;
        max-width: 100%;
        color: #333;
        opacity: 0;
        pointer-events: none;
        background-color: #f5f6f9;
        background-clip: padding-box;
        outline: 0;
        transform: translateY(100%);
        width: 100%;
        left: 0;
        border-radius: 16px 16px 0 0;
        padding: 15px;
        transition: 0.2s linear;
    }
    .menu__sub .close {
        position: absolute;
        top: 20px;
        right: 20px;
        opacity: 0.5;
    }
    .menu__sub .close img {
        width: 18px;
    }
    .menu__sub .menu__tt {
        font-weight: bold;
        font-size: 18px;
    }
    .menu__sub .menu__sub--list {
        border-radius: 14px;
        background-color: #fff;
        padding: 0 12px;
    }
    .menu__sub .menu__sub--list li:not(:last-child) {
        border-bottom: 1px solid #f6f7fa;
    }
    .menu__sub .menu__sub--list a {
        justify-content: flex-start;
        font-size: 16px;
    }
}