body {
	background-color: #1a1a1a;
	color: #ffffff;
	font-family: Helvetica, sans-serif;
	margin: 0;
	padding: 20px;
	min-height: 100dvh;
	display: grid;
	place-items: center;
}

.bg-video {
	position: fixed;
	inset: 0;
	object-fit: contain;
	z-index: -1;
	opacity: .1;
	min-height: 100%;
	object-position: top center;
	min-width: 100%;
}

.container {
	width: 100%;
	max-width: 1600px;
	display: grid;
	align-items: stretch;
	text-align: center;
}

.timer {
	font-size: clamp(24px, min(35vh, 30vw), 600px);
	margin: 40px 0;
	font-weight: bold;
	color: #4CAF50;
}

.level-info {
	font-size: 36px;
	margin: 20px 0;
}

.next-level {
	font-size: 24px;
	color: #888;
	margin: 20px 0;
}

.controls {
	margin: 20px 0;
}

button {
	background-color: #4CAF50;
	border: none;
	color: white;
	padding: 15px 32px;
	text-align: center;
	text-decoration: none;
	display: inline-block;
	font-size: 16px;
	margin: 4px 2px;
	cursor: pointer;
	border-radius: 4px;
}

button:disabled {
	background-color: #555;
	cursor: not-allowed;
}

.break {
	color: #FFA500;
}

dialog {
	background-color: #2a2a2a;
	color: #ffffff;
	padding: 20px;
	border: 1px solid #888;
	width: 80%;
	max-width: 600px;
	border-radius: 8px;
	max-height: calc(100vh - 100px);
	overflow-y: auto;
}

dialog::backdrop {
	background-color: rgba(0, 0, 0, 0.7);
}

.modal-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 20px;
}

.modal-close-form {
	margin: 0;
}

.close {
	background: transparent;
	border: none;
	color: #aaa;
	font-size: 28px;
	font-weight: bold;
	cursor: pointer;
	padding: 0;
	margin: 0;
	line-height: 1;
}

.close:hover {
	color: #fff;
}

.add-player {
	margin-bottom: 20px;
	display: flex;
	gap: 10px;
}

.add-player input {
	flex: 1;
	padding: 8px;
	border: 1px solid #444;
	border-radius: 4px;
	background-color: #333;
	color: white;
}

.players-list {
	margin-bottom: 20px;
}

.player-card {
	background-color: #333;
	padding: 15px;
	margin-bottom: 10px;
	border-radius: 4px;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.player-info {
	flex: 1;
}

.player-name {
	font-weight: bold;
	margin-bottom: 5px;
}

.player-stats {
	color: #888;
	font-size: 14px;
}

.player-actions {
	display: flex;
	gap: 10px;
}

.tournament-stats {
	border-top: 1px solid #444;
	padding-top: 20px;
	margin-top: 20px;
}

.prizes {
	margin-top: 15px;
	padding-top: 15px;
	border-top: 1px solid #444;
}

.prizes h4 {
	margin-bottom: 10px;
	color: #4CAF50;
	font-size: 16px;
}

#playerName {
	margin-right: 10px;
}

.edit-name-input {
	padding: 4px 8px;
	border: 1px solid #4CAF50;
	border-radius: 4px;
	background-color: #333;
	color: white;
	font-size: inherit;
	font-weight: bold;
}

.player-actions button {
	padding: 8px 12px;
	font-size: 14px;
}

.edit-btn {
	background-color: #2196F3;
}

.reentry-add-btn, .reentry-remove-btn {
	background-color: #FF9800;
	padding: 8px 10px !important;
}

.remove-btn {
	background-color: #f44336;
}

.settings-section {
	margin-bottom: 25px;
}

.settings-section h3 {
	margin-bottom: 15px;
	color: #4CAF50;
}

.setting-item {
	margin-bottom: 15px;
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
}

.setting-item label {
	flex: 0 0 150px;
}

.setting-item input, .setting-item select {
	flex: 1;
	padding: 8px;
	border: 1px solid #444;
	border-radius: 4px;
	background-color: #333;
	color: white;
}

.setting-hint {
	font-size: 12px;
	color: #888;
	width: 100%;
	margin-left: 160px;
}

.setting-item select option {
	background-color: #333;
	color: white;
}

#levelsContainer {
	margin-bottom: 15px;
	max-height: 300px;
	overflow-y: auto;
}

.level-item {
	background-color: #333;
	padding: 10px;
	margin-bottom: 10px;
	border-radius: 4px;
	display: flex;
	align-items: center;
	gap: 10px;
}

.level-item.break {
	background-color: #554433;
}

.level-number {
	flex: 0 0 80px;
	font-weight: bold;
}

.level-blinds {
	display: flex;
	gap: 10px;
	align-items: center;
	flex: 1;
}

.level-blinds input {
	width: 60px;
	padding: 5px;
	border: 1px solid #444;
	border-radius: 4px;
	background-color: #222;
	color: white;
	text-align: center;
}

.level-remove {
	background-color: #f44336;
	padding: 5px 10px;
	font-size: 12px;
}

.add-level-btn, .add-break-btn {
	margin-right: 10px;
}

.add-break-btn {
	background-color: #FF9800;
}

.settings-actions {
	margin-top: 20px;
	display: flex;
	gap: 10px;
	justify-content: center;
}

#resetSettingsBtn {
	background-color: #f44336;
}

#newTournamentBtn {
	background-color: #FF5722;
}

.pwa-install-btn {
	position: fixed;
	top: 16px;
	right: 16px;
	padding: 8px 16px;
	font-size: 14px;
	margin: 0;
	z-index: 10;
}

.pwa-install-btn[hidden] {
	display: none;
}

.pwa-toast {
	position: fixed;
	right: 16px;
	bottom: 16px;
	background-color: #2a2a2a;
	color: #ffffff;
	padding: 12px 16px;
	border: 1px solid #444;
	border-radius: 6px;
	display: flex;
	align-items: center;
	gap: 12px;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
	z-index: 20;
	max-width: calc(100vw - 32px);
}

.pwa-toast[hidden] {
	display: none;
}

.pwa-toast-text {
	font-size: 14px;
}

.pwa-toast-action {
	padding: 6px 12px;
	font-size: 14px;
	margin: 0;
}
