/**
 * Tema: WordPress Site Factory - Starter Theme
 * Arquivo: assets/css/template-single.css
 *
 * Desenvolvido por: Roger Alves
 * Data da Modificacao: 2026-05-28
 * Hora da Modificacao: 21:30
 *
 * Todos os direitos reservados.
 */

/* ============================================================
   HERO DO POST
   ============================================================ */
.single-hero {
	position: relative;
	min-height: clamp(360px, 44vh, 480px);
	display: flex;
	align-items: flex-end;
	background-color: #062547;
	overflow: hidden;
}

.single-hero--article {
	min-height: clamp(280px, 34vh, 360px);
	background: linear-gradient(135deg, #030f1d, #062547);
}

.single-hero-image {
	position: absolute;
	inset: 0;
	overflow: hidden;
}

.single-hero-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	opacity: 0.45;
}

.single-hero-image--category {
	inset: -14% 0;
}

.single-hero-image--category img {
	height: 128%;
	object-position: top;
	opacity: 0.24;
	filter: grayscale(1) sepia(0.12);
}

.single-hero-overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(
		to top,
		rgba(3, 15, 29, 0.98) 0%,
		rgba(6, 37, 71, 0.74) 50%,
		rgba(6, 37, 71, 0.3) 100%
	);
}

.single-hero-content {
	position: relative;
	z-index: 1;
	padding-top: clamp(3rem, 6vh, 4.5rem);
	padding-bottom: clamp(1.75rem, 4vh, 2.5rem);
}

.single-hero-title-row {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(300px, 420px);
	gap: clamp(1.5rem, 4vw, 3rem);
	align-items: center;
}

.single-hero--article:not(.single-hero--has-image) .single-hero-title-row {
	grid-template-columns: 1fr;
}

.single-hero--has-image .single-hero-title-row {
	grid-template-columns: minmax(0, 1fr) clamp(200px, 28vw, 320px);
}

.single-hero-title-copy {
	min-width: 0;
}

.single-breadcrumb {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.25rem;
	font-size: 0.8rem;
	color: rgba(255, 255, 255, 0.6);
	margin-bottom: 1rem;
}

.single-breadcrumb a {
	color: rgba(255, 255, 255, 0.6);
	transition: var(--transition-fast);
}

.single-breadcrumb a:hover {
	color: var(--color-secondary);
}

.single-breadcrumb-current {
	color: var(--color-secondary);
	font-weight: 500;
	/* Limita o tamanho do titulo no breadcrumb */
	max-width: 20ch;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	display: inline-block;
}

.single-title {
	color: var(--color-text-on-dark);
	max-width: 800px;
	margin-bottom: 0.75rem;
}

.post-view-count {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	margin: 0 0 1rem;
	font-size: 0.88rem;
	font-weight: 700;
	line-height: 1.2;
	color: rgba(255, 255, 255, 0.78);
}

.post-view-count-dot {
	width: 0.5rem;
	height: 0.5rem;
	border-radius: var(--radius-full);
	background: var(--color-secondary);
	box-shadow: 0 0 0 4px rgba(246, 190, 71, 0.16);
}

.single-meta {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	font-size: 0.85rem;
	color: rgba(255, 255, 255, 0.6);
}

.single-book-featured {
	justify-self: end;
	display: block;
	width: min(100%, 400px);
	padding: clamp(0.85rem, 1.4vw, 1.25rem);
	border-radius: var(--radius-md);
	background: rgba(255, 255, 255, 0.14);
	box-shadow: 0 16px 34px rgba(0, 0, 0, 0.22);
	transform: rotate(2deg) translateY(-18px);
	transition: transform 240ms ease, background-color 240ms ease, box-shadow 240ms ease;
}

.single-book-featured img {
	width: 100%;
	aspect-ratio: 1 / 1;
	object-fit: contain;
	background: rgba(255, 255, 255, 0.88);
	border-radius: var(--radius-sm);
	margin: 0;
}

.single-book-featured:hover {
	background: rgba(255, 255, 255, 0.22);
	box-shadow: 0 20px 42px rgba(0, 0, 0, 0.28);
	transform: rotate(0deg) translateY(-26px) scale(1.03);
}

.single-article-featured:hover {
	box-shadow: 0 20px 42px rgba(0, 0, 0, 0.36);
	transform: rotate(0deg) translateY(-18px) scale(1.02);
}

/* Imagem destacada na hero — posts regulares (nao-biblioteca) */
.single-article-featured {
	justify-self: end;
	display: block;
	width: min(100%, 320px);
	padding: clamp(0.75rem, 1.2vw, 1rem);
	background: rgba(255, 255, 255, 0.60);
	border-radius: var(--radius-md);
	box-shadow: 0 16px 34px rgba(0, 0, 0, 0.32), 0 2px 8px rgba(0, 0, 0, 0.18);
	transform: rotate(-2deg) translateY(-10px);
	transition: transform 240ms ease, box-shadow 240ms ease;
	overflow: visible;
}

.single-article-featured img {
	width: 100%;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	border-radius: 0;
	border: none;
	margin: 0;
	display: block;
}

.single-meta-cat {
	background: var(--color-accent);
	color: var(--color-text-on-dark);
	padding: 0.15em 0.6em;
	border-radius: var(--radius-sm);
	font-weight: 600;
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.single-meta-sep {
	color: rgba(255, 255, 255, 0.3);
}

/* ============================================================
   AGREGAR A UN ESTUDIO (seleccion de texto, miembros logueados)
   ============================================================ */
.add-to-study-trigger {
	position: absolute;
	z-index: 40;
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	cursor: pointer;
	padding: 0.5em 0.85em;
	background: var(--color-primary);
	color: var(--color-text-on-dark);
	border: 0;
	border-radius: var(--radius-full, 999px);
	font: inherit;
	font-size: 0.82rem;
	font-weight: 700;
	box-shadow: var(--shadow-md);
	transition: var(--transition-fast);
}

.add-to-study-trigger:hover,
.add-to-study-trigger:focus-visible {
	background: var(--color-accent);
	outline: none;
}

.add-to-study-trigger .dashicons {
	font-size: 1rem;
	height: 1rem;
	width: 1rem;
}

.add-to-study-panel {
	position: absolute;
	z-index: 41;
	width: min(92vw, 340px);
	display: grid;
	gap: 0.75rem;
	padding: 1rem 1.1rem;
	background: #ffffff;
	color: var(--color-text-primary);
	border: 1px solid rgba(13, 35, 58, 0.14);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-md), 0 18px 40px rgba(0, 0, 0, 0.18);
}

.add-to-study-panel__excerpt {
	margin: 0;
	padding: 0 0 0 0.75rem;
	border-left: 3px solid var(--color-secondary);
	font-size: 0.9rem;
	font-style: italic;
	line-height: 1.5;
	max-height: 140px;
	overflow-y: auto;
	color: var(--color-primary);
}

.add-to-study-panel__existing {
	display: grid;
	gap: 0.4rem;
	max-height: 160px;
	overflow-y: auto;
	border: 0;
	padding: 0;
	margin: 0;
}

.add-to-study-panel__existing legend {
	color: var(--color-text-muted, #64748b);
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	padding: 0;
	margin-bottom: 0.15rem;
}

.add-to-study-panel__option {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	font-size: 0.88rem;
}

.add-to-study-panel__new {
	display: grid;
	gap: 0.35rem;
}

.add-to-study-panel__new span {
	color: var(--color-text-muted, #64748b);
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.add-to-study-panel__new input {
	background: #ffffff;
	border: 1px solid rgba(13, 35, 58, 0.2);
	border-radius: var(--radius-sm);
	color: var(--color-text-primary);
	font: inherit;
	padding: 0.55em 0.7em;
}

.add-to-study-panel__actions {
	display: flex;
	align-items: center;
	gap: 0.6rem;
}

.add-to-study-panel__close {
	margin-left: auto;
	background: transparent;
	border: 0;
	color: var(--color-text-muted, #64748b);
	cursor: pointer;
	font-size: 1.2rem;
	line-height: 1;
	padding: 0.2rem 0.4rem;
}

.add-to-study-panel__close:hover {
	color: var(--color-primary);
}

.add-to-study-panel__status {
	margin: 0;
	font-size: 0.8rem;
	font-weight: 600;
	min-height: 1em;
	color: #176b3a;
}

.add-to-study-panel__status.is-error {
	color: #9f1239;
}

/* En pantallas tactiles (movil/app), el menu nativo de seleccion del
   navegador/SO (Traducir/Copiar/Compartir, buscar con Google, etc.) ocupa
   justo el area cerca de la seleccion y a veces la parte inferior de la
   pantalla, tapando el boton/panel si los posicionamos ahi. Por eso se fijan
   en un lugar de la pantalla que esa UI nativa no suele tocar. */
.add-to-study-trigger--fixed {
	position: fixed;
	top: max(12px, env(safe-area-inset-top, 0px));
	left: 50%;
	right: auto;
	transform: translateX(-50%);
	z-index: 99999;
}

.add-to-study-panel--fixed {
	position: fixed;
	top: 50%;
	left: 50%;
	right: auto;
	transform: translate(-50%, -50%);
	max-height: 80vh;
	overflow-y: auto;
	z-index: 99999;
}

/* Tema oscuro: en este componente, --color-primary y --color-text-primary
   pasan a #ffffff (ver tokens.css), lo que dejaba texto blanco sobre el
   fondo blanco fijo del panel (invisible). Se fija una superficie propia
   con la paleta "Santuario Profundo" usada en el resto de los modales del
   plugin (fondo azul un poco mas claro que el fondo de la pagina). */
html[data-gpm-theme="dark"] .add-to-study-trigger {
	background: #fdba49;
	color: #281800;
	box-shadow: 0 10px 22px rgba(253, 186, 73, 0.18);
}

html[data-gpm-theme="dark"] .add-to-study-trigger:hover,
html[data-gpm-theme="dark"] .add-to-study-trigger:focus-visible {
	background: #ffd27a;
}

html[data-gpm-theme="dark"] .add-to-study-panel {
	background: #14202f;
	border-color: rgba(253, 186, 73, 0.18);
	box-shadow: 0 26px 70px rgba(0, 0, 0, 0.42);
	color: #d7e3f8;
}

html[data-gpm-theme="dark"] .add-to-study-panel__excerpt {
	color: #fdba49;
	border-left-color: #fdba49;
}

html[data-gpm-theme="dark"] .add-to-study-panel__existing legend,
html[data-gpm-theme="dark"] .add-to-study-panel__new span {
	color: #9fb0c9;
}

html[data-gpm-theme="dark"] .add-to-study-panel__new input {
	background: #101c2b;
	border-color: rgba(253, 186, 73, 0.28);
	color: #d7e3f8;
}

html[data-gpm-theme="dark"] .add-to-study-panel__close {
	color: #9fb0c9;
}

html[data-gpm-theme="dark"] .add-to-study-panel__close:hover {
	color: #fdba49;
}

html[data-gpm-theme="dark"] .add-to-study-panel__status {
	color: #6bd68f;
}

html[data-gpm-theme="dark"] .add-to-study-panel__status.is-error {
	color: #ff8fa3;
}

/* ============================================================
   LAYOUT DE 2 COLUNAS: CONTEUDO + SIDEBAR
   ============================================================ */
.single-layout {
	display: grid;
	grid-template-columns: 1fr 280px;
	gap: 3rem;
	align-items: start;
	padding-top: 3.5rem;
	padding-bottom: 4rem;
}

/* ============================================================
   CONTEUDO PRINCIPAL DO POST
   ============================================================ */
.single-content {
	min-width: 0; /* impede overflow do grid */
}

/* Estilos do conteudo inserido pelo editor (the_content) */
.wp-post-content {
	line-height: 1.85;
	color: var(--color-text-primary);
	overflow-wrap: break-word;
	word-break: break-word;
}

/* Elementos que costumam vir com largura fixa e causam overflow horizontal
   no mobile (empurrando o botao ÍNDICE fixed para fora da tela) */
.wp-post-content table {
	display: block;
	max-width: 100%;
	overflow-x: auto;
	border-collapse: collapse;
	border: 1px solid #9ca3af;
}

.wp-post-content table th,
.wp-post-content table td {
	border: 1px solid #9ca3af;
	padding: 4px;
}

.wp-post-content table th {
	background-color: #062547;
	color: #ffffff;
}

html[data-gpm-theme="dark"] .wp-post-content table,
html[data-gpm-theme="dark"] .wp-post-content table th,
html[data-gpm-theme="dark"] .wp-post-content table td {
	border-color: #ffffff;
}

.wp-post-content iframe,
.wp-post-content embed,
.wp-post-content object,
.wp-post-content video {
	max-width: 100%;
}

.wp-post-content pre {
	max-width: 100%;
	overflow-x: auto;
	white-space: pre-wrap;
	word-break: break-word;
}

.wp-post-content code {
	word-break: break-word;
}

.wp-post-content h2 {
	font-size: clamp(1.35rem, 3vw, 1.85rem);
	color: var(--color-primary);
	margin-top: 2.5rem;
	margin-bottom: 0.75rem;
	padding-top: 1rem; /* espaco para a ancora nao ficar atras do header fixo */
	scroll-margin-top: 100px;
}

.wp-post-content h3 {
	font-size: clamp(1.1rem, 2.5vw, 1.35rem);
	color: var(--color-primary);
	margin-top: 1.75rem;
	margin-bottom: 0.5rem;
	scroll-margin-top: 100px; /* espaco para a ancora nao ficar atras do header fixo */
}

.wp-post-content h1 {
	scroll-margin-top: 100px; /* espaco para a ancora nao ficar atras do header fixo, caso exista h1 no conteudo */
}

.wp-post-content p {
	margin-bottom: 1.25rem;
}

.wp-post-content ul,
.wp-post-content ol {
	padding-left: 1.5rem;
	margin-bottom: 1.25rem;
}

.wp-post-content li {
	margin-bottom: 0.4rem;
	color: var(--color-text-secondary);
}

.wp-post-content blockquote {
	position: relative;
	margin: clamp(2rem, 4vw, 3.5rem) 0 clamp(2rem, 4vw, 3.5rem) clamp(1rem, 2vw, 1.5rem);
	padding: clamp(3.5rem, 6vw, 4.5rem) clamp(1.5rem, 4vw, 3.25rem) clamp(1.5rem, 3vw, 3rem);
	border: 0;
	border-left: 9px solid #d8a12a;
	border-radius: 0 14px 14px 0;
	background: #fff4e2;
	color: #795c1f;
	font-style: italic;
	line-height: 1.5;
}

.wp-post-content blockquote::before {
	/* Aspas vetoriais decorativas embutidas no CSS, sem texto adicional no HTML. */
	position: absolute;
	top: clamp(1.15rem, 2vw, 1.5rem);
	left: clamp(1rem, 2.5vw, 1.75rem);
	width: clamp(1.925rem, 2.8vw, 2.625rem);
	aspect-ratio: 4 / 3;
	background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 48'%3E%3Cpath fill='%237d6a45' d='M0 48h24V24H12c0-6.6 5.4-12 12-12V0C10.7 0 0 10.7 0 24v24Zm40 0h24V24H52c0-6.6 5.4-12 12-12V0C50.7 0 40 10.7 40 24v24Z'/%3E%3C/svg%3E");
	content: "";
	pointer-events: none;
}

.wp-post-content blockquote p {
	color: inherit;
	font: inherit;
	margin: 0 !important;
}

.wp-post-content blockquote p + p {
	margin-top: 1.25rem !important;
}

.wp-post-content blockquote br + br {
	display: block;
	content: "";
	margin-top: 1.25rem;
}

@media (max-width: 768px) {
	.wp-post-content blockquote {
		border-left-width: 6px;
		border-radius: 0 10px 10px 0;
		line-height: 1.45;
	}
}

html[data-gpm-theme="dark"] .wp-post-content blockquote {
	background: #05234b;
	border-left-color: #004aad;
	color: #ffffff;
}

html[data-gpm-theme="dark"] .wp-post-content blockquote :is(p, cite) {
	color: #ffffff !important;
}

html[data-gpm-theme="dark"] .wp-post-content blockquote::before {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 48'%3E%3Cpath fill='%239eb6d5' d='M0 48h24V24H12c0-6.6 5.4-12 12-12V0C10.7 0 0 10.7 0 24v24Zm40 0h24V24H52c0-6.6 5.4-12 12-12V0C50.7 0 40 10.7 40 24v24Z'/%3E%3C/svg%3E");
}

.wp-post-content img {
	border-radius: var(--radius-md);
	margin: 1.5rem auto;
}

.wp-post-content a {
	color: var(--color-accent);
	text-decoration: none;
}

.wp-post-content a:hover {
	color: var(--color-accent-dark);
	text-decoration: none;
}

/* Tags */
.single-tags {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem;
	margin-top: 3rem;
	padding-top: 1.5rem;
	border-top: 1px solid var(--color-bg-surface);
}

.single-tags-label {
	font-size: 0.85rem;
	font-weight: 600;
	color: var(--color-text-muted);
	margin: 0;
}

.single-tag {
	display: inline-block;
	background: var(--color-bg-surface);
	color: var(--color-primary);
	font-size: 0.8rem;
	font-weight: 500;
	padding: 0.25em 0.75em;
	border-radius: var(--radius-full);
	border: 1px solid var(--color-primary);
	text-decoration: none;
	transition: var(--transition-fast);
}

.single-tags .single-tag:hover,
.single-tags .single-tag:focus-visible,
.wp-post-content .single-tags .single-tag:hover,
.wp-post-content .single-tags .single-tag:focus-visible {
	background: #062547;
	color: var(--color-text-on-dark);
	text-decoration: none;
}

/* Navegacao Anterior / Proximo */
.single-post-nav {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 1rem;
	margin-top: 2.5rem;
	padding-top: 1.5rem;
	border-top: 1px solid var(--color-bg-surface);
}

.single-post-nav-next {
	text-align: right;
}

.single-post-nav-label {
	display: block;
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	font-weight: 600;
	color: var(--color-text-muted);
	margin-bottom: 0.25rem;
}

.single-post-nav a {
	font-weight: 600;
	color: var(--color-primary);
	font-size: 0.9rem;
	transition: var(--transition-fast);
}

.single-post-nav a:hover {
	color: var(--color-accent);
}

/* ============================================================
   SIDEBAR: INDICE DE ANCORAS (TOC)
   ============================================================ */
.single-sidebar {
	position: sticky;
	top: 100px; /* abaixo do header fixo */
	max-height: calc(100vh - 120px);
	overflow-y: auto;
	/* Scrollbar fina e discreta */
	scrollbar-width: thin;
	scrollbar-color: var(--color-secondary) transparent;
}

.single-sidebar-featured {
	display: block;
	margin-bottom: 1rem;
	padding: 0.75rem;
	border-radius: var(--radius-md);
	background: var(--color-bg-light);
	box-shadow: var(--shadow-sm);
	transition: transform 240ms ease, box-shadow 240ms ease;
}

.single-sidebar-featured img {
	width: 100%;
	aspect-ratio: 1 / 1;
	object-fit: contain;
	background: var(--color-bg-surface);
	border-radius: var(--radius-sm);
	margin: 0;
}

.single-sidebar-featured:hover,
.single-sidebar-featured:focus-visible {
	transform: translateY(-4px);
	box-shadow: var(--shadow-md);
}

.single-sidebar::-webkit-scrollbar {
	width: 4px;
}

.single-sidebar::-webkit-scrollbar-thumb {
	background: var(--color-secondary);
	border-radius: var(--radius-full);
}

.toc-widget {
	background: var(--color-bg-light);
	border: 1px solid rgba(13, 35, 58, 0.12);
	border-radius: var(--radius-md);
	padding: 1.25rem;
	box-shadow: var(--shadow-sm);
}

.toc-widget-title {
	display: flex;
	align-items: center;
	width: calc(100% + 2.5rem);
	margin: -1.25rem -1.25rem 1rem;
	padding: 0.75rem 1rem;
	border-radius: var(--radius-md) var(--radius-md) 0 0;
	background: #062547;
	font-size: 0.7rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: var(--color-text-on-dark);
}

.toc-list {
	list-style: none;
	padding: 0;
	margin: 0;
	display: flex;
	flex-direction: column;
	gap: 0.35rem;
}

.toc-sublist {
	list-style: none;
	margin: 0.35rem 0 0;
	padding: 0 0 0 1.05rem;
	display: flex;
	flex-direction: column;
	gap: 0.25rem;
	border-left: 1px solid rgba(13, 35, 58, 0.1);
}

.toc-item.is-collapsed > .toc-sublist {
	display: none;
}

.toc-item-row {
	display: flex;
	align-items: flex-start;
	gap: 0.45rem;
}

.toc-list a {
	display: flex;
	align-items: flex-start;
	gap: 0.45rem;
	flex: 1;
	min-width: 0;
	font-size: 0.88rem;
	color: var(--color-text-secondary);
	line-height: 1.45;
	padding: 0.45rem 0.55rem;
	border-radius: var(--radius-sm);
	transition: var(--transition-fast);
	text-decoration: none;
}

.toc-list a::before {
	content: "";
	flex-shrink: 0;
	width: 0.45rem;
	height: 0.45rem;
	margin-top: 0.5rem;
	background: rgba(13, 35, 58, 0.28);
	border-radius: var(--radius-full);
	transition: background var(--transition-fast), transform var(--transition-fast);
}

.toc-item.has-children > .toc-item-row > a::before {
	display: none;
}

.toc-item.toc-level-2:not(.has-children) > .toc-item-row {
	position: relative;
}

.toc-item.toc-level-2:not(.has-children) > .toc-item-row > a::before {
	display: none;
}

.toc-item.toc-level-2:not(.has-children) > .toc-item-row::before {
	content: "";
	flex-shrink: 0;
	width: 1.45rem;
	height: 1.45rem;
	margin-top: 0.3rem;
	background: var(--color-bg-light);
	border: 1px solid rgba(13, 35, 58, 0.2);
	border-radius: var(--radius-full);
	transition: border-color var(--transition-fast);
}

.toc-item.toc-level-2:not(.has-children) > .toc-item-row::after {
	content: "";
	position: absolute;
	left: 0.515rem;
	top: 0.815rem;
	width: 0.42rem;
	height: 0.42rem;
	border-right: 2px solid var(--color-primary);
	border-bottom: 2px solid var(--color-primary);
	transform: rotate(45deg) translate(-1px, -1px);
	pointer-events: none;
}

.toc-item.toc-level-2:not(.has-children) > .toc-item-row:has(> a.is-active)::before {
	border-color: var(--color-accent);
}

.toc-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: 1.45rem;
	height: 1.45rem;
	margin-top: 0.3rem;
	border: 1px solid rgba(13, 35, 58, 0.2);
	border-radius: var(--radius-full);
	background: var(--color-bg-light);
	color: var(--color-primary);
	cursor: pointer;
	transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast), transform var(--transition-fast);
}

.toc-toggle::before {
	content: "";
	width: 0.42rem;
	height: 0.42rem;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg) translate(-1px, -1px);
}

.toc-item.is-collapsed > .toc-item-row > .toc-toggle::before {
	transform: rotate(-45deg) translate(-1px, 1px);
}

.toc-toggle:hover,
.toc-toggle:focus-visible {
	background: rgba(13, 35, 58, 0.06);
	border-color: var(--color-primary);
	outline: none;
}

.toc-level-1 > .toc-item-row > a {
	font-weight: 700;
	color: var(--color-primary);
}

.toc-level-2 > .toc-item-row > a {
	font-weight: 600;
}

.toc-level-3 > .toc-item-row > a {
	font-size: 0.82rem;
	color: var(--color-text-muted);
}

.toc-list a:hover,
.toc-list a.is-active {
	color: var(--color-primary);
	background: rgba(13, 35, 58, 0.05);
}

.toc-list a.is-active::before {
	background: var(--color-accent);
	transform: scale(1.25);
}

.toc-empty-msg {
	font-size: 0.85rem;
	color: var(--color-text-muted);
	margin: 0;
}

.see-also-widget {
	margin-top: 1rem;
	padding: 1.25rem;
	border: 1px solid rgba(13, 35, 58, 0.12);
	border-radius: var(--radius-md);
	background: var(--color-bg-light);
	box-shadow: var(--shadow-sm);
}

.see-also-title {
	margin-bottom: 1rem;
	font-size: 0.7rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: var(--color-accent);
}

.see-also-list {
	display: grid;
	gap: 0.8rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.see-also-list a {
	display: grid;
	grid-template-columns: 58px minmax(0, 1fr);
	gap: 0.75rem;
	align-items: center;
	text-decoration: none;
}

.see-also-list img {
	width: 58px;
	aspect-ratio: 1 / 1;
	object-fit: contain;
	border-radius: var(--radius-sm);
	background: var(--color-bg-surface);
}

.see-also-list span {
	font-size: 0.86rem;
	font-weight: 600;
	line-height: 1.35;
	color: var(--color-primary);
}

.see-also-list a:hover span {
	color: var(--color-accent);
}

/* ============================================================
   RESPONSIVIDADE
   ============================================================ */
@media (max-width: 900px) {
	.single-layout {
		grid-template-columns: 1fr;
	}

	.toc-widget {
		border-left: none;
	}
}

@media (max-width: 640px) {
	.single-hero {
		min-height: 340px;
	}

	.single-post-nav {
		grid-template-columns: 1fr;
	}

	.single-post-nav-next {
		text-align: left;
	}

	.single-breadcrumb-current {
		max-width: 15ch;
	}

	.single-hero-title-row {
		grid-template-columns: 1fr;
	}

	.single-hero--has-image .single-hero-title-row {
		grid-template-columns: 1fr;
	}

	.single-book-featured {
		justify-self: start;
		width: min(320px, 100%);
		transform: rotate(2deg) translateY(0);
	}

	.single-article-featured {
		justify-self: start;
		width: min(280px, 100%);
		transform: rotate(-1.5deg) translateY(0);
	}
}

/* ============================================================
   ORACIONES Y ALTA MAGIA: blockquote maior + sidebar VEA TAMBIÉN
   ============================================================ */

/* Blockquote com fonte 3pt (~4px) maior que o padrão */
.is-oraciones .wp-post-content blockquote p {
	font-size: calc(1em + 1pt);
}

/* Widget VEA TAMBIÉN — mesmo visual que .course-topics */
.vea-tambien-widget {
	border: 1px solid rgba(13, 35, 58, 0.12);
	border-radius: var(--radius-md);
	background: var(--color-bg-light);
	box-shadow: var(--shadow-sm);
	padding: 1.25rem;
}

.vea-tambien-title {
	display: inline-flex;
	margin-bottom: 1rem;
	padding: 0.35rem 0.7rem;
	border-radius: var(--radius-full);
	background: var(--color-primary);
	font-size: 0.7rem;
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: var(--color-text-on-dark);
}

.vea-tambien-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: 0.55rem;
}

.vea-tambien-list a {
	display: grid;
	grid-template-columns: 0.5rem 1fr;
	gap: 0.6rem;
	align-items: start;
	padding: 0.65rem;
	border-radius: var(--radius-sm);
	font-size: 0.92rem;
	font-weight: 600;
	line-height: 1.35;
	color: var(--color-text-secondary);
	text-decoration: none;
	transition: var(--transition-fast);
}

.vea-tambien-list a::before {
	content: "";
	display: block;
	width: 0.5rem;
	height: 0.5rem;
	margin-top: 0.35em;
	border-radius: 50%;
	background: var(--color-secondary);
	flex-shrink: 0;
	transition: var(--transition-fast);
}

.vea-tambien-list a:hover::before {
	background: var(--color-accent);
}

.vea-tambien-list a:hover {
	background: rgba(13, 35, 58, 0.06);
	color: var(--color-primary);
}

/* Modo escuro */
html[data-gpm-theme="dark"] .vea-tambien-widget {
	background: #14202f;
	border-color: rgba(253, 186, 73, 0.18);
}

html[data-gpm-theme="dark"] .vea-tambien-title {
	background: rgba(253, 186, 73, 0.18);
	color: #fdba49;
}

html[data-gpm-theme="dark"] .vea-tambien-list a {
	color: rgba(220, 231, 242, 0.85);
}

html[data-gpm-theme="dark"] .vea-tambien-list a:hover {
	background: rgba(253, 186, 73, 0.08);
	color: #ffffff;
}

html[data-gpm-theme="dark"] .vea-tambien-list a::before {
	background: #fdba49;
}
