.sgc-app,
.sgc-app * {
	box-sizing: border-box;
}

.sgc-app {
	--sgc-blue: #086ad8;
	--sgc-blue-dark: #064ea1;
	--sgc-ink: #10243e;
	--sgc-muted: #607086;
	--sgc-line: #dce5ef;
	--sgc-surface: #f5f8fc;
	--sgc-orange: #d96b16;
	position: relative;
	overflow: hidden;
	width: 100%;
	margin: 24px auto;
	border: 1px solid var(--sgc-line);
	border-radius: 20px;
	background: #fff;
	box-shadow: 0 18px 55px rgba(27, 63, 102, .10);
	color: var(--sgc-ink);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.sgc-hero {
	position: relative;
	padding: 52px 56px 38px;
	background:
		radial-gradient(circle at 88% 14%, rgba(55, 178, 255, .22), transparent 26%),
		linear-gradient(135deg, #061f3f 0%, #073f78 58%, #0759a7 100%);
	color: #fff;
}

.sgc-hero::after {
	content: "";
	position: absolute;
	right: -62px;
	bottom: -104px;
	width: 300px;
	height: 300px;
	border: 52px solid rgba(255, 255, 255, .055);
	border-radius: 50%;
}

.sgc-eyebrow,
.sgc-result-kicker {
	font-size: 12px;
	font-weight: 750;
	letter-spacing: .12em;
	text-transform: uppercase;
}

.sgc-eyebrow {
	color: #7fd1ff;
}

.sgc-hero h1 {
	position: relative;
	z-index: 1;
	margin: 8px 0 10px;
	color: #fff;
	font-size: clamp(31px, 4vw, 46px);
	font-weight: 750;
	letter-spacing: -.035em;
	line-height: 1.08;
}

.sgc-hero p {
	position: relative;
	z-index: 1;
	max-width: 720px;
	margin: 0;
	color: rgba(255, 255, 255, .82);
	font-size: 16px;
	line-height: 1.65;
}

.sgc-search-form {
	position: relative;
	z-index: 2;
	margin: -1px 40px 0;
	padding: 28px 16px 20px;
	background: #fff;
}

.sgc-mode-switch {
	display: inline-flex;
	margin: 0 0 16px;
	padding: 4px;
	border: 1px solid var(--sgc-line);
	border-radius: 10px;
	background: var(--sgc-surface);
}

.sgc-mode-switch label {
	cursor: pointer;
	margin: 0;
}

.sgc-mode-switch input {
	position: absolute;
	opacity: 0;
	pointer-events: none;
}

.sgc-mode-switch span {
	display: block;
	min-width: 126px;
	padding: 9px 16px;
	border-radius: 7px;
	color: var(--sgc-muted);
	font-size: 14px;
	font-weight: 650;
	text-align: center;
	transition: .18s ease;
}

.sgc-mode-switch input:checked + span {
	background: #fff;
	box-shadow: 0 2px 8px rgba(40, 70, 105, .12);
	color: var(--sgc-blue);
}

.sgc-mode-switch input:focus-visible + span {
	outline: 2px solid var(--sgc-blue);
	outline-offset: 2px;
}

.sgc-search-row {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	gap: 10px;
}

.sgc-input-wrap {
	position: relative;
}

.sgc-input-wrap svg {
	position: absolute;
	top: 50%;
	left: 18px;
	width: 22px;
	height: 22px;
	transform: translateY(-50%);
	fill: none;
	stroke: #7c8da2;
	stroke-linecap: round;
	stroke-width: 1.8;
}

.sgc-input-wrap input {
	width: 100%;
	height: 58px;
	margin: 0;
	padding: 0 18px 0 54px;
	border: 1px solid #aebdcd;
	border-radius: 11px;
	background: #fff;
	box-shadow: none;
	color: var(--sgc-ink);
	font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
	font-size: 18px;
	font-weight: 650;
	letter-spacing: .02em;
	text-transform: uppercase;
}

.sgc-input-wrap input:focus {
	border-color: var(--sgc-blue);
	box-shadow: 0 0 0 3px rgba(8, 106, 216, .14);
	outline: none;
}

.sgc-search-row > button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-width: 126px;
	height: 58px;
	margin: 0;
	padding: 0 24px;
	border: 0;
	border-radius: 11px;
	background: linear-gradient(135deg, var(--sgc-blue), #0a7bef);
	box-shadow: 0 8px 18px rgba(8, 106, 216, .22);
	color: #fff;
	cursor: pointer;
	font-size: 16px;
	font-weight: 700;
	transition: transform .15s ease, box-shadow .15s ease, opacity .15s ease;
}

.sgc-search-row > button:hover {
	transform: translateY(-1px);
	box-shadow: 0 10px 22px rgba(8, 106, 216, .30);
}

.sgc-search-row > button:disabled {
	cursor: wait;
	opacity: .68;
}

.sgc-search-row > button svg {
	width: 20px;
	height: 20px;
	fill: none;
	stroke: currentColor;
	stroke-linecap: round;
	stroke-linejoin: round;
	stroke-width: 2;
}

.sgc-search-row > button.is-loading svg {
	animation: sgc-pulse .75s alternate infinite;
}

.sgc-form-hint {
	margin: 9px 0 0;
	color: var(--sgc-muted);
	font-size: 12px;
}

.sgc-search-status {
	margin: 0 56px;
	padding: 0;
	color: var(--sgc-muted);
	font-weight: 600;
}

.sgc-search-status.is-working,
.sgc-search-status.is-error {
	margin-bottom: 24px;
	padding: 13px 16px;
	border-radius: 8px;
}

.sgc-search-status.is-working {
	background: #edf6ff;
	color: var(--sgc-blue-dark);
}

.sgc-search-status.is-error {
	background: #fff0f0;
	color: #a62222;
}

.sgc-results {
	scroll-margin-top: 28px;
	padding: 0 56px;
}

.sgc-result-summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	margin-top: 8px;
	padding-top: 28px;
	border-top: 1px solid var(--sgc-line);
}

.sgc-result-kicker {
	color: var(--sgc-blue);
}

.sgc-result-summary h2 {
	margin: 5px 0 0;
	color: var(--sgc-ink);
	font-size: clamp(22px, 3vw, 30px);
	letter-spacing: -.025em;
	line-height: 1.25;
}

.sgc-result-counts {
	display: flex;
	flex-shrink: 0;
	gap: 8px;
}

.sgc-result-counts span {
	min-width: 78px;
	padding: 10px 13px;
	border-radius: 9px;
	background: var(--sgc-surface);
	color: var(--sgc-muted);
	font-size: 12px;
	text-align: center;
}

.sgc-result-counts strong {
	display: block;
	color: var(--sgc-ink);
	font-size: 20px;
	line-height: 1.1;
}

.sgc-resolution-path {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr);
	align-items: center;
	gap: 10px;
	margin: 24px 0 14px;
}

.sgc-resolution-path > i {
	color: #91a2b6;
	font-style: normal;
	font-size: 22px;
}

.sgc-path-card {
	min-width: 0;
	padding: 14px 16px;
	border: 1px solid var(--sgc-line);
	border-radius: 10px;
	background: #fff;
}

.sgc-path-card span,
.sgc-path-card small {
	display: block;
	color: var(--sgc-muted);
	font-size: 11px;
}

.sgc-path-card strong {
	display: block;
	overflow: hidden;
	margin: 3px 0;
	color: var(--sgc-ink);
	font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
	font-size: 15px;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.sgc-path-package {
	border-color: #add2f9;
	background: #f1f8ff;
}

.sgc-candidate-notice {
	margin: 0 0 24px;
	padding: 12px 14px;
	border-left: 4px solid #e2a72b;
	border-radius: 4px 8px 8px 4px;
	background: #fff9e8;
	color: #6d5519;
	font-size: 13px;
	line-height: 1.5;
}

.sgc-object-group {
	overflow: hidden;
	margin: 0 0 22px;
	border: 1px solid var(--sgc-line);
	border-radius: 12px;
	background: #fff;
}

.sgc-object-group > header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	padding: 15px 18px;
	border-bottom: 1px solid var(--sgc-line);
	background: #f8fafc;
}

.sgc-object-group > header > div {
	display: flex;
	align-items: center;
	gap: 10px;
}

.sgc-object-group h3 {
	margin: 0;
	color: var(--sgc-ink);
	font-size: 16px;
}

.sgc-type-dot {
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: var(--sgc-blue);
	box-shadow: 0 0 0 4px rgba(8, 106, 216, .12);
}

.sgc-type-sxsd .sgc-type-dot {
	background: var(--sgc-orange);
	box-shadow: 0 0 0 4px rgba(217, 107, 22, .13);
}

.sgc-group-count {
	padding: 5px 9px;
	border-radius: 999px;
	background: #e9f3fe;
	color: var(--sgc-blue-dark);
	font-size: 11px;
	font-weight: 700;
}

.sgc-type-sxsd .sgc-group-count {
	background: #fff0e5;
	color: #a34a0a;
}

.sgc-object-table-wrap {
	overflow-x: auto;
}

.sgc-object-table {
	width: 100%;
	margin: 0;
	border: 0;
	border-collapse: collapse;
	background: #fff;
	font-size: 13px;
}

.sgc-object-table th,
.sgc-object-table td {
	padding: 13px 16px;
	border: 0;
	border-bottom: 1px solid #edf1f5;
	background: transparent;
	color: var(--sgc-ink);
	text-align: left;
	vertical-align: middle;
}

.sgc-object-table th {
	color: var(--sgc-muted);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .04em;
	text-transform: uppercase;
}

.sgc-object-table tr:last-child td {
	border-bottom: 0;
}

.sgc-object-table tbody tr:hover {
	background: #f8fbff;
}

.sgc-object-table code {
	padding: 4px 7px;
	border-radius: 5px;
	background: #edf4fb;
	color: #064e96;
	font-size: 12px;
	font-weight: 700;
	white-space: nowrap;
}

.sgc-gui-code {
	display: inline-block;
	min-width: 44px;
	font-weight: 750;
}

.sgc-object-table td small {
	display: block;
	color: var(--sgc-muted);
	font-size: 10px;
	white-space: nowrap;
}

.sgc-copy-button {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin: 0;
	padding: 7px 10px;
	border: 1px solid #b8c8d9;
	border-radius: 7px;
	background: #fff;
	color: var(--sgc-blue-dark);
	cursor: pointer;
	font-size: 11px;
	font-weight: 700;
	white-space: nowrap;
}

.sgc-copy-button:hover,
.sgc-copy-button.is-copied {
	border-color: var(--sgc-blue);
	background: #eef7ff;
}

.sgc-copy-button svg {
	width: 15px;
	height: 15px;
	fill: none;
	stroke: currentColor;
	stroke-linecap: round;
	stroke-linejoin: round;
	stroke-width: 1.7;
}

.sgc-no-objects {
	margin-bottom: 25px;
	padding: 30px;
	border: 1px dashed #b8c8d9;
	border-radius: 12px;
	background: var(--sgc-surface);
	text-align: center;
}

.sgc-no-objects h3 {
	margin: 0 0 5px;
	color: var(--sgc-ink);
}

.sgc-no-objects p {
	margin: 0;
	color: var(--sgc-muted);
}

.sgc-disclaimer {
	margin: 38px 0 0;
	padding: 17px 24px 22px;
	border-top: 1px solid var(--sgc-line);
	background: var(--sgc-surface);
	color: #718096;
	font-size: 10px;
	line-height: 1.55;
	text-align: center;
}

.sgc-empty-state {
	padding: 22px;
	border: 1px solid #dce5ef;
	border-radius: 10px;
	background: #f5f8fc;
	color: #40546b;
}

@keyframes sgc-pulse {
	from { transform: translateX(-2px); }
	to { transform: translateX(3px); }
}

@media (max-width: 760px) {
	.sgc-app {
		border-radius: 14px;
	}

	.sgc-hero {
		padding: 38px 24px 30px;
	}

	.sgc-search-form {
		margin: 0;
		padding: 24px;
	}

	.sgc-mode-switch {
		display: flex;
	}

	.sgc-mode-switch label,
	.sgc-mode-switch span {
		width: 100%;
	}

	.sgc-mode-switch span {
		min-width: 0;
	}

	.sgc-search-row {
		grid-template-columns: 1fr;
	}

	.sgc-search-row > button {
		width: 100%;
	}

	.sgc-search-status,
	.sgc-results {
		margin-right: 24px;
		margin-left: 24px;
		padding-right: 0;
		padding-left: 0;
	}

	.sgc-result-summary {
		align-items: flex-start;
		flex-direction: column;
	}

	.sgc-resolution-path {
		grid-template-columns: 1fr;
	}

	.sgc-resolution-path > i {
		transform: rotate(90deg);
		text-align: center;
	}

}

@media (max-width: 480px) {
	.sgc-result-counts {
		width: 100%;
	}

	.sgc-result-counts span {
		flex: 1;
	}

	.sgc-object-table th,
	.sgc-object-table td {
		padding: 11px 12px;
	}
}
