

/* メニュー */
.menu {
    position: fixed;
    top: 0;
    left: -100vw;
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    transition: left 0.5s ease-in-out;
    z-index: 1000;
}

.menu ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
}

.menu li {
    width: 100%;
    padding: 20px 30px;
    background-color: transparent;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    transform: translateX(-100%);
    opacity: 0;
    transition: transform 0.5s ease, opacity 0.5s ease;
}

/* メニューリンク */
.menu li a {
    color: #ffffff;
    font-size: 18px;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.menu li a:hover {
    text-decoration: underline;
}

/* メニューが開いた時 */
.menu.open {
    left: 0;
}

.menu.close {
    left: 0; /* 位置はそのままにしておく */
}

/* ハンバーガーメニュー */
.hamburger {
    background: none;
    border: none;
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    z-index: 11;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px; /* 線の間隔 */
}

.hamburger .line {
    width: 35px;
    height: 3px;
    background-color: #ffffff;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}


/* ハンバーガーメニューが開いた時のアニメーション */
.hamburger.open .line:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.hamburger.open .line:nth-child(2) {
    opacity: 0;
}

.hamburger.open .line:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* ホバー時の軽いエフェクト */
.hamburger:hover .line {
    background-color: #b2a6a6; /* 少し濃くなる */
}
/* メニューのバックグラウンド背景 */
.menu-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5); /* 半透明の黒背景 */
    z-index: 9;
    display: none; /* 初期状態では非表示 */
}

/* メニューが開いたときに背景を表示 */
.menu.open ~ .menu-background {
    display: block; /* メニューが開いたときに背景を表示 */
}

/* ハンバーガーメニューの z-index を上げる */
.hamburger {
    z-index: 12; /* メニュー背景よりも上にする */
}

.menu li:nth-child(1) {
    background-color: #74575f /* サドルブラウン */
}
.menu li:nth-child(2) {
    background-color: #836970; /* シエナ */
}
.menu li:nth-child(3) {
    background-color: #927b81; /* ペルー */
}
.menu li:nth-child(4) {
    background-color: #a59297; /* チョコレート */
}
.menu li:nth-child(5) {
    background-color: #b4a4a8; /* バーリーウッド */
}
.menu li:nth-child(6) {
    background-color: #c0b3b6; /* ウィート */
}
