.autodgn-shell {
	max-width: 720px;
	margin: 24px auto;
	padding: 28px;
	color: #f8fafc;
	background: #111318;
	border: 1px solid #2b3039;
	border-radius: 8px;
	box-shadow: 0 16px 40px rgba(15, 23, 42, 0.22);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.autodgn-header {
	text-align: center;
	margin-bottom: 24px;
}

.autodgn-header h2,
.autodgn-result h3 {
	margin: 0 0 8px;
	color: #ffffff;
	font-size: 24px;
	line-height: 1.25;
	letter-spacing: 0;
}

.autodgn-header p {
	margin: 0;
	color: #b8c0cc;
	font-size: 15px;
	line-height: 1.5;
}

.autodgn-form {
	display: grid;
	gap: 16px;
}

.autodgn-dropzone {
	position: relative;
	display: grid;
	place-items: center;
	min-height: 170px;
	padding: 28px 18px;
	text-align: center;
	background: #181c23;
	border: 2px dashed #475163;
	border-radius: 8px;
	cursor: pointer;
	transition: background-color 0.16s ease, border-color 0.16s ease;
}

.autodgn-dropzone.is-active,
.autodgn-dropzone:focus {
	background: #202633;
	border-color: #4f8cff;
	outline: none;
}

.autodgn-upload-icon {
	width: 42px;
	height: 42px;
	margin-bottom: 12px;
	border-radius: 50%;
	border: 2px solid #4f8cff;
	display: inline-block;
	position: relative;
}

.autodgn-upload-icon::before,
.autodgn-upload-icon::after {
	content: "";
	position: absolute;
	left: 50%;
	background: #4f8cff;
	transform: translateX(-50%);
}

.autodgn-upload-icon::before {
	top: 10px;
	width: 2px;
	height: 18px;
}

.autodgn-upload-icon::after {
	top: 10px;
	width: 12px;
	height: 12px;
	border-top: 2px solid #4f8cff;
	border-left: 2px solid #4f8cff;
	background: transparent;
	transform: translateX(-50%) rotate(45deg);
}

.autodgn-file-input {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	cursor: pointer;
}

.autodgn-file-label,
.autodgn-label {
	color: #e5e9f0;
	font-size: 15px;
	font-weight: 600;
}

.autodgn-prompt {
	width: 100%;
	min-height: 120px;
	box-sizing: border-box;
	padding: 12px 14px;
	color: #ffffff;
	background: #181c23;
	border: 1px solid #475163;
	border-radius: 8px;
	font-size: 15px;
	line-height: 1.45;
	resize: vertical;
}

.autodgn-prompt:focus {
	border-color: #4f8cff;
	outline: none;
	box-shadow: 0 0 0 2px rgba(79, 140, 255, 0.18);
}

.autodgn-analyze,
.autodgn-submit,
.autodgn-download {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 46px;
	padding: 12px 18px;
	color: #ffffff;
	background: #2563eb;
	border: 0;
	border-radius: 8px;
	font-size: 16px;
	font-weight: 700;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.16s ease, transform 0.16s ease;
}

.autodgn-analyze {
	background: #334155;
}

.autodgn-submit:hover,
.autodgn-analyze:hover,
.autodgn-download:hover {
	background: #1d4ed8;
	color: #ffffff;
}

.autodgn-analyze:disabled,
.autodgn-submit:disabled {
	cursor: wait;
	opacity: 0.72;
}

.autodgn-suggestions {
	display: grid;
	gap: 14px;
	padding: 16px;
	background: #171b22;
	border: 1px solid #2f3744;
	border-radius: 8px;
}

.autodgn-suggestions-head h3 {
	margin: 0 0 4px;
	color: #ffffff;
	font-size: 17px;
	line-height: 1.3;
}

.autodgn-suggestions-head p {
	margin: 0;
	color: #b8c0cc;
	font-size: 14px;
	line-height: 1.45;
}

.autodgn-options {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 10px;
}

.autodgn-option {
	display: grid;
	grid-template-columns: 22px minmax(0, 1fr);
	gap: 10px;
	align-items: flex-start;
	padding: 12px;
	background: #111821;
	border: 1px solid #354153;
	border-radius: 8px;
	cursor: pointer;
}

.autodgn-option:hover {
	border-color: #4f8cff;
}

.autodgn-option input {
	width: 18px;
	height: 18px;
	margin: 2px 0 0;
	accent-color: #2563eb;
}

.autodgn-option-body {
	display: grid;
	gap: 4px;
	min-width: 0;
}

.autodgn-option-body strong {
	color: #ffffff;
	font-size: 14px;
	line-height: 1.25;
}

.autodgn-option-meta,
.autodgn-option-description {
	color: #a9b4c4;
	font-size: 12px;
	line-height: 1.35;
}

.autodgn-option-meta {
	color: #93b5ff;
	font-weight: 700;
}

.autodgn-mode-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
}

.autodgn-mode-panel {
	display: grid;
	gap: 10px;
	padding: 14px;
	background: #171b22;
	border: 1px solid #2f3744;
	border-radius: 8px;
}

.autodgn-radio {
	display: grid;
	grid-template-columns: 20px minmax(0, 1fr);
	gap: 10px;
	align-items: flex-start;
	padding: 10px;
	background: #111821;
	border: 1px solid #354153;
	border-radius: 8px;
	cursor: pointer;
}

.autodgn-radio:hover {
	border-color: #4f8cff;
}

.autodgn-radio input {
	width: 16px;
	height: 16px;
	margin: 2px 0 0;
	accent-color: #2563eb;
}

.autodgn-radio strong,
.autodgn-radio small {
	display: block;
	line-height: 1.35;
}

.autodgn-radio strong {
	color: #ffffff;
	font-size: 14px;
}

.autodgn-radio small {
	color: #a9b4c4;
	font-size: 12px;
}

.autodgn-status {
	margin: -4px 0 0;
	color: #b8c0cc;
	font-size: 14px;
	line-height: 1.4;
	text-align: center;
}

.autodgn-status.is-working {
	color: #93b5ff;
	font-weight: 700;
}

.autodgn-status.is-error {
	color: #fecaca;
	font-weight: 700;
}

.autodgn-status.is-success {
	color: #bbf7d0;
	font-weight: 700;
}

.autodgn-loading {
	padding: 26px 0 10px;
	text-align: center;
}

.autodgn-loading p {
	margin: 12px 0 0;
	color: #93b5ff;
	font-weight: 600;
}

.autodgn-spinner {
	display: inline-block;
	width: 42px;
	height: 42px;
	border: 4px solid rgba(255, 255, 255, 0.12);
	border-left-color: #4f8cff;
	border-radius: 50%;
	animation: autodgn-spin 1s linear infinite;
}

.autodgn-message,
.autodgn-error {
	margin: 16px auto;
	padding: 14px 16px;
	color: #7f1d1d;
	background: #fef2f2;
	border: 1px solid #fecaca;
	border-radius: 8px;
	font-weight: 600;
}

.autodgn-result {
	margin-top: 26px;
	padding-top: 24px;
	text-align: center;
	border-top: 1px solid #2b3039;
}

.autodgn-result img {
	display: block;
	width: 100%;
	height: auto;
	margin: 0 0 16px;
	border-radius: 8px;
	box-shadow: 0 12px 30px rgba(0, 0, 0, 0.36);
}

.autodgn-result-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	justify-content: center;
}

.autodgn-download {
	background: #16a34a;
	font-size: 15px;
}

.autodgn-download:hover {
	background: #15803d;
}

.autodgn-secondary {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 42px;
	padding: 10px 14px;
	color: #ffffff;
	background: #334155;
	border: 0;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 700;
	cursor: pointer;
}

.autodgn-secondary:hover {
	background: #475569;
}

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

@media (max-width: 640px) {
	.autodgn-shell {
		margin: 16px 0;
		padding: 20px;
	}

	.autodgn-header h2 {
		font-size: 21px;
	}

	.autodgn-options {
		grid-template-columns: 1fr;
	}

	.autodgn-mode-grid {
		grid-template-columns: 1fr;
	}
}
