/* calendarevent.css (page-specific) */

/* 入力エリア幅制御（イベント作成フォーム） */
.main input,
.main textarea {
  max-width: 480px;
  width: 100%;
}

/* フォーム全体の横幅上限 */
.form-group {
  max-width: 420px;
  margin-bottom: 20px;
}

/* 画面全体レイアウト：サイドバー + メイン */
.container {
  display: flex;
  min-height: 100vh;
}

/* サイドバー */
.sidebar {
  width: 200px;
  background: #1e88e5;
  color: white;
  padding: 20px;
}

.sidebar a {
  color: white;
  text-decoration: none;
}

/* メイン */
.main {
  flex: 1;
  padding: 30px;
  background: #13294b;
}

/* input / textarea */
input,
textarea {
  width: 100%;
  padding: 8px;
  background: #000;
  border: 3px solid var(--ui-0);
  font-family: "PixelMplus", monospace;
}

input:focus,
textarea:focus {
  border-color: #fff;
}

/* カテゴリ（タグ） */
.category-area {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.category-tag {
  --tag-color: #4fc3f7;

  padding: 6px 10px;
  font-size: 10px;
  border: 1px solid var(--tag-color);
  border-radius: 4px;

  /* ※color-mixは環境により未対応の可能性あり */
  background: rgba(79, 195, 247, 0.20);

  cursor: pointer;
  transition: all 0.15s ease;
}

.category-tag:hover {
  background: rgba(79, 195, 247, 0.35);
}

.category-tag.active {
  background: var(--tag-color);
  color: #000;
}

/* 「＋ タグ追加」 */
.add-category {
  padding: 6px 10px;
  font-size: 10px;
  border-radius: 6px;
  border: 1px dashed #4fc3f7;
  background: transparent;
  color: #4fc3f7;
  cursor: pointer;
  transition: all 0.15s ease;
}

.add-category:hover {
  background: rgba(79, 195, 247, 0.2);
}

/* ボタンエリア */
.button-area {
  margin-top: 30px;
}

/* 作成ボタン（見た目は theme の hover も効く） */
.create {
  padding: 10px 20px;
  background: #000;
  color: #fff;
  border: 4px solid #4fc3f7;
  box-shadow: 6px 6px 0 #000;
  cursor: pointer;
}

.create:active {
  box-shadow: 1px 1px 0 #000;
  transform: translate(3px, 3px);
}

/* 日付セル（流用時） */
.date-cell {
  overflow-y: auto;
}

/* モーダル背景 */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
}

/* モーダル本体 */
.modal-content {
  background: #000;
  color: #fff;
  border: 4px solid #4fc3f7;
  box-shadow: 6px 6px 0 #000;
  padding: 20px;

  max-height: 80vh;
  overflow: auto;

  width: 280px;
  max-width: 90vw;
  animation: questFloat 1.6s ease-in-out infinite;
}

/* モーダル中央寄せ */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);

  /* ✅ 中央ポップアップ */
  align-items: center;
  justify-content: center;

  /* ✅ ほか要素より前面 */
  z-index: 3000;
}

/* JSが display:flex にするので保険（class方式にしたい場合） */
.modal.open {
  display: flex;
}