/* ===============================
   ハンバーガーメニュー 共通設定
   =============================== */

/* チェックボックスを非表示にする */
.drawer_hidden {
    display: none;
}

/* ハンバーガーアイコン */
.drawer_open {
    position: fixed;
    display: flex;
    justify-content: center;
    align-items: center;
    left: 0;
    top: 0;
    z-index: 9999;
    background-color: #dc000c;
    width: 50px;
    height: 80px;
    cursor: pointer;
}

/* アイコンの線3本 */
.drawer_open span {
    display: inline-block;
    position: absolute;
    left: 14px;
    height: 2px;
    border-radius: 5px;
    background: #fff;
    width: 45%;
    transition: all 0.4s;
}

.drawer_open span:nth-of-type(1) {
    top: 30px;
}
.drawer_open span:nth-of-type(2) {
    top: 40px;
}
.drawer_open span:nth-of-type(3) {
    top: 50px;
}

.drawer_open span:nth-of-type(3)::after {
    position: absolute;
    top: 5px;
    left: -8px;
    color: #fff;
    font-size: 0.1rem;
    text-transform: uppercase;
    white-space: nowrap;
}

/* ハンバーガー × 変化 */
#drawer_input:checked ~ .drawer_open span:nth-of-type(1) {
    top: 40px;
    transform: rotate(45deg);
}
#drawer_input:checked ~ .drawer_open span:nth-of-type(2) {
    opacity: 0;
}
#drawer_input:checked ~ .drawer_open span:nth-of-type(3) {
    top: 40px;
    transform: rotate(-45deg);
}
#drawer_input:checked ~ .drawer_open span:nth-of-type(3)::after {
    content: "";
}

/* サイドバー表示切替 */
#drawer_input:checked ~ .sidebar {
    left: 0;
}

/* ===============================
   PCサイズ（960px以上）
   =============================== */
@media screen and (min-width: 960px) {
    .drawer_open {
        display: none;
    }
    .sidebar {
        left: 0;
    }
    #drawer_input {
        display: none;
    }
}

/* ===============================
   タブレット（520px〜959px）
   =============================== */
@media screen and (min-width: 520px) and (max-width: 959px) {
    .sidebar-logo {
        margin-top: 70px;
    }
    .content {
        margin-left: 0;
    }
    .pc-only {
        display: none;
    }

    /* ナビメニュー */
    .nav_content {
        width: 50%;
        height: 660px;
        position: fixed;
        top: 5.5%;
        left: 100%;
        z-index: 80;
        background-color: #fff;
        transition: all 0.5s;
        font-weight: 500;
        padding: 28px 25.5px 42px 25.5px;
    }

    .nav_content li {
        padding: 14px 0;
        border-bottom: 2px solid #c0c0c0;
    }

    .information {
        margin-top: 40px;
        display: flex;
    }

    .information a img {
        width: 100%;
        object-fit: cover;
        padding: 0 15px;
    }

    /* メニュー表示 */
    #drawer_input:checked ~ .nav_content {
        left: 50%;
    }
}

/* ===============================
   スマホサイズ（〜519px）
   =============================== */
@media screen and (max-width: 519px) {
    .drawer_open {
        display: flex;
    }

    .sidebar {
        left: -190px;
        transition: left 0.3s;
    }

    #drawer_input:checked ~ .sidebar {
        left: 0;
    }

    .sidebar-logo {
        margin-top: 70px;
    }

    .hamburger p {
        transform: scale(0.6);
        line-height: 9px;
        margin-top: 10px;
    }

    .content {
        margin-left: 0;
    }

    .pc-only {
        display: none;
    }

    .information {
        margin-top: 40px;
        display: flex;
    }

    .information a img {
        width: 100%;
        object-fit: cover;
        padding: 0 15px;
    }

    /* メニュー表示 */
    #drawer_input:checked ~ .nav_content {
        left: 20%;
    }
}
