/* static/style.css */

body {
    font-family: 'Noto Sans JP', sans-serif;
    background-color: #fdf6f0; /* やわらかいベージュ */
    color: #3e2723;           /* 濃いブラウン寄りの文字色 */
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
  }
  
  header {
    width: 100%;
    text-align: center;
    padding: 1em 0;
    background-color: #eed1b7;
    border-bottom: 1px solid #ccc;
    box-sizing: border-box;
  }
  
  footer {
    width: 100%;
    background-color: #eed1b7;
    color: #3e2723;
    font-size: 0.9em;
    padding: 1em 0;
    text-align: center;
    box-shadow: 0 -2px 6px rgba(0, 0, 0, 0.05); /* 上にうっすら影をつける */
    border-top: 1px solid #d4b59e; /* 上に薄い線を入れて「区切り感」出す */
  }
  
.container {
  width: 90%;
  max-width: none;
  padding: 2em;
  margin: 0 auto;
  box-sizing: border-box;
  background: #fffaf2;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
  border-radius: 10px;
  margin-bottom: 4em;
  flex: 1;
  background-color: #fefaf7;
}
  
  html, body {
    height: 100%;
  }

  h1, h2, h3 {
    color: #222;
    font-weight: 600;
  }
  
  button {
    background-color: #1976d2;
    color: white;
    border: none;
    padding: 0.5em 1.2em;
    margin: 0.2em;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.3s;
  }
  
  button:hover {
    background-color: #1565c0;
  }
  
  /* 削除ボタン専用（赤） */
  button[value="delete_user"],
  form[action$="delete_date"] button {
    background-color: #e53935;
  }
  
  button[value="delete_user"]:hover,
  form[action$="delete_date"] button:hover {
    background-color: #c62828;
  }
  
  table {
    border-collapse: collapse;
    width: 100%;
    margin-bottom: 1em;
  }
  
  table th, table td {
    padding: 0.8em;
    border: 1px solid #ddd;
    text-align: center;
    font-size: 0.95em;
  }
  
  table th {
    background-color: #f0f0f0;
  }
  
  input[type="text"],
  input[type="password"],
  textarea,
  select {
    padding: 0.5em;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: 100%;
    margin-bottom: 0.5em;
    box-sizing: border-box;
  }
  
  /* フォーム系調整 */
  form label {
    display: inline-block;
    margin-right: 0.5em;
    font-weight: bold;
  }
  
  form input, form select {
    margin-right: 1em;
    margin-bottom: 0.5em;
  }
  
  textarea {
    width: 100%;
    font-family: inherit;
    font-size: 1em;
    border-radius: 6px;
  }
  
  /* イベント編集行の横並び */
  .event-row form {
    display: inline-block;
    margin-right: 0.3em;
  }
  
  .event-row input[type="text"] {
    width: 200px;
    display: inline-block;
    vertical-align: middle;
  }
  
  /* イベント追加にも使う入力欄サイズ統一 */
  .event-input {
    width: 200px;
    max-width: 100%;
    padding: 0.5em;
    border: 1px solid #ccc;
    border-radius: 4px;
  }
  .event-button {
    margin-left: 0.5em;
  }
  .event-edit-block {
    display: flex;
    align-items: center;
    gap: 0.5em;
  }  
  /* イベント追加フォーム入力欄のサイズ指定（確実に上書き） */
input.event-input {
    width: 200px !important;
  }  

#editor {
    background-color: white;
    border: 1px solid #ccc;
    border-radius: 6px;
    padding: 10px;
  }  

/* ユーザー追加フォームのレイアウト調整 */
.user-add-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1em;
  margin-bottom: 1em;
}

/* 入力欄のサイズ指定 */
.input-short {
  width: 200px !important;
}

.input-medium {
  width: 250px !important;
}

.user-add-form label {
  font-weight: bold;
  margin-right: 0.3em;
}

/* ユーザー追加フォーム：縦並びバージョン */
.user-add-form-vertical > div {
  margin-bottom: 0.5em;
}

.user-add-form-vertical label {
  display: inline-block;
  width: 100px;
  font-weight: bold;
}

.select-compact {
  width: 120px;
  padding: 0.4em;
  font-size: 1em;
}

h2, h3 {
  background-color: #5d4037; /* こげ茶 */
  color: white;              /* 白抜き文字 */
  padding: 0.3em 0.6em;
  border-radius: 6px;
}
/* notice-area（伝達事項）内ではh2,h3の茶帯を無効化 */
.notice-area h2, .notice-area h3 {
  background: none;
  color: inherit;
  padding: 0;
  border-radius: 0;
  font-size: 1.5em; /* これは好みで微調整可 */
  font-weight: bold;
  margin-top: 1em;
  margin-bottom: 0.5em;
}
/* 管理画面の伝達事項エディター内（Quill）のh2,h3は茶帯なしにする */
#editor h2, #editor h3,
#editor2 h2, #editor2 h3 {
  background: none !important;
  color: inherit !important;
  padding: 0 !important;
  border-radius: 0 !important;
  font-size: 1.5em; /* 見出しらしく少し大きめに */
  font-weight: bold;
  margin-top: 1em;
  margin-bottom: 0.5em;
}
button {
  background-color: #a97458;
  color: white;
}

button:hover {
  background-color: #8d6e63;
}
.pawmask {
  width: 30px;
  height: 30px;
  vertical-align: middle;
  margin-right: 0.5em;
}
.heading-matcha {
  background-color: #6b8e23; /* 抹茶色 */
  color: white;
  padding: 0.3em 0.6em;
  border-radius: 6px;
}
#editor2 {
  background-color: white !important;
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 10px;
}
/* ユーザー管理テーブルのフォントとボタン調整 */
#sortable-users td, #sortable-users th {
  font-size: 0.85em;
  padding: 0.4em 0.6em;
}

#sortable-users button {
  font-size: 0.75em;
  padding: 0.3em 0.8em;
}
thead th {
  background-color: #f0f0f0;
  position: sticky;
  top: 0;
  z-index: 2;
}
.comment-table td,
.comment-table th {
  padding: 0.3em 0.5em;
  line-height: 1.2;
  font-size: 0.85em;
}
.select-small {
  width: 80px;
  padding: 0.3em;
  font-size: 1em;
}
.welcome-banner {
  background-color: #f4c2c2; /* くすんだピンク（桜色寄り） */
  color: #3e2723;            /* 濃いブラウンで文字 */
  padding: 0.3em 0.6em;
  border-radius: 6px;
  margin-bottom: 1em;
}
.event-name-column {
  width: 160px;
  min-width: 160px;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
  font-size: 1em;
  font-weight: normal;
  text-align: left;
  padding-left: 0.5em;
  position: sticky;
  left: 0;
  background-color: #fffaf2; /* 背景を同じ色で固定感 */
  z-index: 1;  /* 上に重なるように */
}

th.event-name-column {
  position: sticky;
  top: 0;
  left: 0;
  z-index: 11;
  background-color: #f0f0f0;
  text-align: center;
  padding-left: 0;
  font-size: 1em;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
  min-width: 160px;
  width: 160px;
}
/* PC表示用の入力欄サイズ（共通で指定） */
#login-form label {
  display: block;
  margin-top: 1em;
  font-weight: bold;
}
#login-form input[type="text"],
#login-form input[type="password"] {
  width: 300px;
}
thead th {
  position: sticky;
  top: 0;
  background-color: #f0f0f0;
  z-index: 5;
}
.user-name-column {
  font-size: 0.8em;
  font-weight: 400;
  color: #444;
  white-space: nowrap;
}
.status-select {
  width: 60px;
  padding: 0.3em;
  font-size: 0.95em;
  text-align: center;
}
.status-cell {
  text-align: center;
  font-weight: bold;
  padding: 0.4em;
}

.status-◎ {
  background-color: #a2d6a5; /* 濃いグリーン */
}

.status-〇 {
  background-color: #c8e6c9; /* 薄いグリーン */
}

.status-△ {
  background-color: #fff9c4; /* 薄い黄色 */
}

.status-✕ {
  background-color: #fad5e2; /* 薄い桃色 */
}
.attendance-table td,
.attendance-table th {
  padding: 0.3em 0.5em;  /* ← デフォルトより少なめに */
  line-height: 1.2;      /* ← 行の高さもコンパクトに */
}
.status-select {
  height: 1.8em;
}
.comment-input {
  width: 100%;
  max-width: 600px;
  font-size: 0.9em;
  padding: 0.3em;
  line-height: 1.3;
  resize: none;
  margin-bottom: 0.5em;
}

.comment-input:focus {
  outline: none;
  border-color: #a97458;
  box-shadow: 0 0 3px rgba(169, 116, 88, 0.5);
}

textarea.comment-input {
  height: 2.5em;  /* 実質1行分で表示 */
}
.password-input {
  width: 25% !important;
  min-width: 180px;
  padding: 0.4em;
}
.status-cell:empty,
.status-cell:not([class*="status-"]) {
  background-color: transparent !important;
}
.status-none {
  background-color: transparent;
}
.mobile-note {
  display: none;  /* デフォルトは非表示（PCでは見えない） */
  font-size: 0.9em;
  color: #999;
  margin: 0.5em 0;
}
.setting-block {
  display: flex;
  align-items: center;
  gap: 0.5em;
}
@media (max-width: 768px) {
  #login-form input[type="text"],
  #login-form input[type="password"]{
    font-size: 1.3em !important;
    padding: 0.6em;
  }
  #login-form label {
    font-size: 1.1em !important;
  }

  #login-form button {
    font-size: 1.1em !important;
    padding: 0.6em 1.2em;
  }
  .attendance-table th,
  .attendance-table td {
    font-size: 0.75em;
    padding: 0.3em 0.4em;
  }

  .event-name-column,
  th.event-name-column {
    font-size: 0.8em;
    min-width: 120px;
    width: 120px;
  }

  .status-select {
    width: 50px;
    font-size: 0.8em;
  }

  .user-name-column {
    font-size: 0.7em;
  }

  .comment-input {
    font-size: 0.8em;
    padding: 0.2em;
    height: 3.5em !important;
  }

  button {
    padding: 0.4em 0.8em;
    font-size: 1em;  /* ← ボタンもやや大きく */
  }

  .password-input {
    width: 90% !important;
  }
  .container {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto;
    padding: 1em;
  }

  input[type="text"],
  input[type="password"],
  select,
  textarea {
    font-size: 1.1em;  /* ← 1em → 1.1em にアップ */
    padding: 0.5em;
  }

  label {
    font-size: 1em;  /* ← 0.9em → 1em にアップ */
  }
  h2, h3 {
    font-size: 1.3em;
    padding: 0.4em 0.6em;
  }

  .welcome-banner {
    font-size: 0.95em;
    padding: 0.4em 0.6em;
  }
  .pawmask {
    vertical-align: middle;
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-right: 0.5em;
    object-fit: contain;
  }
  p {
    font-size: 0.95em;
  }
  .drag-note {
    display: none;
  }
  .event-edit-block {
    flex-direction: column;
    align-items: flex-start;
  }

  .event-input {
    width: 100%;
    max-width: 300px;
  }

  .event-button {
    width: 120px; /* ←ボタンの幅を固定する！ */
    margin-top: 0.3em;
  }
  .example-text {
    flex-basis: 100%;
    margin-left: 0.5em;
    font-size: 0.9em;
    color: gray;
  }  
  .mobile-note {
    display: block;  /* スマホだけ表示する */
  }
  .user-add-form-vertical label {
    display: block;
    margin-bottom: 0.3em;
  }
  
  .user-add-form-vertical input {
    width: 100%;
    margin-bottom: 1em;
  }
    /* その他設定フォームを縦並びにする */
  form[action$="update_choice_type"],
  form[action$="update_contact_email"] {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5em;
  }

  /* プルダウンや入力欄も幅いっぱいにする */
  form[action$="update_choice_type"] select,
  form[action$="update_contact_email"] input[type="email"] {
    width: 100%;
  }

  /* ボタンも幅いっぱいにする（自然な感じに） */
  form[action$="update_choice_type"] button,
  form[action$="update_contact_email"] button {
    width: 100%;
  }
  .setting-block {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.3em;
  }
}
.drag-handle {
  font-size: 1.2em;
  text-align: center;
  color: #333;
}
/* @media (max-width: 1024px) {
  .drag-note {
    display: none;
  }
  .mobile-note {
    display: block;
  }
} */
/* ログインフォームの入力欄サイズ調整（PC基準） */
#login-form input[type="text"],
#login-form input[type="password"] {
  width: 100%;
  max-width: 280px;
}

/* ログインボタンをコンセプトカラーで統一 */
#login-form button {
  background-color: #a97458;
  color: white;
  width: 100%;
  max-width: 150px;
}

#login-form button:hover {
  background-color: #8d6e63;
}

/* ログインボックス全体の幅調整 */
#login-form {
  max-width: 320px;
  margin: 0 auto;
}

.login-box h2 {
  max-width: 380px;
  margin: 0 auto;
}

/* オーナー画面のクラブ一覧テーブルをコンパクトにする */
.compact-table th,
.compact-table td {
  padding: 0.3em 0.5em;
  font-size: 0.85em;
}

.compact-table button {
  font-size: 0.75em;
  padding: 0.3em 0.7em;
}

.scroll-table {
  max-height: 400px;
  overflow-y: auto;
  margin-bottom: 1em;
  border: 1px solid #ccc;
}

/* イベントの状態表示スタイル */
.event-hidden {
  text-decoration: line-through;
}
.event-link {
  text-decoration: underline;
}
.event-closed {
  color: gray;
}

.event-link.event-hidden {
  text-decoration: line-through underline;
}

.attendance-table-wrapper {
  overflow-x: auto;
  width: 100%;
}

.attendance-table {
  min-width: 700px;
  width: max-content;
}

.register-box {
  max-width: 380px;
  margin: 0 auto;
}

.ad-banner {
  background-color: #fff3cd;
  border-left: 5px solid #ffecb5;
  padding: 1em;
  margin: 1em auto;
  border-radius: 6px;
  max-width: 800px;
  box-shadow: 0 0 6px rgba(0,0,0,0.05);
}
/* イベント一覧テーブルをコンパクトにする */
#event-list td,
#event-list th {
  font-size: 0.85em;
  padding: 0.4em 0.6em;
}

/* イベントテーブルにスクロールをつける */
.event-table-wrapper {
  max-height: 400px;
  overflow-y: auto;
  border: 1px solid #ccc;
  margin-bottom: 1em;
}

.footer-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5em;
}
