.kfc {
	--kfc-bg: #111111;
	--kfc-panel: #1a1a1a;
	--kfc-border: #2c2c2c;
	--kfc-text: #f2f2f2;
	--kfc-text-soft: #9a9a9a;
	--kfc-accent: #d0d0d0;

	font-family:
		Inter,
		system-ui,
		sans-serif;

	color: var(--kfc-text);

	max-width: 1400px;

	margin: 0 auto;

	padding: 32px;
}

.kfc * {
	box-sizing: border-box;
}

.kfc-header {
	margin-bottom: 32px;
}

.kfc-header h2 {
	margin: 0 0 6px 0;

	font-size: 28px;
	font-weight: 600;
	letter-spacing: -0.03em;
}

.kfc-header p {
	margin: 0;

	color: var(--kfc-text-soft);

	font-size: 14px;
}

.kfc-layout {
	display: grid;

	grid-template-columns:
		minmax(320px, 1fr)
		minmax(320px, 420px);

	gap: 24px;
}

.kfc-panel {
	display: flex;
	flex-direction: column;
	gap: 24px;
}

.kfc-section,
.kfc-results {
	background: var(--kfc-panel);

	border: 1px solid var(--kfc-border);

	border-radius: 12px;

	padding: 20px;
}

.kfc-section-title {
	margin: 0 0 20px 0;

	font-size: 13px;
	font-weight: 600;

	text-transform: uppercase;

	letter-spacing: 0.08em;

	color: var(--kfc-text-soft);
}

.kfc-field {
	display: flex;
	flex-direction: column;

	gap: 8px;

	margin-bottom: 20px;
}

.kfc-field:last-child {
	margin-bottom: 0;
}

.kfc-field label {
	font-size: 13px;

	color: var(--kfc-text-soft);
}

.kfc select,
.kfc input {
	width: 100%;

	background: #0d0d0d;

	border: 1px solid var(--kfc-border);

	color: var(--kfc-text);

	border-radius: 8px;

	padding: 12px 14px;

	font-size: 14px;

	outline: none;

	transition:
		border-color 0.15s ease,
		background 0.15s ease;
}

.kfc select:focus,
.kfc input:focus {
	border-color: #666666;

	background: #141414;
}

.kfc-input-unit {
	position: relative;
}

.kfc-input-unit span {
	position: absolute;

	top: 50%;
	right: 14px;

	transform: translateY(-50%);

	font-size: 12px;

	color: var(--kfc-text-soft);

	pointer-events: none;
}

.kfc-input-unit input {
	padding-right: 42px;
}

.kfc-radio-group {
	display: flex;
	flex-wrap: wrap;

	gap: 10px;
}

.kfc-radio {
	position: relative;

	cursor: pointer;
}

.kfc-radio input {
	position: absolute;

	opacity: 0;

	pointer-events: none;
}

.kfc-radio span {
	display: flex;
	align-items: center;
	justify-content: center;

	min-width: 110px;

	padding: 12px 16px;

	border-radius: 8px;

	border: 1px solid var(--kfc-border);

	background: #0d0d0d;

	font-size: 13px;

	transition:
		border-color 0.15s ease,
		background 0.15s ease;
}

.kfc-radio input:checked + span {
	border-color: #7a7a7a;

	background: #202020;
}

.kfc-timecode {
	display: flex;
	align-items: center;

	gap: 8px;
}

.kfc-timecode span {
	color: var(--kfc-text-soft);

	font-size: 18px;
}

.kfc-tc {
	text-align: center;

	font-family:
		ui-monospace,
		SFMono-Regular,
		Menlo,
		monospace;
	appearance: textfield;
	-moz-appearance: textfield;
}

.kfc-tc::-webkit-outer-spin-button,
.kfc-tc::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.kfc-checkbox {
	display: flex;
	align-items: center;
	gap: 10px;
	cursor: pointer;
	font-size: 13px;
	color: var(--kfc-text-soft);
}

.kfc-checkbox input {
	width: auto;
	margin: 0;
}

.kfc-results {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.kfc-result {
	display: flex;
	align-items: center;
	justify-content: space-between;

	padding-bottom: 14px;

	border-bottom: 1px solid var(--kfc-border);
}

.kfc-result:last-child {
	padding-bottom: 0;
	border-bottom: 0;
}

.kfc-result span {
	font-size: 13px;

	color: var(--kfc-text-soft);
}

.kfc-result strong {
	font-size: 15px;
	font-weight: 600;

	font-family:
		ui-monospace,
		SFMono-Regular,
		Menlo,
		monospace;
}

.kfc-reels {
	display: flex;
	flex-direction: column;

	gap: 12px;
}

.kfc-reel {
	display: flex;
	align-items: center;
	justify-content: space-between;

	padding: 12px 14px;

	border-radius: 8px;

	background: #0d0d0d;

	border: 1px solid var(--kfc-border);
}

.kfc-reel strong {
	font-size: 14px;
}

.kfc-reel span {
	font-size: 13px;

	color: var(--kfc-text-soft);
}

.kfc-section details {
	width: 100%;
}

.kfc-section summary {
	list-style: none;

	cursor: pointer;
}

.kfc-section summary::-webkit-details-marker {
	display: none;
}

.kfc-svg-preview {
	width: 100%;

	padding: 12px;

	border-radius: 10px;

	background: #0d0d0d;

	border: 1px solid var(--kfc-border);
}

#kfc-format-preview {
	width: 100%;
	height: auto;

	display: block;
}

.kfc details[open] summary {
	margin-bottom: 20px;
}

/*
|--------------------------------------------------------------------------
| SVG Preview
|--------------------------------------------------------------------------
*/

.kfc-preview {
	margin-top: 24px;
}

.kfc-preview-container {
	display: flex;
	justify-content: center;
	align-items: center;

	padding: 20px;

	border: 1px solid var(--kfc-border);
	border-radius: 12px;

	background: rgba(255,255,255,0.02);
}

.kfc-preview-svg {
	width: 100%;
	max-width: 240px;
	height: auto;
}

/*
|--------------------------------------------------------------------------
| Film body
|--------------------------------------------------------------------------
*/

.kfc-film-base {
	fill: #1a1a1a;
	stroke: #444;
	stroke-width: 1;
}

/*
|--------------------------------------------------------------------------
| Perforations
|--------------------------------------------------------------------------
*/

.kfc-preview-svg rect {
	vector-effect: non-scaling-stroke;
}

.kfc-preview-svg rect:not(.kfc-film-base):not(.kfc-image-frame):not(.kfc-overscan-frame) {
	fill: #d8d8d8;
}

/*
|--------------------------------------------------------------------------
| Image area
|--------------------------------------------------------------------------
*/

.kfc-image-frame {
	fill: rgba(255,255,255,0.08);

	stroke: #ffffff;
	stroke-width: 1.5;
}

/*
|--------------------------------------------------------------------------
| Overscan
|--------------------------------------------------------------------------
*/

.kfc-overscan-frame {
	fill: rgba(255,255,255,0.03);

	stroke: rgba(255,255,255,0.35);
	stroke-width: 1;

	stroke-dasharray: 2 2;
}

/*
|--------------------------------------------------------------------------
| Labels
|--------------------------------------------------------------------------
*/

.kfc-preview-label {
	fill: rgba(255,255,255,0.75);

	font-size: 5px;
	font-family: sans-serif;
}

@media (max-width: 960px) {

	.kfc {
		padding: 20px;
	}

	.kfc-layout {
		grid-template-columns: 1fr;
	}
}