/* Traço Mangá Core */

:root {
	--pc-cor: #C0392B;
	--pc-cor-escuro: #922B21;
	--pc-borda: #cccccc;
}

/* ---------- Grades ---------- */
.pc-grade {
	--pc-colunas: 4;
	display: grid;
	grid-template-columns: repeat(var(--pc-colunas), minmax(0, 1fr));
	gap: 14px;
	list-style: none;
	margin: 18px 0 26px;
	padding: 0;
}

.pc-card {
	margin: 0;
}

.pc-card a {
	display: flex;
	flex-direction: column;
	height: 100%;
	color: inherit;
	text-decoration: none;
	border: 1px solid var(--pc-borda);
	border-radius: 8px;
	background: #ffffff;
	overflow: hidden;
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.pc-card a:hover,
.pc-card a:focus-visible {
	transform: scale(1.03);
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}

.pc-card-img {
	display: block;
	aspect-ratio: 1 / 1;
	background: #ffffff;
	padding: 6px;
}

.pc-card-img img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.pc-card-sem-imagem {
	display: block;
	width: 100%;
	height: 100%;
	background: repeating-linear-gradient(45deg, #f4f4f4, #f4f4f4 10px, #fafafa 10px, #fafafa 20px);
}

.pc-card-titulo {
	display: block;
	padding: 8px 8px 10px;
	font-size: 15px;
	line-height: 1.3;
	font-weight: 600;
	text-align: center;
	color: #333333;
}

.pc-card-categoria .pc-card-titulo {
	font-size: 17px;
	font-weight: 700;
	color: var(--pc-cor);
	padding-top: 10px;
	padding-bottom: 4px;
}

@media (max-width: 1024px) {
	.pc-grade {
		grid-template-columns: repeat(min(var(--pc-colunas), 3), minmax(0, 1fr));
	}
}

@media (max-width: 600px) {
	.pc-grade {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 10px;
	}

	.pc-card-titulo {
		font-size: 14px;
	}
}

/* ---------- Barra lateral de categorias ---------- */
.pc-menu-lateral {
	background: var(--pc-cor);
	border-radius: 8px;
	overflow: hidden;
	color: #ffffff;
}

.pc-menu-lateral + .pc-menu-lateral {
	margin-top: 16px;
}

/* tutoriais: caixa escura, para separar das categorias de desenho */
.pc-menu-tutoriais {
	background: #2b2b2b;
}

.pc-menu-tutoriais .pc-menu-titulo {
	background: #111111;
}

.pc-menu-tutoriais a {
	padding: 10px 12px;
}

.pc-menu-icone {
	flex: 0 0 auto;
	width: 28px;
	text-align: center;
	font-size: 18px;
}

.pc-menu-titulo {
	margin: 0;
	padding: 12px 14px;
	font-size: 20px;
	font-weight: 700;
	background: var(--pc-cor-escuro);
}

.pc-menu-lateral ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.pc-menu-lateral li {
	margin: 0;
	border-top: 1px solid rgba(255, 255, 255, 0.85);
}

.pc-menu-lateral li:first-child {
	border-top: 0;
}

.pc-menu-lateral a {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 6px 8px;
	color: #ffffff;
	text-decoration: none;
	font-size: 16px;
	font-weight: 600;
	line-height: 1.25;
}

.pc-menu-lateral a:hover,
.pc-menu-lateral a:focus-visible,
.pc-menu-lateral .pc-atual a {
	background: var(--pc-cor-escuro);
	color: #ffffff;
}

.pc-menu-lateral img,
.pc-menu-sem-imagem {
	flex: 0 0 auto;
	width: 64px;
	height: 64px;
	object-fit: cover;
	border-radius: 6px;
	background: #ffffff;
	transition: transform 0.15s ease;
}

.pc-menu-lateral a:hover img {
	transform: scale(1.03);
}

@media (max-width: 768px) {
	.pc-menu-lateral ul {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.pc-menu-lateral li,
	.pc-menu-lateral li:first-child {
		border-top: 1px solid rgba(255, 255, 255, 0.5);
	}

	.pc-menu-lateral li:nth-child(odd) {
		border-right: 1px solid rgba(255, 255, 255, 0.5);
	}

	.pc-menu-lateral img,
	.pc-menu-sem-imagem {
		width: 44px;
		height: 44px;
	}

	.pc-menu-lateral a {
		font-size: 14px;
	}
}

/* ---------- Página do desenho ---------- */
.pc-na-categoria {
	font-size: 20px;
	margin: 0 0 14px;
	font-weight: 600;
}

.pc-acoes {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 0 0 10px;
}

.pc-botao,
a.pc-botao {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	min-height: 46px;
	padding: 10px 18px;
	border: 2px solid var(--pc-cor);
	border-radius: 999px;
	background: #ffffff;
	color: var(--pc-cor);
	font-size: 17px;
	font-weight: 700;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
}

.pc-botao:hover,
.pc-botao:focus-visible {
	background: #eaf3f8;
	color: var(--pc-cor-escuro);
}

.pc-botao-imprimir,
.pc-botao-imprimir:hover,
.pc-botao-imprimir:focus-visible {
	background: var(--pc-cor);
	color: #ffffff;
}

.pc-botao-imprimir:hover {
	background: var(--pc-cor-escuro);
}

.pc-botao-irma,
a.pc-botao-irma {
	border-color: #6a1b9a;
	color: #6a1b9a;
}

.pc-botao-irma:hover,
a.pc-botao-irma:hover {
	background: #6a1b9a;
	color: #ffffff;
}

.pc-contador {
	font-size: 15px;
	color: #555555;
	margin: 0 0 16px;
}

.pc-figura {
	margin: 0 0 28px;
	text-align: center;
}

.pc-figura img {
	display: block;
	margin: 0 auto;
	max-width: 100%;
	height: auto;
	border: 1px solid var(--pc-borda);
	background: #ffffff;
}

.pc-figura figcaption {
	margin-top: 8px;
	font-size: 15px;
	color: #555555;
}

.pc-continue {
	margin-top: 32px;
}

.pc-ver-todos {
	text-align: center;
}

@media (max-width: 600px) {
	.pc-acoes .pc-botao {
		flex: 1 1 calc(50% - 10px);
		font-size: 15px;
		padding: 8px 10px;
	}
}

/* ---------- anúncios ---------- */
.pc-anuncio {
	display: block;
	margin: 22px auto;
	padding: 6px 0;
	text-align: center;
	max-width: 100%;
	clear: both;
}

/* o espaço é reservado para a página não "pular" quando o anúncio carrega */
.pc-anuncio ins.adsbygoogle {
	display: block;
	min-width: 300px;
	min-height: 250px;
	margin: 0 auto;
}

/* quando o Google não tem anúncio para aquela visita, some o espaço e o rótulo */
.pc-anuncio ins.adsbygoogle[data-ad-status="unfilled"] {
	display: none !important;
}

.pc-anuncio:has(ins.adsbygoogle[data-ad-status="unfilled"]) {
	display: none;
}

@media (max-width: 480px) {
	.pc-anuncio ins.adsbygoogle {
		min-width: 250px;
	}
}

.pc-anuncio-rotulo {
	display: block;
	margin-bottom: 4px;
	font-size: 11px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #8a8a8a;
}

/* separa bem o anúncio da grade de desenhos, para ninguém confundir com conteúdo */
.pc-anuncio-grade-categoria {
	margin: 26px auto;
	padding: 10px 0;
	border-top: 1px solid var(--pc-borda);
	border-bottom: 1px solid var(--pc-borda);
}

/* nunca dentro do editor nem na hora de imprimir */
.pc-editor .pc-anuncio,
.pc-editor-cheio ~ .pc-anuncio {
	display: none;
}

/* ---------- Quebra-cabeça ---------- */
.pc-qc-palco {
	background: #ffffff;
}

.pc-qc-guia {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0.12;
	pointer-events: none;
	transition: opacity 0.2s ease;
}

.pc-qc-espiando .pc-qc-guia {
	opacity: 0.55;
}

.pc-qc-pronto .pc-qc-guia {
	opacity: 0;
}

.pc-qc-grade {
	position: absolute;
	inset: 0;
	display: grid;
}

.pc-qc-alvo {
	position: relative;
	border: 1px dashed #c9c9c9;
}

.pc-qc-peca img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: fill;
	pointer-events: none;
}

/* números de ajuda: só aparecem com o botão Espiar ligado */
.pc-qc-numero {
	display: none;
	position: absolute;
	top: 2px;
	left: 3px;
	padding: 0 4px;
	border-radius: 6px;
	background: rgba(255, 255, 255, 0.85);
	color: #1e88e5;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.5;
	pointer-events: none;
}

.pc-qc-alvo .pc-qc-numero {
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	font-size: 22px;
	color: #2e7d32;
	background: rgba(255, 255, 255, 0.7);
}

.pc-qc-espiando .pc-qc-numero {
	display: block;
}

.pc-qc-pronto .pc-qc-numero {
	display: none !important;
}

.pc-qc-alvo .pc-qc-peca {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	aspect-ratio: auto;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
	cursor: default;
}

.pc-qc-pronto .pc-qc-alvo {
	border-color: transparent;
}

/* duas colunas de peças (a classe do editor define 92px, por isso a dupla) */
.pc-editor-lateral.pc-qc-lateral {
	width: calc(var(--pc-qc-peca-largura, 46px) * 2 + 14px);
	max-height: none;
	min-height: 0;
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	align-content: flex-start;
	justify-content: center;
	gap: 6px;
	overflow: visible;
}

.pc-qc-peca {
	position: relative;
	display: block;
	width: var(--pc-qc-peca-largura, 46px);
	height: auto;
	aspect-ratio: 1 / var(--pc-qc-proporcao, 1.3);
	overflow: hidden;
	border: 2px solid #b9b9b9;
	border-radius: 6px;
	background: #ffffff;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
	cursor: grab;
	touch-action: none;
	user-select: none;
	-webkit-user-select: none;
}

.pc-qc-peca:hover,
.pc-qc-peca:focus-visible {
	border-color: var(--pc-cor);
}

.pc-qc-selecionada {
	border-color: #2e7d32;
	box-shadow: 0 0 0 3px rgba(46, 125, 50, 0.35);
}

.pc-qc-arrastando {
	position: fixed !important;
	z-index: 100010;
	pointer-events: none;
	cursor: grabbing;
	border-color: var(--pc-cor);
	box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
}

.pc-qc-encaixada {
	animation: pc-encaixe 0.25s ease;
}

@keyframes pc-encaixe {
	from { transform: scale(1.12); }
	to { transform: scale(1); }
}

.pc-qc-erro {
	animation: pc-tremer 0.35s ease;
}

@keyframes pc-tremer {
	25% { transform: translateX(-5px); }
	75% { transform: translateX(5px); }
}

/* no celular as peças ficam numa faixa embaixo do tabuleiro */
@media (max-width: 700px) {
	.pc-qc-area {
		flex-direction: column;
		align-items: center;
	}

	.pc-editor-lateral.pc-qc-lateral {
		width: 100%;
		max-width: 100%;
		min-height: 0;
		justify-content: center;
		padding-top: 8px;
	}

	.pc-qc-peca {
		width: calc(var(--pc-qc-peca-largura, 46px) - 4px);
	}
}

/* ---------- Editor de colorir ---------- */
.pc-editor {
	margin: 0 0 32px;
	padding: 14px;
	border: 1px solid var(--pc-borda);
	border-radius: 10px;
	background: #fafafa;
	scroll-margin-top: 8px;
}

.pc-editor h2 {
	margin-top: 0;
}

.pc-editor-dica {
	font-size: 15px;
	color: #555555;
}

.pc-editor-barra,
.pc-editor-ajustes {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 14px;
	align-items: center;
	margin-bottom: 8px;
}

.pc-editor-grupo {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	align-items: center;
}

.pc-editor-bt {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	min-height: 42px;
	padding: 5px 11px;
	border: 1px solid #b9b9b9;
	border-radius: 10px;
	background: #ffffff;
	color: #222222;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.1;
	cursor: pointer;
	touch-action: manipulation;
}

.pc-editor-bt .pc-icone {
	font-size: 19px;
}

.pc-editor-bt:hover,
.pc-editor-bt:focus-visible {
	border-color: var(--pc-cor);
	background: #ffffff;
	color: var(--pc-cor);
}

.pc-editor-bt.pc-ativo {
	border-color: var(--pc-cor);
	background: var(--pc-cor);
	color: #ffffff;
}

.pc-editor-bt[disabled] {
	opacity: 0.4;
	cursor: default;
}

.pc-editor-bt-proximo,
a.pc-editor-bt-proximo {
	border-color: #ef6c00;
	color: #ef6c00;
	text-decoration: none;
}

.pc-editor-bt-proximo:hover,
a.pc-editor-bt-proximo:hover {
	background: #ef6c00;
	color: #ffffff;
}

.pc-editor-bt-destaque,
.pc-editor-bt-destaque:hover,
.pc-editor-bt-destaque:focus-visible {
	border-color: #2e7d32;
	background: #2e7d32;
	color: #ffffff;
}

/* opções da ferramenta: no computador quebram linha; no celular rolam de lado (ver media query) */
.pc-editor-ajustes {
	padding-bottom: 2px;
}

.pc-editor-opcoes {
	display: none;
	flex: 0 1 auto;
	flex-wrap: wrap;
	gap: 5px;
}

.pc-ferr-balde .pc-opcoes-balde,
.pc-ferr-pincel .pc-opcoes-pincel,
.pc-ferr-carimbo .pc-opcoes-carimbo {
	display: flex;
}

.pc-ajuste-tamanho,
.pc-ajuste-transparencia {
	display: none;
}

.pc-ferr-pincel .pc-ajuste-tamanho,
.pc-ferr-borracha .pc-ajuste-tamanho,
.pc-ferr-carimbo .pc-ajuste-tamanho,
.pc-ferr-balde .pc-ajuste-transparencia,
.pc-ferr-pincel .pc-ajuste-transparencia {
	display: inline-flex;
}

.pc-editor-opcao {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	min-height: 38px;
	padding: 3px 9px;
	border: 1px solid #c9c9c9;
	border-radius: 999px;
	background: #ffffff;
	color: #333333;
	font-size: 14px;
	font-weight: 600;
	white-space: nowrap;
	cursor: pointer;
	touch-action: manipulation;
}

.pc-opcoes-carimbo .pc-editor-opcao {
	min-width: 42px;
	justify-content: center;
	font-size: 22px;
	padding: 2px 6px;
}

.pc-editor-opcao.pc-ativo {
	border-color: var(--pc-cor);
	box-shadow: inset 0 0 0 2px var(--pc-cor);
	background: #eaf3f8;
	color: var(--pc-cor-escuro);
}

.pc-amostra-efeito {
	display: inline-block;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	border: 1px solid rgba(0, 0, 0, 0.25);
	background: #e53935;
}

.pc-efeito-degrade { background: linear-gradient(180deg, #f6b3b1, #e53935); }
.pc-efeito-arcoiris { background: conic-gradient(#e53935, #fdd835, #43a047, #1e88e5, #8e24aa, #e53935); }
.pc-efeito-bolinhas { background: radial-gradient(circle, #e53935 28%, transparent 30%) 0 0 / 8px 8px, #f6b3b1; }
.pc-efeito-listras { background: repeating-linear-gradient(45deg, #e53935 0 4px, #f6b3b1 4px 8px); }
.pc-efeito-brilho { background: radial-gradient(circle at 30% 30%, #ffffff 0 12%, transparent 14%), radial-gradient(circle at 68% 62%, #ffffff 0 10%, transparent 12%), #e53935; }
.pc-efeito-giz { background: repeating-linear-gradient(100deg, #e53935 0 3px, #f3a19f 3px 5px); }
.pc-efeito-spray { background: radial-gradient(circle, #e53935 0 18%, transparent 20%) 0 0 / 6px 6px, #ffffff; }

.pc-editor-ajuste {
	flex: 0 0 auto;
	align-items: center;
	gap: 6px;
	font-size: 14px;
	font-weight: 600;
	white-space: nowrap;
}

.pc-editor-ajuste input[type="range"] {
	width: 110px;
}

/* desenho + paleta lado a lado */
.pc-editor-area {
	display: flex;
	justify-content: center;
	align-items: flex-start;
	column-gap: 8px;
}

.pc-editor-palco {
	position: relative;
	flex: 0 0 auto;
	width: 100%;
	max-width: 100%;
	aspect-ratio: 2 / 3;
	background: #ffffff;
	border: 1px solid var(--pc-borda);
	user-select: none;
	-webkit-user-select: none;
	-webkit-touch-callout: none;
}

.pc-editor-palco canvas {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
}

.pc-camada-linhas {
	mix-blend-mode: multiply;
	cursor: crosshair;
}

/* com pincel e borracha o toque desenha; com balde e carimbo o toque ainda rola a página */
.pc-ferr-pincel .pc-camada-linhas,
.pc-ferr-borracha .pc-camada-linhas {
	touch-action: none;
}

.pc-editor-aviso {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	color: #666666;
}

.pc-editor-lateral {
	flex: 0 0 auto;
	display: flex;
	flex-direction: column;
	gap: 6px;
	width: 92px;
	min-height: 200px;
}

.pc-editor-cor-atual {
	flex: 0 0 auto;
	display: block;
}

.pc-editor-cor-atual input[type="color"] {
	display: block;
	width: 100%;
	height: 48px;
	padding: 0;
	border: 3px solid #333333;
	border-radius: 10px;
	background: none;
	cursor: pointer;
}

.pc-editor-paleta {
	flex: 1 1 auto;
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	grid-auto-rows: 40px;
	gap: 5px;
	overflow-y: auto;
	overscroll-behavior: contain;
	padding: 3px;
	border-radius: 8px;
	background: #ffffff;
	border: 1px solid #dddddd;
}

.pc-editor-amostra {
	width: 100%;
	height: 100%;
	padding: 0;
	border: 1px solid rgba(0, 0, 0, 0.25);
	border-radius: 8px;
	cursor: pointer;
	touch-action: manipulation;
}

.pc-editor-amostra.pc-ativo {
	outline: 3px solid #222222;
	outline-offset: -1px;
	box-shadow: inset 0 0 0 3px #ffffff;
}

/* modo pontilhado: progresso de quanto já foi coberto */
.pc-modo-pontilhado .pc-ajuste-transparencia {
	display: none !important;
}

.pc-editor-progresso {
	flex: 1 0 200px;
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 180px;
}

.pc-progresso-trilho {
	flex: 1 1 auto;
	height: 14px;
	border-radius: 999px;
	background: #e3e3e3;
	overflow: hidden;
}

.pc-progresso-barra {
	display: block;
	width: 0;
	height: 100%;
	border-radius: 999px;
	background: linear-gradient(90deg, #fdd835, #fb8c00, #e53935, #8e24aa);
	transition: width 0.4s ease;
}

.pc-progresso-texto {
	flex: 0 0 auto;
	font-size: 14px;
	font-weight: 700;
	white-space: nowrap;
}

.pc-editor-progresso.pc-completo .pc-progresso-texto {
	color: #2e7d32;
}

.pc-editor-festa {
	position: absolute;
	inset: 0;
	overflow: hidden;
	pointer-events: none;
	z-index: 5;
}

.pc-editor-festa span {
	position: absolute;
	top: -40px;
	animation: pc-cair 2.2s ease-in forwards;
}

@keyframes pc-cair {
	to { transform: translateY(110vh) rotate(360deg); opacity: 0.2; }
}

/* ligue os pontos */
.pc-pontos-palco {
	position: relative;
	margin: 0 auto;
	max-width: 100%;
	background: #ffffff;
	border: 1px solid var(--pc-borda);
	user-select: none;
	-webkit-user-select: none;
	-webkit-touch-callout: none;
}

.pc-pontos-img,
.pc-pontos-completo {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	max-width: none;
	pointer-events: none;
}

.pc-pontos-completo {
	opacity: 0;
	transition: opacity 1.2s ease;
}

.pc-pontos-revelado .pc-pontos-completo {
	opacity: 1;
}

.pc-pontos-canvas {
	position: absolute;
	inset: 0;
	touch-action: none;
	cursor: crosshair;
}

.pc-pontos-revelado .pc-pontos-canvas {
	opacity: 0;
	transition: opacity 1.2s ease;
}

.pc-pontos-final {
	margin: 12px 0 0;
	text-align: center;
	font-size: 18px;
	font-weight: 700;
}

.pc-pontos-final p {
	margin: 0 0 8px;
	color: #2e7d32;
}

.pc-pontos-final-acoes {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	justify-content: center;
}

.pc-botao-proximo,
a.pc-botao-proximo {
	border-color: #ef6c00;
	background: #ef6c00;
	color: #ffffff;
}

.pc-botao-proximo:hover,
a.pc-botao-proximo:hover {
	background: #e65100;
	border-color: #e65100;
	color: #ffffff;
}

/* na tela cheia a mensagem fica no alto, longe do anúncio fixo do rodapé */
.pc-editor-cheio .pc-pontos-final {
	position: absolute;
	left: 50%;
	transform: translateX(-50%);
	top: calc(var(--pc-reserva-topo, 0px) + var(--pc-barra-altura, 56px) + 14px);
	bottom: auto;
	z-index: 6;
	max-width: min(560px, calc(100% - 16px));
	padding: 10px 16px;
	border-radius: 12px;
	background: rgba(255, 255, 255, 0.96);
	box-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
}

/* tela cheia: só o desenho e as ferramentas */
html.pc-sem-rolagem,
html.pc-sem-rolagem body {
	overflow: hidden;
	overscroll-behavior: none;
}

.pc-editor.pc-editor-cheio {
	position: fixed;
	inset: 0;
	z-index: 100000;
	margin: 0;
	padding: 8px;
	border: 0;
	border-radius: 0;
	background: #f4f4f4;
	overflow: hidden;
	/* espaço para o anúncio fixo (topo ou rodapé) não cobrir o desenho */
	padding-top: calc(8px + var(--pc-reserva-topo, 0px));
	padding-bottom: calc(8px + var(--pc-reserva-anuncio, 0px));
}

.pc-editor-cheio > h2,
.pc-editor-cheio > .pc-editor-dica {
	display: none;
}

.pc-editor-bt-cheio {
	border-color: #ef6c00;
	color: #ef6c00;
}

.pc-editor-cheio .pc-editor-bt-cheio {
	background: #ef6c00;
	border-color: #ef6c00;
	color: #ffffff;
}

@media (max-width: 600px) {
	.pc-editor {
		padding: 10px 8px;
	}

	.pc-editor-bt {
		min-height: 40px;
		padding: 4px 8px;
	}

	.pc-editor-grupo {
		gap: 4px;
	}

	.pc-editor-barra {
		gap: 4px 8px;
	}

	/* no celular as opções ficam numa linha só, que rola de lado, para não empurrar o desenho */
	.pc-editor-ajustes {
		flex-wrap: nowrap;
		overflow-x: auto;
		scrollbar-width: thin;
	}

	.pc-ferr-balde .pc-opcoes-balde,
	.pc-ferr-pincel .pc-opcoes-pincel,
	.pc-ferr-carimbo .pc-opcoes-carimbo {
		flex: 0 0 auto;
		flex-wrap: nowrap;
	}

	/* no celular os botões mostram só o ícone (o nome fica no aria-label) */
	.pc-editor-bt .pc-rotulo {
		display: none;
	}

	.pc-editor-bt .pc-icone {
		font-size: 21px;
	}

	.pc-editor-opcao .pc-rotulo {
		font-size: 13px;
	}

	.pc-editor-lateral {
		width: 72px;
	}

	.pc-editor-paleta {
		grid-auto-rows: 32px;
		gap: 4px;
	}

	.pc-editor-cor-atual input[type="color"] {
		height: 40px;
	}

	.pc-editor-ajuste input[type="range"] {
		width: 90px;
	}
}

/* ---------- Convite para instalar o app ---------- */
.pc-app-convite {
	position: fixed;
	left: 8px;
	right: 8px;
	bottom: calc(8px + env(safe-area-inset-bottom, 0px));
	z-index: 9990;
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 10px 12px 12px;
	border-radius: 18px;
	background: linear-gradient(135deg, #1e88e5 0%, #8e24aa 55%, #ec407a 100%);
	color: #ffffff;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
	animation: pc-app-entrar 0.45s ease-out;
}

@keyframes pc-app-entrar {
	from { transform: translateY(120%); opacity: 0; }
	to { transform: translateY(0); opacity: 1; }
}

.pc-app-convite[hidden],
.pc-app-convite [hidden],
.pc-app-botao[hidden] {
	display: none !important;
}

.pc-app-convite img {
	flex: 0 0 auto;
	width: 58px;
	height: 58px;
	padding: 3px;
	border-radius: 14px;
	background: #ffffff;
}

.pc-app-texto {
	flex: 1 1 auto;
	margin: 0;
	font-size: 16px;
	line-height: 1.25;
}

.pc-app-texto strong {
	display: block;
	font-size: 17px;
}

.pc-app-ajuda {
	display: block;
	margin-top: 4px;
	font-size: 14px;
	font-weight: 600;
	color: #fff9c4;
}

.pc-app-adicionar {
	flex: 0 0 auto;
	min-height: 46px;
	padding: 8px 16px;
	border: 0;
	border-radius: 999px;
	background: #fdd835;
	color: #1a1a1a;
	font-size: 16px;
	font-weight: 800;
	box-shadow: 0 3px 0 #c6a700;
	animation: pc-app-pulsar 1.6s ease-in-out 1s 3;
}

@keyframes pc-app-pulsar {
	50% { transform: scale(1.08); }
}

.pc-app-fechar {
	position: absolute;
	top: -10px;
	right: -4px;
	width: 30px;
	height: 30px;
	padding: 0;
	border: 2px solid #ffffff;
	border-radius: 50%;
	background: #333333;
	color: #ffffff;
	font-size: 14px;
	line-height: 26px;
}

.pc-app-botao-envoltorio {
	padding: 4px 16px 8px;
	text-align: center;
}

.pc-app-botao {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	max-width: 620px;
	min-height: 50px;
	padding: 10px 18px;
	border: 0;
	border-radius: 999px;
	background: linear-gradient(135deg, #1e88e5 0%, #8e24aa 55%, #ec407a 100%);
	color: #ffffff;
	font-size: 17px;
	font-weight: 700;
	box-shadow: 0 4px 14px rgba(142, 36, 170, 0.35);
	cursor: pointer;
}

.pc-app-botao .pc-app-emoji {
	font-size: 22px;
}

.pc-app-botao:hover,
.pc-app-botao:focus-visible {
	color: #ffffff;
	filter: brightness(1.08);
}

@media print {
	.pc-app-convite,
	.pc-app-botao-envoltorio {
		display: none !important;
	}
}

/* ---------- Impressão: só o desenho e o domínio, sempre numa folha ---------- */
#pc-impressao {
	display: none;
}

@media print {
	@page {
		size: A4 portrait;
		margin: 8mm;
	}

	html,
	body.pc-tem-impressao {
		margin: 0 !important;
		padding: 0 !important;
		background: #ffffff !important;
	}

	body.pc-tem-impressao > *:not(#pc-impressao) {
		display: none !important;
	}

	body.pc-tem-impressao #pc-impressao {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		width: 100%;
		height: min(281mm, 100vh);
		overflow: hidden;
		break-inside: avoid;
		page-break-inside: avoid;
		break-after: avoid;
	}

	#pc-impressao img {
		display: block;
		width: auto;
		height: auto;
		max-width: 100%;
		max-height: min(270mm, calc(100vh - 10mm));
		object-fit: contain;
	}

	#pc-impressao p {
		margin: 2mm 0 0;
		font: 9pt/1.2 Arial, sans-serif;
		color: #555555;
	}
}

/* ---------- Página do tutorial ---------- */
.pc-tut-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	margin: 0 0 20px;
	color: #555555;
	font-size: 15px;
}

.pc-tut-meta a {
	color: var(--pc-cor);
	font-weight: 600;
}

.pc-tut-selo {
	display: inline-block;
	padding: 2px 10px;
	border-radius: 999px;
	background: var(--pc-cor);
	color: #ffffff;
	font-weight: 700;
	font-size: 14px;
}

.pc-tut-capa {
	margin: 0 0 24px;
}

.pc-tut-capa img {
	width: 100%;
	height: auto;
	border-radius: 8px;
}

.pc-tutorial-texto {
	max-width: 760px;
	font-size: 18px;
	line-height: 1.75;
}

.pc-tutorial-texto h2 {
	margin: 36px 0 12px;
	padding-left: 12px;
	border-left: 5px solid var(--pc-cor);
	font-size: 26px;
	line-height: 1.3;
}

.pc-tutorial-texto h3 {
	margin: 28px 0 10px;
	font-size: 21px;
}

.pc-tutorial-texto ul,
.pc-tutorial-texto ol {
	margin-left: 1.4em;
}

.pc-tutorial-texto li {
	margin-bottom: 6px;
}

.pc-tutorial-texto a {
	color: var(--pc-cor);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.pc-tutorial-texto img {
	max-width: 100%;
	height: auto;
	border-radius: 6px;
}

.pc-tutorial-texto figure {
	margin: 24px 0;
}

.pc-tutorial-texto figcaption {
	margin-top: 6px;
	color: #555555;
	font-size: 15px;
	text-align: center;
}

.pc-tutorial-texto blockquote {
	margin: 24px 0;
	padding: 12px 18px;
	border-left: 5px solid var(--pc-cor);
	background: #fbeeec;
	font-style: normal;
}

/* ---------- Lista de tutoriais ---------- */
.pc-tut-lista {
	list-style: none;
	margin: 0 0 24px;
	padding: 0;
	display: grid;
	gap: 14px;
}

.pc-tut-card a {
	display: flex;
	gap: 14px;
	align-items: stretch;
	padding: 12px;
	border: 2px solid #e2e2e2;
	border-radius: 10px;
	color: inherit;
	text-decoration: none;
	transition: border-color 0.15s ease;
}

.pc-tut-card a:hover,
.pc-tut-card a:focus-visible {
	border-color: var(--pc-cor);
}

.pc-tut-card-img {
	flex: 0 0 120px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 8px;
	background: #fbeeec;
	overflow: hidden;
}

.pc-tut-card-img img {
	width: 120px;
	height: 120px;
	object-fit: cover;
}

.pc-tut-card-icone {
	font-size: 40px;
}

.pc-tut-card-corpo {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.pc-tut-card-titulo {
	font-size: 19px;
	font-weight: 700;
	line-height: 1.3;
}

.pc-tut-card-resumo {
	color: #555555;
	font-size: 15px;
	line-height: 1.5;
}

.pc-tut-card-ler {
	margin-top: auto;
	color: var(--pc-cor);
	font-weight: 700;
	font-size: 15px;
}

@media (max-width: 600px) {
	.pc-tut-card-img {
		flex-basis: 72px;
	}

	.pc-tut-card-img img {
		width: 72px;
		height: 72px;
	}

	.pc-tut-card-resumo {
		display: none;
	}

	.pc-tutorial-texto {
		font-size: 17px;
	}

	.pc-tutorial-texto h2 {
		font-size: 22px;
	}
}

/* ---------- Nota de autoria (fim do tutorial) ---------- */
.pc-autoria {
	display: flex;
	gap: 14px;
	align-items: center;
	max-width: 760px;
	margin: 32px 0 8px;
	padding: 14px 16px;
	border: 2px solid #e2e2e2;
	border-radius: 10px;
	background: #faf7f6;
	font-size: 15px;
	line-height: 1.55;
	color: #444444;
}

.pc-autoria p {
	margin: 0;
}

.pc-autoria a {
	color: var(--pc-cor);
	font-weight: 600;
}

.pc-autoria-img {
	flex: 0 0 64px;
	width: 64px;
	height: 64px;
	border-radius: 50%;
	object-fit: cover;
}

.pc-tut-fig {
	margin: 18px 0 24px;
}

/* ---------- Página inicial ---------- */
.pc-hero {
	display: flex;
	align-items: center;
	gap: 24px;
	margin: 0 0 32px;
	padding: 24px;
	border-radius: 14px;
	background: #fbeeec;
}

.pc-hero-texto {
	flex: 1 1 60%;
}

.pc-hero h1 {
	margin: 0 0 12px;
	font-size: 34px;
	line-height: 1.2;
}

.pc-hero p {
	margin: 0 0 16px;
	font-size: 18px;
}

.pc-hero-botoes {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.pc-hero-botoes .pc-botao-cheio {
	background: var(--pc-cor);
	color: #ffffff;
}

.pc-hero-img {
	flex: 0 0 34%;
	max-width: 260px;
}

.pc-hero-img img {
	width: 100%;
	height: auto;
	border-radius: 12px;
}

.pc-trilha {
	counter-reset: trilha;
}

.pc-trilha .pc-tut-card a::before {
	counter-increment: trilha;
	content: counter(trilha);
	flex: 0 0 36px;
	height: 36px;
	border-radius: 50%;
	background: var(--pc-cor);
	color: #ffffff;
	font-weight: 700;
	display: flex;
	align-items: center;
	justify-content: center;
	align-self: center;
}

.pc-frentes {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 14px;
	margin: 0 0 28px;
}

.pc-frente {
	padding: 16px;
	border: 2px solid #e2e2e2;
	border-top: 5px solid var(--pc-cor);
	border-radius: 10px;
}

.pc-frente h3 {
	margin: 0 0 8px;
	font-size: 19px;
}

.pc-frente p {
	margin: 0;
	font-size: 15px;
	line-height: 1.55;
}

.pc-quem {
	display: flex;
	gap: 16px;
	align-items: center;
	padding: 16px;
	border-radius: 10px;
	background: #faf7f6;
	margin: 0 0 28px;
}

.pc-quem img {
	flex: 0 0 96px;
	width: 96px;
	height: 96px;
	border-radius: 50%;
	object-fit: cover;
}

.pc-quem p {
	margin: 0;
}

@media (max-width: 700px) {
	.pc-hero {
		flex-direction: column-reverse;
		text-align: center;
		padding: 18px;
	}

	.pc-hero h1 {
		font-size: 27px;
	}

	.pc-hero-botoes {
		justify-content: center;
	}

	.pc-hero-img {
		max-width: 170px;
	}

	.pc-frentes {
		grid-template-columns: 1fr;
	}

	.pc-quem {
		flex-direction: column;
		text-align: center;
	}
}
