/* Style Sheet for Minecraft-Map */

/* 初期化 */
html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

/* h1, h2 中央揃え */
h1, h2 {
  text-align: center;
  font-family: sans-serif;
  color: #333;
  margin-top: 20px;
}

/* ページフッター */
.page-footer {
  width: 100%;
  text-align: right;
  font-family: sans-serif;
  font-size: 14px;
  background-color: #eeeeee;
  padding: 12px 20px 12px 0;
  margin: 60px 0 0;
  position: relative;
  box-sizing: border-box;
}

.page-footer a {
  text-decoration: none;
}


/* 説明部分とボタン表示 */
.map-description {
  text-align: center;
  font-family: sans-serif;
  font-size: 14px;
  color: #555;
  margin-top: -10px;
  margin-bottom: 20px;
}

.jump-form {
  max-width: 530px;
  margin: 20px auto;
  padding: 12px 16px;
  border: 1px solid #ccc;
  border-radius: 8px;
  background-color: #f8f8f8;
  font-family: sans-serif;
  font-size: 14px;
  color: #333;
  text-align: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.jump-form label {
  margin: 0 8px;
}

.jump-form input {
  width: 80px;
  padding: 4px;
  font-size: 14px;
}

.jump-form button {
  padding: 6px 12px;
  font-size: 14px;
  background-color: #4CAF50;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.jump-form button:hover {
  background-color: #45a049;
}

/* ツールメニューのドロワー */

.settings-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
  padding: 10px 14px;
  font-size: 14px;
  background-color: #4CAF50;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.settings-panel {
  position: fixed;
  top: 0;
  right: -300px; /* 完全に隠れるよう調整（-1 * width） */
  width: 300px;
  height: 100%;
  text-align: center;
  background-color: #f9f9f9;
  border-left: 1px solid #ccc;
  box-shadow: -2px 0 6px rgba(0, 0, 0, 0.1);
  padding: 20px;
  transition: right 0.3s ease;
  z-index: 999;
  box-sizing: border-box;
  overflow-y: auto;  /* ドロワーの表示が増えたときにスクロール */
}

.settings-panel.open {
  right: 0; /* 表示状態 */
}

.settings-panel h2 {
  margin-top: 60px;
  font-size: 16px;
}

#settingsPanel input[type="number"] {
  width: 55px;
}

/* ドロワーの簡易座標リスト */
#drawerTable table {
  font-size: 12px;
  border-collapse: collapse;
  width: 100%;
  margin-top: 10px;
}
#drawerTable th, #drawerTable td {
  border: 1px solid #ccc;
  padding: 4px 6px;
}
#drawerTable tbody tr:hover {
  background-color: #e0f7fa;
  cursor: pointer;
}

/* キャンバスの中央表示＋スタイル */
#mapCanvas {
  display: block;
  margin: 30px auto;
  border: 1px solid #ccc;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
}

/* 表全体：幅をマップに合わせる（800px） */
table {
  width: 800px;
  margin: 20px auto;
  border-collapse: collapse;
  font-family: sans-serif;
  font-size: 14px;
  background-color: #fdfdfd;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

/* ヘッダー行 */
thead {
  background-color: #4CAF50;
  color: white;
}

/* セル共通 */
th, td {
  border: 1px solid #ccc;
  padding: 8px 12px;
  text-align: left;
}

/* 偶数行に薄い背景 */
tbody tr:nth-child(even) {
  background-color: #f9f9f9;
}

/* ホバー時にハイライト */
tbody tr:hover {
  background-color: #e0f7fa;
  cursor: pointer;
}


/* 表の開閉 */
#tableContainer {
  width: 800px;
  margin: 20px auto;
}

#tableToggleBtn {
  display: block;
  margin: 0 auto 10px;
  padding: 6px 12px;
  background-color: #4CAF50;
  color: white;
  font-size: 14px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

#coordTableWrapper {
  display: none;
}

#coordTableWrapper.open {
  display: block;
}

// 気持ちばかりのレスポンシブ対応
@media screen and (max-width: 820px) {
  body {
    font-size: 18px;
  }

  canvas {
    font-size: 18px;
  }

  .jump-form {
    font-size: 16px;
  }

  .jump-form input,
  .jump-form button {
    font-size: 16px;
  }

  .settings-panel {
    font-size: 16px;
  }

  #drawerTable table {
    font-size: 16px;
  }

  #drawerTable th,
  #drawerTable td {
    padding: 6px 8px;
  }

  table {
    font-size: 16px;
  }

  th, td {
    padding: 10px;
  }
}
