body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
  background: #f5f7fa;
  color: #333;
}
a { color: #0b8d5d; text-decoration: none; }
a:hover { text-decoration: underline; }

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #0b8d5d;
  color: #fff;
  padding: 0.6rem 0.9rem;
}
.header-title { font-size: 1rem; font-weight: bold; }
.header-right { font-size: 0.8rem; }

.container {
  max-width: 600px;
  margin: 0 auto;
  padding: 0.8rem;
}
.card {
  background: #fff;
  border-radius: 0.6rem;
  padding: 0.8rem 0.9rem;
  margin-bottom: 0.8rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.04);
}
.card-title { font-weight: bold; margin-bottom: 0.4rem; }

form label {
  display: block;
  font-size: 0.85rem;
  margin-top: 0.5rem;
}
input[type="text"],
input[type="password"],
textarea,
select {
  width: 100%;
  padding: 0.5rem;
  margin-top: 0.2rem;
  border-radius: 0.4rem;
  border: 1px solid #ccc;
  box-sizing: border-box;
  font-size: 0.9rem;
}
button,
input[type="submit"] {
  margin-top: 0.7rem;
  padding: 0.5rem 0.8rem;
  border-radius: 999px;
  border: none;
  background: #0b8d5d;
  color: #fff;
  font-size: 0.9rem;
}

/* chat */
.chat-list {
  max-height: 60vh;
  overflow-y: auto;
  padding: 0.4rem;
}
.chat-msg {
  margin: 0.3rem 0;
  max-width: 80%;
  padding: 0.4rem 0.6rem;
  border-radius: 0.8rem;
  font-size: 0.88rem;
}
.chat-me {
  margin-left: auto;
  background: #c0f0d8; /* 自分：緑 */
}
.chat-other {
  margin-right: auto;
  background: #fff9c4; /* 相手：薄い黄色 */
}

.menu-btn {
  border: none;
  background: transparent;
  color: #fff;
  font-size: 1.4rem;
}
.side-menu {
  position: fixed;
  top: 0;
  left: -260px;
  width: 240px;
  height: 100vh;
  background: #ffffff;
  box-shadow: 2px 0 6px rgba(0,0,0,0.2);
  padding: 1rem 0.9rem;
  box-sizing: border-box;
  transition: left 0.2s ease;
  z-index: 1000;
}
.side-menu.open { left: 0; }
.side-menu-title { font-weight: bold; margin-bottom: 0.5rem; }
.side-menu a {
  display: block;
  padding: 0.35rem 0;
  font-size: 0.9rem;
}

.avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #0b8d5d33;
}
.badges img { height: 24px; margin-right: 0.25rem; }
.point { font-size: 1.4rem; font-weight: bold; }


/* ===== Side Menu Close (overlay + X) ===== */
.menu-overlay{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease;
  z-index: 900;
}

.menu-overlay.show{
  opacity: 1;
  pointer-events: auto;
}

.side-menu{
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: min(84vw, 320px);
  transform: translateX(-105%);
  transition: transform .18s ease;
  z-index: 1000;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.side-menu.open{
  transform: translateX(0);
}

body.menu-open{
  overflow: hidden;
}

/* ヘッダー行（タイトル＋×） */
.side-menu-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  padding: 14px 14px 8px;
}

/* ×ボタン */
.menu-close{
  border: none;
  background: transparent;
  font-size: 28px;
  line-height: 1;
  padding: 6px 10px;
  cursor: pointer;
}
/* menu-close は共通 button スタイルを無効化して「×だけ」にする */
.side-menu .menu-close{
  background: transparent !important;
  color: #333 !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 6px 10px !important;
  margin-top: 0 !important;      /* 共通の margin-top を消す */
  box-shadow: none !important;
  font-size: 28px;
  line-height: 1;
}
