/**
 * 試合種別管理タブ用スタイル
 */

/* セクション */
.game-kinds-section {
  padding: 0;
}

/* サブタブナビゲーション */
.game-kinds-subtabs {
  display: flex;
  gap: 0;
  margin-bottom: 1.5rem;
  border-bottom: 2px solid var(--admin-border);
}

.game-kinds-subtab {
  padding: 0.75rem 1.5rem;
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 0.95rem;
  color: var(--admin-text-muted);
  transition: all 0.2s;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
}

.game-kinds-subtab:hover {
  color: var(--admin-primary);
  background: var(--admin-primary-light);
}

.game-kinds-subtab.active {
  color: var(--admin-primary);
  border-bottom-color: var(--admin-primary);
  font-weight: 600;
}

/* サブタブコンテンツ */
.game-kinds-subtab-content {
  display: none;
}

.game-kinds-subtab-content.active {
  display: block;
}

/* サブタブヘッダー */
.subtab-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding: 0 0.5rem;
}

.subtab-header h3 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--admin-text);
}

.subtab-header-left {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.subtab-header-left h3 {
  margin: 0;
}

/* テーブル */
.game-kinds-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.game-kinds-table th,
.game-kinds-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--admin-border);
}

.game-kinds-table th {
  background: var(--admin-bg-secondary);
  font-weight: 600;
  color: var(--admin-text);
}

.game-kinds-table tbody tr:hover {
  background: var(--admin-bg-hover);
}

.game-kinds-table .loading {
  text-align: center;
  color: var(--admin-text-muted);
  padding: 2rem;
}

/* ステータスバッジ */
.game-kinds-table .status-badge {
  display: inline-block;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 500;
}

.game-kinds-table .status-badge.active {
  background: var(--admin-success-light);
  color: var(--admin-success);
}

.game-kinds-table .status-badge.inactive {
  background: var(--admin-danger-light);
  color: var(--admin-danger);
}

/* 操作ボタン */
.game-kinds-table .btn-action {
  padding: 0.25rem 0.5rem;
  font-size: 0.8rem;
  margin-right: 0.25rem;
}

/* プリセット構成表示 */
.preset-items-display {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.preset-item-badge {
  display: inline-block;
  padding: 0.15rem 0.4rem;
  background: var(--admin-primary-light);
  color: var(--admin-primary);
  border-radius: 3px;
  font-size: 0.75rem;
}

.preset-item-badge.group {
  background: var(--admin-info-light);
  color: var(--admin-info);
}

/* プリセット編集モーダル */
.preset-items-container {
  max-height: 300px;
  overflow-y: auto;
  border: 1px solid var(--admin-border);
  border-radius: 4px;
  padding: 1rem;
}

.preset-group-section {
  margin-bottom: 1rem;
}

.preset-group-section:last-child {
  margin-bottom: 0;
}

.preset-group-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  padding: 0.5rem;
  background: var(--admin-bg-secondary);
  border-radius: 4px;
}

.preset-group-header input[type='checkbox'] {
  margin: 0;
}

.preset-group-header label {
  font-weight: 600;
  cursor: pointer;
}

.preset-group-items {
  padding-left: 1.5rem;
}

.preset-group-items label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0;
  cursor: pointer;
}

.preset-group-items label:hover {
  background: var(--admin-bg-hover);
}

/* フォームレイアウト */
.form-row {
  display: flex;
  gap: 1rem;
}

.form-group-half {
  flex: 1;
}

.form-group-small {
  flex: 0 0 120px;
}

.form-check {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
}

.form-check input[type='checkbox'] {
  margin: 0;
}

/* モーダル */
.modal-large .modal-content {
  max-width: 800px;
}

/* プリセットモーダル: 固定高さを解除 */
#preset-modal .modal-content {
  height: auto;
  max-height: 90vh;
}

#preset-modal .modal-body {
  flex: none;
}

/* 同期ボタン */
#sync-game-kinds-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

#sync-game-kinds-btn.syncing {
  opacity: 0.7;
  pointer-events: none;
}

/* フィルタ */
.filter-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.filter-group label {
  font-size: 0.9rem;
  color: var(--admin-text-muted);
}

.filter-group select {
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--admin-border);
  border-radius: 4px;
  font-size: 0.9rem;
  background: white;
}

/* 空状態 */
.empty-state {
  text-align: center;
  padding: 3rem;
  color: var(--admin-text-muted);
}

.empty-state-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.empty-state-text {
  font-size: 1rem;
}

/* プリセット編集モーダルの説明欄 */
#preset-description {
  min-height: auto;
}

/* プリセット編集モーダルの余白調整 */
#preset-form .form-group:last-of-type {
  margin-bottom: 0.25rem;
}

#preset-form .modal-footer {
  margin-top: 0.5rem;
  padding-top: 0.75rem;
}
