@charset "UTF-8";

/*リセットCSS----------------------------*/
* {
    margin: 0;
    padding: 0;
    list-style: none;
}

body {
    background-color: #fff;
    background-size: cover;
    font-family: "Huninn", sans-serif;
    font-weight: 400;
    font-style: normal;
}

a {
    color: black;
    text-decoration: none;
}

p {
    font-size: 25px;
}

img {
    width: 100%;
}

header {
    color: #000000;
    padding: 20px;
    position: sticky;
    top: 0;
    z-index: 100;
}

/* ハンバーガーメニューのスタイル */
.hamburger {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 30px;
    cursor: pointer;
    z-index: 10;
    /* メニューより前に表示 */
}

.hamburger span {
    display: block;
    height: 3px;
    width: 100%;
    background-color: #333;
    /* ボタンの色 */
    margin: 5px 0;
    transition: 0.4s;
}

/* メニューのスタイル */
.menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 250px;
    height: 100%;
    background-color: #c0c0c0;
    opacity: 0;
    /* 初期状態は透明 */
    pointer-events: none;
    /* クリック不可 */
    transition: opacity 0.5s ease;
    /* フェードインのアニメーション */
    padding: 80px 20px 0;
    box-sizing: border-box;
    z-index: 5;
}

/* メニューが開いたとき */
.menu.open {
    opacity: 1;
    /* 不透明にする */
    pointer-events: auto;
    /* クリック可能にする */
}

/* バツ印に変わるハンバーガーボタン */
.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
    /* 真ん中の線を透明にする */
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

footer {
    background-color: #111;
    color: #FFF;
    text-align: center;
}

/*============
nav
=============*/
nav {
    display: block;
    position: fixed;
    top: 0;
    left: -300px;
    bottom: 0;
    width: 300px;
    background: #ffffff;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    transition: all .5s;
    z-index: 3;
    opacity: 0;
}

.open nav {
    left: 0;
    opacity: 1;
}

nav .inner {
    padding: 25px;
}

nav .inner ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

nav .inner ul li {
    position: relative;
    margin: 0;
    border-bottom: 1px solid #333;
}

nav .inner ul li a {
    display: block;
    color: #333;
    font-size: 35px;
    padding: 1em;
    text-decoration: none;
    transition-duration: 0.2s;
}

nav .inner ul li a:hover {
    background: #e4e4e4;
}

@media screen and (max-width: 767px) {
    nav {
        left: -220px;
        width: 220px;
    }
}

a.pagetop {
    display: block;
    width: 50px;
    height: 50px;
    text-align: center;
    box-sizing: border-box;
    padding-top: 12px;
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    background-color: #333;
    color: #FFF;
    position: fixed;
    bottom: 0;
    right: 20px;
}

.toggle_btn {
    display: block;
    position: fixed;
    top: 30px;
    right: 30px;
    width: 30px;
    height: 30px;
    transition: all .5s;
    cursor: pointer;
    z-index: 3;
}

.toggle_btn span {
    display: block;
    position: absolute;
    left: 0;
    width: 30px;
    height: 2px;
    background-color: #333;
    border-radius: 4px;
    transition: all .5s;
}

.toggle_btn span:nth-child(1) {
    top: 4px;
}

.toggle_btn span:nth-child(2) {
    top: 14px;
}

.toggle_btn span:nth-child(3) {
    bottom: 4px;
}

.open .toggle_btn span {
    background-color: #fff;
}

.open .toggle_btn span:nth-child(1) {
    -webkit-transform: translateY(10px) rotate(-315deg);
    transform: translateY(10px) rotate(-315deg);
}

.open .toggle_btn span:nth-child(2) {
    opacity: 0;
}

.open .toggle_btn span:nth-child(3) {
    -webkit-transform: translateY(-10px) rotate(315deg);
    transform: translateY(-10px) rotate(315deg);
}

#mask {
    display: none;
    transition: all .5s;
}

.open #mask {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    opacity: .8;
    z-index: 2;
    cursor: pointer;
}

h2 {
    font-size: 50px;
    text-align: center;
    padding: 2% 0;
}

ul {
    text-align: center;
    padding: 0 150px;
}

#Words ul {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
}

#Words li {
    font-size: 50px;
    margin: 10% 15% 5%;
    border-radius: 50px;
    padding: 15px 30px;
    text-align: center;
}

.chat-container {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding: 100px 0;
}


.message {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    max-width: 75%;
}


.message.them {
    flex-direction: row;
    align-self: flex-start;
}


.message.me {
    flex-direction: row-reverse;
    align-self: flex-end;
}


.avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}


.bubble {
    background: #8bc34a;
    color: #000;
    padding: 14px 18px;
    border-radius: 30px;
    font-size: 15px;
    line-height: 1.6;
    position: relative;
    word-break: break-word;
}


.message.them .bubble {
    border-bottom-left-radius: 6px;
}


.message.me .bubble {
    border-bottom-right-radius: 6px;
}


@media(max-width:600px) {
    .chat-container {
        padding: 10px
    }

    .avatar {
        width: 44px;
        height: 44px
    }

    .bubble {
        font-size: 14px;
        padding: 12px 14px
    }
}