:root {
	--bg: #0f1720;
	--surface: #0f1724;
	--card: #111820;
	--muted: #9aa4ad;
	--text: #e6eef6;
	--subtle: rgba(255, 255, 255, 0.04);
	--border: rgba(255, 255, 255, 0.06);
	--accent: #4dd0e1;
	--primary: linear-gradient(180deg, #3ac2d6, #0db8c0);
	--danger: #e3576b;
	--success: #5fd1a6;
}

body {
	font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
	background: var(--bg);
	color: var(--text);
}

.card {
	background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent);
	border: 1px solid var(--subtle);
	box-shadow: 0 6px 18px rgba(2, 6, 10, 0.6);
}

.group-card {
	border-radius: 12px;
	padding: 14px;
	background: var(--card);
	margin-bottom: 14px;
	border: 1px solid var(--border);
}

.steam-line {
	display: flex;
	gap: 12px;
	align-items: center;
	margin-bottom: 10px;
	flex-wrap: wrap;
}

.steam-line input.form-control,
.steam-line textarea,
.steam-line select {
	flex: 1 1 160px;
	min-width: 120px;
	width: auto;
	background: rgba(255, 255, 255, 0.02);
	border: 1px solid rgba(255, 255, 255, 0.04);
	color: var(--text);
	padding: 6px 8px;
	border-radius: 8px
}

.steam-line .avatar-thumb {
	flex: 0 0 36px;
}

.steam-line .form-control,
.steam-line input.form-control,
.steam-line select {
	height: 44px;
	min-height: 40px;
	max-height: 56px;
	box-sizing: border-box;
}

.steam-line textarea {
	height: 56px;
	min-height: 48px;
	max-height: 120px;
	resize: vertical;
	box-sizing: border-box;
}

.steam-line .btn,
.steam-line .remove-btn {
	flex: 0 0 auto;
}

.avatar-thumb {
	width: 36px;
	height: 36px;
	object-fit: cover;
	border-radius: 8px;
	border: 1px solid rgba(0, 0, 0, 0.4);
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
}

.comment-label {
	font-weight: 700;
	color: var(--muted);
	letter-spacing: 0.6px
}

.showcolors-input {
	width: auto;
	flex: 0 0 auto;
	margin-left: 4px;
	margin-right: 4px;
	transform: scale(1.0);
}

.form-check-input.showcolors-input {
	width: 18px;
	height: 18px;
	-webkit-appearance: auto;
	appearance: auto;
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 4px;
	background-color: transparent;
	vertical-align: middle;
	accent-color: rgba(95, 209, 166, 0.95);
}

.steam-line.invalid input {
	box-shadow: 0 6px 18px rgba(227, 87, 107, 0.06);
	border-color: rgba(227, 87, 107, 0.35);
}

.steam-line.valid input {
	box-shadow: 0 6px 18px rgba(95, 209, 166, 0.06);
	border-color: rgba(95, 209, 166, 0.35);
}

#newBtn {
	background: transparent;
	color: var(--muted);
	border: none;

	cursor: pointer;
	border-radius: 0;
	color: var(--muted);
	display: flex;
	flex-direction: column;
	align-items: end;
	justify-content: end;
	font-weight: bold;
	user-select: none;

	font-size: 14px;
	border-bottom: 1px solid var(--muted);
	padding: 0;
	padding-bottom: 4px;
}

#newBtn:hover {
	border-color: var(--accent);
}

#fileDrop {
	cursor: pointer;
	border-radius: 10px;
	color: var(--muted);
	display: flex;
	flex-direction: column;
	align-items: end;
	justify-content: end;
	font-weight: bold;
	user-select: none;
}

#dropMessage {
	font-size: 14px;
	border-bottom: 1px solid var(--muted);
	padding-bottom: 4px;
	padding-left: 4px;
	padding-right: 4px;
}

#dropMessage:hover {
	color: var(--accent);
	border-color: var(--accent);
}

#dropMessage:active {
	box-shadow: 0 6px 22px rgba(13, 184, 192, 0.06);
}

#fileDrop.dragover {
	background: linear-gradient(180deg, rgba(77, 208, 225, 0.05), transparent);
	border-color: var(--accent);
	box-shadow: 0 6px 22px rgba(13, 184, 192, 0.06);
}

#fileDrop #dropMessage {
	color: var(--muted);
}

#fileDrop {
	border-color: var(--muted) !important;
}

.spinner {
	width: 18px;
	height: 18px;
	border-radius: 50%;
	border: 2px solid rgba(255, 255, 255, 0.06);
	border-top-color: var(--accent);
	animation: spin 1s linear infinite;
	display: inline-block;
}

@keyframes spin {
	to {
		transform: rotate(360deg);
	}
}

.container {
	max-width: 1100px
}

.card {
	border-radius: 12px;
	color: var(--text) !important;
}

.group-card {
	margin-bottom: 18px
}

.btn-primary {
	background: var(--primary);
	border: none;
	color: #042027;
	box-shadow: 0 6px 18px rgba(8, 20, 25, 0.5);
	border-radius: 10px;
	padding: 6px 12px
}

.btn-secondary {
	border-radius: 10px;
}

.btn-outline-secondary {
	background: transparent;
	border: 1px solid rgba(255, 255, 255, 0.04);
	color: var(--muted);
	border-radius: 10px
}

.btn-success {
	background: var(--success);
	color: #042217;
	border-radius: 8px
}

.btn-sm {
	padding: 6px 8px;
	border-radius: 8px
}

.btn-danger {
	background: linear-gradient(180deg, #e3576b, #d63f56);
	border: none;
	color: #fff;
	padding: 6px 10px
}

.btn-outline-danger {
	border-radius: 10px;
}

.btn-outline-success:hover {
	box-shadow: 0 8px 20px rgba(95, 209, 166, 0.12);
}

#loadFtpBtn {
	border-color: #6afced;
	color: #6afced;
}

#loadFtpBtn:hover {
	background: rgba(106, 252, 237, 0.170);
}

#loadBtn {
	display: flex;
	justify-self: end;
}
#ftpModalConnect {
	width: 100%;
}

#ftpModalTest,
#ftpModalConnect,
#ftpUploadBtn,
#exportBtn,
#exportInEditBtn,
#loadBtn {
	text-align: center;
	margin-top: 0.25em;
	justify-content: center;
	background: transparent;
	border-color: var(--accent) !important;
	color: var(--accent);
	border-radius: 10px;
}

#ftpModalTest,
#ftpModalConnect,
#ftpUploadBtn,
#exportBtn {
	margin: 0;
}

#addGroupBtn {
	border-radius: 10px;
	background: transparent;
	border: 1px solid var(--muted);
	color: var(--muted);
}

#addGroupBtn:hover {
	background: rgba(255, 255, 255, 0.02);
	box-shadow: 0 8px 20px rgba(77, 208, 225, 0.06);
}

#addGroupBtn:active {
	box-shadow: 0 8px 20px rgba(13, 184, 192, 0.12);
}

#ftpModalTest:hover,
#ftpModalConnect:hover,
#ftpUploadBtn:hover,
#exportBtn:hover,
#exportInEditBtn:hover,
#loadBtn:hover {
	background: rgba(77, 208, 225, 0.170);
}

#ftpModalTest:active,
#ftpModalConnect:active,
#ftpUploadBtn:active,
#exportBtn:active,
#exportInEditBtn:active,
#loadBtn:active {
	box-shadow: 0 8px 20px rgba(13, 184, 192, 0.12);
}

#downloadBtn {
	margin: 0;
	background: transparent;
	border: 1px solid;
	border-radius: 10px;
	border-color: var(--success) !important;
	text-align: center;
	justify-content: center;
	color: var(--success);
}

.btn-outline-success {
	background: transparent;
	border: 1px solid;
	border-radius: 10px;
	border-color: rgba(95, 209, 166, 1);
	text-align: center;
	justify-content: center;
	color: rgba(95, 209, 166, 1);
	margin-right: 0.75em !important;
}

.btn-outline-success:hover {
	background: rgba(95, 209, 166, 0.12);
	box-shadow: 0 8px 20px rgba(95, 209, 166, 0.12);
	color: rgba(95, 209, 166, 1);
}

.btn-outline-success:active {
	box-shadow: 0 8px 20px rgba(13, 184, 192, 0.12);
}

/* Stepper styling */
.btn-group .btn {
	border-radius: 8px;
	border: 1px solid rgba(255, 255, 255, 0.03);
	background: transparent;
	color: var(--muted);
}

.btn {
	border-radius: 10px;
}

.btn-group .btn.active,
.btn-group .btn:active {
	background: var(--accent);
	color: #042027;
	box-shadow: 0 8px 20px rgba(13, 184, 192, 0.12);
	border: none
}

.btn-group .btn:not(.active):hover {
	background: rgba(255, 255, 255, 0.02);
	color: var(--text)
}

/* group name editable */
.group-name-input {
	background: transparent;
	border: none;
	color: var(--text);
	font-weight: 700;
	font-size: 14px;
	padding: 4px 8px;
	border-radius: 6px
}

.group-name-input:focus {
	outline: none;
	box-shadow: 0 8px 20px rgba(77, 208, 225, 0.06);
}

footer {
	color: var(--muted);
	opacity: 0.95
}

#exportXml {
	background: rgba(255, 255, 255, 0.02);
	border: 1px solid rgba(255, 255, 255, 0.04);
	color: var(--text);
	border-radius: 8px
}

h1,
h2,
h3,
h4,
h5,
h6 {
	color: var(--text);
	font-weight: 700;
}

.card h5 {
	color: var(--text);
	margin: 0 0 8px 0;
}

.form-label,
label {
	color: var(--muted);
}

#pasteXml {
	background: rgba(255, 255, 255, 0.02);
	border: 1px solid rgba(255, 255, 255, 0.04);
	color: var(--text);
	border-radius: 8px;
	height: 200px
}

#pasteXml.dragover {
	background: linear-gradient(180deg, rgba(77, 208, 225, 0.03), transparent);
	border-color: var(--accent);
	box-shadow: 0 6px 22px rgba(13, 184, 192, 0.04);
}

.avatar-link {
	display: inline-block;
	cursor: pointer;
}

.simple-modal {
	position: fixed;
	left: 0;
	top: 0;
	right: 0;
	bottom: 0;
	z-index: 1300;
	display: none;
}

.simple-modal-backdrop {
	position: absolute;
	left: 0;
	top: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.6);
}

.simple-modal-card {
	position: absolute;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%);
	background: var(--card);
	border-radius: 12px;
	padding: 16px;
	width: 320px;
	box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
	border: 1px solid var(--border);
}

.simple-modal-body {
	margin-bottom: 12px;
	color: var(--text);
	text-align: center
}

.simple-modal-actions {
	display: flex;
	flex-direction: column;
	gap: 10px;
	justify-content: center;
	align-items: stretch;
}

.simple-modal-actions .btn {
	width: 100%;
}

.modal-close-btn {
	position: absolute;
	right: 10px;
	top: 10px;
	background: transparent;
	border: none;
	color: var(--text);
	font-size: 20px;
	line-height: 1;
	padding: 6px 8px;
	border-radius: 8px;
	cursor: pointer
}

.modal-close-btn:hover {
	background: rgba(255, 255, 255, 0.02);
}

.card .form-control,
.card .form-control.form-control-sm,
.simple-modal .form-control,
.simple-modal .form-control.form-control-sm {
	background: rgba(255, 255, 255, 0.02);
	border: 1px solid rgba(255, 255, 255, 0.04);
	color: var(--text);
	padding: 6px 8px;
	border-radius: 8px;
}

.card .form-control:focus,
.simple-modal .form-control:focus {
	outline: none;
	box-shadow: 0 8px 20px rgba(77, 208, 225, 0.06);
}

.card .form-control::placeholder,
.card .form-control.form-control-sm::placeholder,
.simple-modal .form-control::placeholder,
.simple-modal .form-control.form-control-sm::placeholder {
	color: rgba(255, 255, 255, 0.45);
}

/* toast styles */
.toast-card {
	background: var(--card);
	color: var(--text);
	padding: 12px;
	border-radius: 10px;
	margin-top: 10px;
	min-width: 260px;
	border: 1px solid rgba(255, 255, 255, 0.04);
	box-shadow: 0 8px 28px rgba(0, 0, 0, 0.6);
	display: flex;
	flex-direction: column;
	gap: 8px
}

.toast-card .toast-message {
	color: var(--text);
}

.toast-actions {
	display: flex;
	gap: 8px;
	justify-content: flex-end
}

.toast-card-persistent {
	background: linear-gradient(180deg, rgba(227, 87, 107, 0.12), rgba(227, 87, 107, 0.04));
	border-color: rgba(227, 87, 107, 0.45);
	box-shadow: 0 12px 36px rgba(227, 87, 107, 0.12);
}

.toast-card-success {
	background: linear-gradient(180deg, rgba(95, 209, 166, 0.12), rgba(95, 209, 166, 0.04));
	border-color: rgba(95, 209, 166, 0.45);
	box-shadow: 0 12px 36px rgba(95, 209, 166, 0.12);
}

input::placeholder,
textarea::placeholder,
.form-control::placeholder {
	color: rgba(255, 255, 255, 0.28);
	opacity: 1;
}

input:-ms-input-placeholder,
textarea:-ms-input-placeholder {
	color: rgba(255, 255, 255, 0.28);
}

input::-ms-input-placeholder,
textarea::-ms-input-placeholder {
	color: rgba(255, 255, 255, 0.28);
}

input::-webkit-input-placeholder,
textarea::-webkit-input-placeholder {
	color: rgba(255, 255, 255, 0.28);
}

footer {
	color: rgba(255, 255, 255, 0.65);
}

.group-actions {
	display: flex;
	flex-direction: row;
	justify-content: flex-end;
	margin-bottom: 0.5em;
}

@media (max-width: 600px) {
	.steam-line {
		flex-direction: column;
		align-items: stretch;
		gap: 8px;
	}

	.avatar-thumb {
		width: 50px;
		height: 50px;
	}

	.group-actions {
		flex-direction: column !important;
		justify-content: flex-end;
		gap: 8px;
	}

	.group-actions .btn {
		width: 100% !important;
	}

	.steam-line .avatar-thumb {
		align-self: flex-start;
	}

	.steam-line input.form-control,
	.steam-line textarea,
	.steam-line select {
		min-width: 0;
		width: 100%;
		flex: 0 0 auto;
		min-height: 40px;
		max-height: 140px;
		resize: vertical;
	}

	.steam-line textarea {
		min-height: 60px;
	}

	.showcolors-input {
		width: auto;
	}

	.steam-line .btn,
	.steam-line .remove-btn {
		align-self: flex-end;
		padding: 6px 8px;
		font-size: 13px;
	}

	.steam-line .remove-btn {
		width: 36px;
		height: 36px;
		padding: 0;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		border-radius: 8px;
	}

	.group-card .btn,
	#addGroupBtn,
	#exportInEditBtn {
		padding: 6px 10px;
		font-size: 13px;
	}
}