/**
 * ダブルエリミネーション表 専用スタイル
 */

.deb-options-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 14px 20px;
	padding: 16px 20px;
	border-top: 1px solid var(--color-border);
}

@media (max-width: 600px) {
	.deb-options-grid {
		grid-template-columns: 1fr;
	}
}

.deb-option {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.deb-option-label {
	font-size: 13px;
	font-weight: 600;
	color: var(--color-text);
}

.deb-option-select {
	padding: 10px 12px;
	font-size: 14px;
	border: 1px solid var(--color-border);
	border-radius: 6px;
	background: var(--color-bg);
	font-family: inherit;
	cursor: pointer;
}

.deb-option-select:focus {
	outline: none;
	border-color: #C0392B;
}

.deb-option-hint {
	font-size: 11.5px;
	color: var(--color-text-muted);
	line-height: 1.5;
}

/* ========================================
   ブラケットセクション
   ======================================== */
.deb-bracket-section {
	padding: 16px 0 0;
	border-top: 1px solid var(--color-border);
}

.deb-bracket-header {
	padding: 0 20px;
	margin-bottom: 10px;
}

.deb-bracket-title {
	font-family: var(--font-display);
	font-size: 16px;
	font-weight: 700;
	color: var(--color-text);
	margin: 14px 0 4px;
	padding-left: 8px;
	border-left: 4px solid #2E8B57;
}

.deb-bracket-title--losers {
	border-left-color: #C0392B;
}

.deb-bracket-title--grand {
	border-left-color: #DBA935;
}

.deb-bracket-wrap {
	overflow-x: auto;
	padding: 0 20px 14px;
}

/* ========================================
   ブラケット本体（ラウンド横並び）
   ======================================== */
.deb-bracket {
	display: flex;
	gap: 22px;
	min-width: min-content;
	align-items: stretch;
}

.deb-round {
	display: flex;
	flex-direction: column;
	gap: 12px;
	justify-content: space-around;
	min-width: 180px;
}

.deb-round-label {
	font-family: var(--font-display);
	font-size: 11.5px;
	font-weight: 700;
	color: var(--color-text-muted);
	text-align: center;
	letter-spacing: 0.05em;
	padding: 4px 6px;
	background: #F0F5FB;
	border-radius: 3px;
}

.deb-match {
	display: flex;
	flex-direction: column;
	background: var(--color-white);
	border: 1px solid var(--color-border);
	border-radius: 6px;
	overflow: hidden;
	font-size: 12.5px;
}

.deb-match-slot {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 7px 9px;
	cursor: pointer;
	transition: background 0.15s;
	border-bottom: 1px dashed var(--color-border-light, #EAE7E0);
}

.deb-match-slot:last-child {
	border-bottom: none;
}

.deb-match-slot:hover:not(.deb-match-slot--empty):not(.deb-match-slot--bye) {
	background: #F4F8FF;
}

.deb-match-slot--winner {
	background: linear-gradient(90deg, #E8F5EC 0%, #FFFFFF 100%);
	font-weight: 700;
}

.deb-match-slot--loser {
	color: var(--color-text-muted);
	text-decoration: line-through;
}

.deb-match-slot--bye {
	background: #FAFAF8;
	color: var(--color-text-muted);
	cursor: default;
	font-style: italic;
}

.deb-match-slot--empty {
	color: #C0C0C0;
	cursor: default;
}

.deb-slot-seed {
	flex-shrink: 0;
	display: inline-block;
	width: 20px;
	text-align: right;
	font-family: var(--font-display);
	font-size: 10.5px;
	font-weight: 700;
	color: var(--color-text-muted);
}

.deb-slot-name {
	flex: 1;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	font-weight: 600;
	color: var(--color-text);
}

.deb-match-slot--loser .deb-slot-name {
	color: var(--color-text-muted);
}

.deb-slot-mark {
	flex-shrink: 0;
	display: inline-block;
	width: 14px;
	height: 14px;
	font-size: 11px;
	font-weight: 700;
	text-align: center;
}

.deb-slot-mark--win {
	color: #2E8B57;
}

/* Losers Bracket は赤系 */
.deb-bracket--losers .deb-match-slot--winner {
	background: linear-gradient(90deg, #FCEFE8 0%, #FFFFFF 100%);
}

/* Grand Finals は金系 */
.deb-bracket--grand {
	justify-content: center;
}

.deb-bracket--grand .deb-match {
	border-color: #DBA935;
	box-shadow: 0 2px 8px rgba(219, 169, 53, 0.20);
}

.deb-bracket--grand .deb-match-slot--winner {
	background: linear-gradient(90deg, #FFF5DD 0%, #FFFFFF 100%);
}

/* ========================================
   優勝者表示
   ======================================== */
.deb-champion {
	margin: 16px 20px 0;
	padding: 18px 20px;
	background: linear-gradient(135deg, #DBA935 0%, #B58A23 100%);
	color: #FFFFFF;
	border-radius: 10px;
	text-align: center;
	box-shadow: 0 4px 14px rgba(219, 169, 53, 0.30);
}

.deb-champion-label {
	font-size: 13px;
	letter-spacing: 0.08em;
	margin-bottom: 6px;
	font-family: var(--font-display);
}

.deb-champion-name {
	font-family: var(--font-display);
	font-size: 26px;
	font-weight: 800;
	letter-spacing: 0.04em;
}

/* ========================================
   アクション
   ======================================== */
.deb-actions {
	display: flex;
	gap: 10px;
	justify-content: space-between;
	align-items: center;
	padding: 14px 20px;
	border-top: 1px solid var(--color-border);
	margin-top: 16px;
}

@media (max-width: 600px) {
	.deb-actions {
		flex-direction: column-reverse;
		align-items: stretch;
	}
}
