/**
 * Gerador de Fontes: front-end styles.
 * Every selector is scoped to .gdf-app so the theme cannot break the tool
 * and the tool cannot leak into the theme.
 */

.gdf-app {
	--gdf-accent: #c8177a;
	--gdf-on-accent: #ffffff;
	--gdf-accent-soft: rgba(200, 23, 122, 0.1);
	--gdf-bg: #f3f4f8;
	--gdf-surface: #ffffff;
	--gdf-ink: #161827;
	--gdf-muted: #555a72;
	--gdf-line: #dfe1eb;
	--gdf-hover: #f7f8fb;
	--gdf-ok: #187a4d;
	--gdf-mid: #a65b00;
	--gdf-low: #c42b2b;
	--gdf-shadow: 0 1px 2px rgba(22, 24, 39, 0.06), 0 10px 28px -14px rgba(22, 24, 39, 0.22);
	--gdf-sample-size: 24px;
	--gdf-sticky-top: 0px;
	--gdf-pad: clamp(14px, 3.5vw, 36px);

	position: relative;
	box-sizing: border-box;
	width: 100%;
	max-width: 100%;
	margin: 0 auto 1.5em;
	padding: var(--gdf-pad);
	border-radius: 24px;
	background: var(--gdf-bg);
	color: var(--gdf-ink);
	font-family: inherit;
	font-size: 16px;
	line-height: 1.5;
	text-align: left;
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
}

@supports (color: color-mix(in srgb, red 10%, transparent)) {
	.gdf-app {
		--gdf-accent-soft: color-mix(in srgb, var(--gdf-accent) 11%, transparent);
	}
}

.gdf-app.gdf-theme-dark {
	--gdf-bg: #11121b;
	--gdf-surface: #1a1c28;
	--gdf-ink: #eef0f7;
	--gdf-muted: #a6abc4;
	--gdf-line: #2c2f42;
	--gdf-hover: #222536;
	--gdf-ok: #4cc38a;
	--gdf-mid: #f0a640;
	--gdf-low: #ff8079;
	--gdf-shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 30px -16px rgba(0, 0, 0, 0.75);
	color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
	.gdf-app.gdf-theme-auto {
		--gdf-bg: #11121b;
		--gdf-surface: #1a1c28;
		--gdf-ink: #eef0f7;
		--gdf-muted: #a6abc4;
		--gdf-line: #2c2f42;
		--gdf-hover: #222536;
		--gdf-ok: #4cc38a;
		--gdf-mid: #f0a640;
		--gdf-low: #ff8079;
		--gdf-shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 30px -16px rgba(0, 0, 0, 0.75);
		color-scheme: dark;
	}
}

.gdf-app *,
.gdf-app *::before,
.gdf-app *::after {
	box-sizing: border-box;
}

.gdf-app [hidden] {
	display: none !important;
}

.gdf-app .gdf-sr {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

/* Neutralise common theme styles on form controls inside the tool. */
.gdf-app button,
.gdf-app input,
.gdf-app select,
.gdf-app textarea {
	margin: 0;
	font-family: inherit;
	letter-spacing: normal;
	text-transform: none;
	text-shadow: none;
	box-shadow: none;
}

.gdf-app button {
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	-webkit-tap-highlight-color: transparent;
}

.gdf-app button:focus-visible,
.gdf-app input:focus-visible,
.gdf-app select:focus-visible {
	outline: 3px solid var(--gdf-accent);
	outline-offset: 2px;
}

.gdf-app .gdf-ico {
	display: block;
	flex: none;
	width: 18px;
	height: 18px;
}

/* ---------- Header ---------- */

.gdf-app .gdf-head {
	margin: 0 0 18px;
}

.gdf-app .gdf-title {
	margin: 0 0 6px;
	padding: 0;
	border: 0;
	color: var(--gdf-ink);
	font-family: inherit;
	font-size: clamp(26px, 4.4vw, 40px);
	font-weight: 800;
	line-height: 1.1;
	letter-spacing: -0.02em;
}

.gdf-app .gdf-title::before,
.gdf-app .gdf-title::after {
	content: none;
}

.gdf-app .gdf-sub {
	max-width: 62ch;
	margin: 0;
	color: var(--gdf-muted);
	font-size: 16px;
}

/* ---------- Text box ---------- */

.gdf-app .gdf-compose {
	position: relative;
	z-index: 3;
	padding: 14px 18px 10px;
	border: 1.5px solid var(--gdf-line);
	border-radius: 20px;
	background: var(--gdf-surface);
	box-shadow: var(--gdf-shadow);
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.gdf-app.gdf-is-sticky .gdf-compose {
	position: -webkit-sticky;
	position: sticky;
	top: var(--gdf-sticky-top);
}

.gdf-app .gdf-compose:focus-within {
	border-color: var(--gdf-accent);
	box-shadow: 0 0 0 4px var(--gdf-accent-soft), var(--gdf-shadow);
}

.gdf-app .gdf-label {
	display: block;
	margin: 0 0 2px;
	color: var(--gdf-muted);
	font-size: 14px;
	font-weight: 600;
}

.gdf-app .gdf-input {
	display: block;
	width: 100%;
	min-height: 2.7em;
	max-height: 40vh;
	padding: 4px 0;
	border: 0;
	border-radius: 0;
	outline: none;
	background: transparent;
	color: var(--gdf-ink);
	font-size: clamp(21px, 3.6vw, 32px);
	font-weight: 500;
	line-height: 1.3;
	resize: vertical;
}

.gdf-app .gdf-input::placeholder {
	color: var(--gdf-muted);
	opacity: 0.75;
}

.gdf-app .gdf-compose-bar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 12px;
	margin-top: 8px;
	padding-top: 8px;
	border-top: 1px solid var(--gdf-line);
}

.gdf-app .gdf-count {
	color: var(--gdf-muted);
	font-size: 13px;
	font-variant-numeric: tabular-nums;
}

.gdf-app .gdf-count.gdf-is-max {
	color: var(--gdf-low);
	font-weight: 700;
}

.gdf-app .gdf-compose-actions {
	display: flex;
	gap: 6px;
}

/* ---------- Buttons ---------- */

.gdf-app .gdf-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 44px;
	padding: 10px 18px;
	border: 1px solid var(--gdf-line);
	border-radius: 999px;
	background: var(--gdf-surface);
	color: var(--gdf-ink);
	font-size: 15px;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.1s ease;
}

.gdf-app .gdf-btn:hover {
	border-color: var(--gdf-ink);
	background: var(--gdf-surface);
	color: var(--gdf-ink);
}

.gdf-app .gdf-btn:active {
	transform: scale(0.98);
}

.gdf-app .gdf-btn:disabled {
	opacity: 0.5;
	cursor: not-allowed;
	transform: none;
}

.gdf-app .gdf-btn-quiet {
	padding: 8px 14px;
	border-color: transparent;
	background: transparent;
	color: var(--gdf-muted);
}

.gdf-app .gdf-btn-quiet:hover {
	border-color: var(--gdf-line);
	background: var(--gdf-hover);
	color: var(--gdf-ink);
}

.gdf-app .gdf-btn-primary,
.gdf-app .gdf-btn-primary:hover {
	border-color: var(--gdf-accent);
	background: var(--gdf-accent);
	color: var(--gdf-on-accent);
}

.gdf-app .gdf-btn-primary:hover {
	filter: brightness(1.07);
}

/* ---------- Category chips ---------- */

.gdf-app .gdf-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 20px 0 14px;
}

.gdf-app .gdf-chip {
	flex: 0 0 auto;
	min-height: 44px;
	padding: 9px 16px;
	border: 1px solid var(--gdf-line);
	border-radius: 999px;
	background: var(--gdf-surface);
	color: var(--gdf-ink);
	font-size: 15px;
	font-weight: 500;
	line-height: 1.2;
	white-space: nowrap;
	transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.gdf-app .gdf-chip:hover {
	border-color: var(--gdf-ink);
	background: var(--gdf-surface);
	color: var(--gdf-ink);
}

.gdf-app .gdf-chip[aria-pressed="true"],
.gdf-app .gdf-chip[aria-pressed="true"]:hover {
	border-color: var(--gdf-ink);
	background: var(--gdf-ink);
	color: var(--gdf-surface);
}

/* ---------- Tools row ---------- */

.gdf-app .gdf-tools {
	display: grid;
	grid-template-columns: minmax(180px, 260px) minmax(0, 1fr);
	align-items: start;
	gap: 12px 18px;
	margin: 0 0 16px;
}

.gdf-app .gdf-options {
	min-width: 0;
	margin: 0;
	padding: 0;
	border: 0;
}

.gdf-app .gdf-options-toggle {
	display: flex;
	align-items: center;
	gap: 8px;
	min-height: 44px;
	margin: 0;
	padding: 0 4px;
	color: var(--gdf-ink);
	font-size: 15px;
	font-weight: 600;
	list-style: none;
	cursor: pointer;
}

.gdf-app .gdf-options-toggle::-webkit-details-marker {
	display: none;
}

.gdf-app .gdf-options-toggle::before {
	content: "";
	flex: none;
	width: 8px;
	height: 8px;
	margin: 0 4px 0 2px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(-45deg);
	transition: transform 0.15s ease;
}

.gdf-app .gdf-options[open] > .gdf-options-toggle::before {
	transform: rotate(45deg);
}

.gdf-app .gdf-options-toggle:focus-visible {
	outline: 3px solid var(--gdf-accent);
	outline-offset: 2px;
	border-radius: 8px;
}

.gdf-app .gdf-options-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
	align-items: end;
	gap: 12px 14px;
	padding-top: 4px;
}

/* Wide screens: the options sit beside the search box and the summary is hidden. */
@media (min-width: 641px) {
	.gdf-app .gdf-tools {
		grid-template-columns: minmax(180px, 240px) minmax(0, 1fr);
		align-items: end;
	}

	.gdf-app .gdf-options[open] > .gdf-options-toggle {
		position: absolute;
		width: 1px;
		height: 1px;
		min-height: 0;
		overflow: hidden;
		clip: rect(0, 0, 0, 0);
		white-space: nowrap;
	}

	.gdf-app .gdf-options-grid {
		padding-top: 0;
	}
}

.gdf-app .gdf-field {
	min-width: 0;
}

.gdf-app .gdf-field > label {
	display: block;
	margin: 0 0 4px;
	color: var(--gdf-muted);
	font-size: 13px;
	font-weight: 600;
}

.gdf-app .gdf-field input[type="search"],
.gdf-app .gdf-field select {
	display: block;
	width: 100%;
	max-width: 100%;
	height: 44px;
	padding: 0 12px;
	border: 1px solid var(--gdf-line);
	border-radius: 12px;
	background-color: var(--gdf-surface);
	color: var(--gdf-ink);
	font-size: 15px;
	line-height: 1.2;
}

.gdf-app .gdf-field input[type="range"] {
	display: block;
	width: 100%;
	height: 44px;
	padding: 0;
	border: 0;
	background: transparent;
	accent-color: var(--gdf-accent);
}

.gdf-app .gdf-field > label.gdf-toggle,
.gdf-app .gdf-toggle {
	position: relative;
	display: flex;
	margin: 0;
	align-items: center;
	gap: 10px;
	min-height: 44px;
	color: var(--gdf-ink);
	font-size: 15px;
	font-weight: 500;
	cursor: pointer;
}

.gdf-app .gdf-toggle input {
	position: absolute;
	width: 1px;
	height: 1px;
	opacity: 0;
}

.gdf-app .gdf-toggle-ui {
	position: relative;
	flex: none;
	width: 44px;
	height: 26px;
	border-radius: 999px;
	background: var(--gdf-line);
	transition: background-color 0.15s ease;
}

.gdf-app .gdf-toggle-ui::after {
	content: "";
	position: absolute;
	top: 3px;
	left: 3px;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: #ffffff;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
	transition: transform 0.15s ease;
}

.gdf-app .gdf-toggle input:checked + .gdf-toggle-ui {
	background: var(--gdf-accent);
}

.gdf-app .gdf-toggle input:checked + .gdf-toggle-ui::after {
	transform: translateX(18px);
}

.gdf-app .gdf-toggle input:focus-visible + .gdf-toggle-ui {
	outline: 3px solid var(--gdf-accent);
	outline-offset: 2px;
}

/* ---------- Results ---------- */

.gdf-app .gdf-status {
	margin: 0 0 10px;
	color: var(--gdf-muted);
	font-size: 14px;
}

.gdf-app .gdf-list {
	margin: 0;
	padding: 0;
	overflow: hidden;
	border: 1px solid var(--gdf-line);
	border-radius: 18px;
	background: var(--gdf-surface);
	list-style: none;
}

.gdf-app .gdf-row {
	display: grid;
	grid-template-columns: minmax(120px, 190px) minmax(0, 1fr) auto;
	align-items: center;
	gap: 4px 16px;
	margin: 0;
	padding: 10px 12px 10px 18px;
	border-top: 1px solid var(--gdf-line);
	list-style: none;
	transition: background-color 0.2s ease;
}

.gdf-app .gdf-row::before,
.gdf-app .gdf-row::marker {
	content: none;
}

.gdf-app .gdf-row:first-child {
	border-top: 0;
}

.gdf-app .gdf-row:hover {
	background: var(--gdf-hover);
}

.gdf-app .gdf-row.gdf-is-copied {
	background: var(--gdf-accent-soft);
}

.gdf-app .gdf-row-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 8px;
	min-width: 0;
}

.gdf-app .gdf-row-name {
	color: var(--gdf-muted);
	font-size: 14px;
	font-weight: 600;
	line-height: 1.3;
}

.gdf-app .gdf-row-len {
	color: var(--gdf-muted);
	font-size: 12px;
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
}

.gdf-app .gdf-row-len.gdf-is-over {
	color: var(--gdf-low);
	font-weight: 700;
}

/* Compatibility signal: three bars, like phone reception. */
.gdf-app .gdf-compat {
	display: inline-flex;
	align-items: flex-end;
	gap: 2px;
	height: 12px;
}

.gdf-app .gdf-compat i {
	display: block;
	width: 3px;
	border-radius: 1px;
	background: var(--gdf-line);
}

.gdf-app .gdf-compat i:nth-child(1) { height: 5px; }
.gdf-app .gdf-compat i:nth-child(2) { height: 8px; }
.gdf-app .gdf-compat i:nth-child(3) { height: 12px; }
.gdf-app .gdf-compat-1 i { background: var(--gdf-ok); }
.gdf-app .gdf-compat-2 i:nth-child(-n+2) { background: var(--gdf-mid); }
.gdf-app .gdf-compat-3 i:nth-child(1) { background: var(--gdf-low); }

.gdf-app .gdf-sample {
	display: block;
	width: 100%;
	min-width: 0;
	min-height: 44px;
	padding: 6px 10px;
	border: 0;
	border-radius: 10px;
	background: transparent;
	color: var(--gdf-ink);
	font-family: system-ui, -apple-system, "Segoe UI", "Segoe UI Symbol", "Segoe UI Emoji", Roboto, "Noto Sans", "Noto Sans Symbols 2", "Noto Sans Math", "Cambria Math", "Apple Symbols", "Apple Color Emoji", sans-serif;
	font-size: var(--gdf-sample-size);
	font-weight: 400;
	line-height: 1.4;
	text-align: left;
	white-space: pre-wrap;
	overflow-wrap: anywhere;
	word-break: break-word;
	cursor: copy;
	transition: background-color 0.15s ease;
}

.gdf-app .gdf-sample:hover {
	background: var(--gdf-accent-soft);
	color: var(--gdf-ink);
}

.gdf-app.gdf-is-sample .gdf-sample {
	color: var(--gdf-muted);
}

.gdf-app .gdf-row-actions {
	display: flex;
	align-items: center;
	gap: 4px;
}

.gdf-app .gdf-icon-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--gdf-muted);
	transition: background-color 0.15s ease, color 0.15s ease;
}

.gdf-app .gdf-icon-btn:hover {
	background: var(--gdf-hover);
	color: var(--gdf-ink);
}

.gdf-app .gdf-fav[aria-pressed="true"],
.gdf-app .gdf-fav[aria-pressed="true"]:hover {
	color: var(--gdf-accent);
}

.gdf-app .gdf-copy {
	position: relative;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 44px;
	padding: 8px 15px;
	border: 1.5px solid var(--gdf-accent);
	border-radius: 999px;
	background: transparent;
	color: var(--gdf-ink);
	font-size: 14px;
	font-weight: 700;
	line-height: 1;
	white-space: nowrap;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.gdf-app .gdf-copy:hover,
.gdf-app .gdf-is-copied .gdf-copy {
	background: var(--gdf-accent);
	color: var(--gdf-on-accent);
}

.gdf-app .gdf-copy .gdf-ico-check,
.gdf-app .gdf-is-copied .gdf-copy .gdf-ico-copy {
	display: none;
}

.gdf-app .gdf-is-copied .gdf-copy .gdf-ico-check {
	display: block;
}

/* Loading skeleton: shown until the script is ready. */
.gdf-app .gdf-skeleton {
	display: none;
}

.gdf-app:not(.gdf-is-ready):not(.gdf-has-error) .gdf-skeleton {
	display: grid;
	gap: 10px;
}

.gdf-app:not(.gdf-is-ready) .gdf-list,
.gdf-app:not(.gdf-is-ready) .gdf-actions {
	display: none;
}

.gdf-app .gdf-skeleton span {
	display: block;
	height: 60px;
	border-radius: 14px;
	background: linear-gradient(90deg, var(--gdf-surface) 0%, var(--gdf-hover) 50%, var(--gdf-surface) 100%);
	background-size: 200% 100%;
	animation: gdf-shimmer 1.3s linear infinite;
}

@keyframes gdf-shimmer {
	from { background-position: 200% 0; }
	to { background-position: -200% 0; }
}

.gdf-app .gdf-empty {
	padding: 28px 20px;
	border: 1px dashed var(--gdf-line);
	border-radius: 18px;
	background: var(--gdf-surface);
	color: var(--gdf-muted);
	text-align: center;
}

.gdf-app .gdf-empty p {
	margin: 0 0 10px;
}

.gdf-app .gdf-actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 10px;
	margin-top: 18px;
}

.gdf-app .gdf-error,
.gdf-app .gdf-noscript {
	display: none;
	margin: 16px 0 0;
	padding: 14px 16px;
	border: 1px solid var(--gdf-low);
	border-radius: 14px;
	background: var(--gdf-surface);
	color: var(--gdf-ink);
}

.gdf-app .gdf-noscript,
.gdf-app.gdf-has-error .gdf-error {
	display: block;
}

/* Toast: visible feedback plus a polite live region for screen readers. */
.gdf-app .gdf-toast {
	position: fixed;
	left: 50%;
	bottom: calc(20px + env(safe-area-inset-bottom, 0px));
	z-index: 99999;
	max-width: min(92vw, 420px);
	padding: 12px 18px;
	border-radius: 14px;
	background: var(--gdf-ink);
	color: var(--gdf-surface);
	font-size: 15px;
	font-weight: 600;
	text-align: center;
	box-shadow: 0 14px 34px -12px rgba(0, 0, 0, 0.5);
	opacity: 0;
	pointer-events: none;
	transform: translate(-50%, 16px);
	transition: opacity 0.2s ease, transform 0.2s ease;
}

.gdf-app .gdf-toast:empty {
	padding: 0;
}

.gdf-app .gdf-toast.gdf-toast-show {
	opacity: 1;
	transform: translate(-50%, 0);
}

/* ---------- Responsive ---------- */

@media (max-width: 640px) {
	.gdf-app {
		border-radius: 18px;
	}

	.gdf-app .gdf-filters {
		flex-wrap: nowrap;
		margin-right: calc(-1 * var(--gdf-pad));
		margin-left: calc(-1 * var(--gdf-pad));
		padding: 0 var(--gdf-pad) 2px;
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: none;
	}

	.gdf-app .gdf-filters::-webkit-scrollbar {
		display: none;
	}

	.gdf-app .gdf-tools {
		grid-template-columns: minmax(0, 1fr);
		gap: 6px;
	}

	.gdf-app .gdf-options-grid {
		grid-template-columns: 1fr 1fr;
		padding: 4px 0 6px;
	}

	.gdf-app .gdf-input {
		min-height: 2.2em;
		font-size: 21px;
	}

	.gdf-app .gdf-compose-bar {
		flex-wrap: nowrap;
	}

	.gdf-app .gdf-compose-actions .gdf-btn {
		padding: 8px 10px;
	}

	.gdf-app .gdf-row {
		grid-template-columns: minmax(0, 1fr) auto;
		padding: 12px 6px 12px 12px;
	}

	.gdf-app .gdf-row-meta {
		grid-column: 1 / -1;
		padding-left: 10px;
	}

	.gdf-app .gdf-compose {
		padding: 12px 14px 8px;
	}

	.gdf-app .gdf-actions .gdf-btn-primary {
		flex: 1 1 100%;
	}
}

@media (max-width: 360px) {
	.gdf-app .gdf-options-grid {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 420px) {

	.gdf-app .gdf-copy {
		width: 44px;
		padding: 0;
		justify-content: center;
	}

	.gdf-app .gdf-copy .gdf-copy-label {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip: rect(0, 0, 0, 0);
		white-space: nowrap;
	}
}

@media (prefers-reduced-motion: reduce) {
	.gdf-app *,
	.gdf-app *::before,
	.gdf-app *::after {
		transition: none !important;
		animation: none !important;
	}
}

@media print {
	.gdf-app .gdf-filters,
	.gdf-app .gdf-tools,
	.gdf-app .gdf-actions,
	.gdf-app .gdf-row-actions,
	.gdf-app .gdf-toast {
		display: none !important;
	}
}
