/* Home */

.site-header {
	background-color: rgba(255, 255, 255, .95);
	backdrop-filter: blur(10px);
	padding: 1rem 2.75rem;
	position: sticky;
	top: 0;
	width: 100%;
	z-index: 100;
	border-bottom: 1px solid rgba(209, 179, 231, .2);
}

.header-inner {
	width: 100%;
	max-width: none;
	min-height: unset;
	margin: 0 auto;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.site-branding {
	font-family: 'Playfair Display', serif;
	font-size: 1.8rem;
	color: var(--ink);
	font-weight: 400;
	letter-spacing: .5px;
	text-transform: lowercase;
}

.primary-menu {
	gap: 0;
}

.primary-menu a {
	margin-left: 2rem;
	color: #9B8BB3;
	font-weight: 400;
	font-size: .9rem;
	transition: color .3s ease;
	letter-spacing: .3px;
}

.primary-menu a:hover, .primary-menu .current-menu-item a {
	color: var(--rose);
}

.hero {
	background: linear-gradient(135deg, var(--lavender) 0%, rgba(255, 255, 255, .8) 100%);
	text-align: center;
	padding: 8rem 2rem 6rem;
	/* Para reverter à altura dinâmica (baseada no conteúdo), adicione:
	   padding: 8rem 2rem 6rem;
	   e remova height/display/flex-direction/align-items/justify-content
	   deste seletor, além dos breakpoints "tablet" e mobile que setam
	   .hero { height: ... } mais abaixo neste arquivo. */
	/* padding: 0 2rem;
	height: 30rem;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center; */
	/* */
	position: relative;
	overflow: hidden;
	border-bottom: 1px solid var(--cream);
	box-shadow: 0 4px 15px rgba(167, 127, 195, .3);
}

.hero-image {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	opacity: 0.4;
	z-index: 0;
	object-fit: cover;
	/* object-fit: contain; */
}

.hero::before {
	content: '';
	position: absolute;
	top: 20%;
	right: 10%;
	width: 80px;
	height: 80px;
	background: radial-gradient(circle, rgba(255, 255, 255, .7) 0%, transparent 70%);
	border-radius: 50%;
	animation: hero-glow-float 5.5s ease-in-out infinite;
}

.hero::after {
	content: '';
	position: absolute;
	bottom: 30%;
	left: 15%;
	width: 60px;
	height: 60px;
	background: radial-gradient(circle, rgba(255, 255, 255, .5) 0%, transparent 70%);
	border-radius: 50%;
	animation: hero-glow-float 7s ease-in-out infinite reverse;
}

@keyframes hero-glow-float {
	0%, 100% {
		transform: translate(0, 0) scale(1);
		opacity: .7;
	}
	50% {
		transform: translate(-15px, 20px) scale(1.25);
		opacity: 1;
	}
}

.hero-sparkles {
	position: absolute;
	inset: 0;
	z-index: 1;
	pointer-events: none;
}

.sparkle {
	position: absolute;
	color: #fff;
	font-size: 1rem;
	line-height: 1;
	opacity: 0;
	text-shadow: 0 0 6px rgba(255, 255, 255, .9), 0 0 12px rgba(255, 255, 255, .5);
	animation: sparkle-twinkle 6s ease-in-out infinite;
}

.sparkle-1 { top: 15%; left: 8%; font-size: .8rem; animation-delay: 0s; }
.sparkle-2 { top: 25%; left: 85%; font-size: 1.2rem; animation-delay: 1.2s; }
.sparkle-3 { top: 55%; left: 20%; font-size: 1rem; animation-delay: 2.4s; }
.sparkle-4 { top: 70%; left: 78%; font-size: .9rem; animation-delay: 3.6s; }
.sparkle-5 { top: 40%; left: 50%; font-size: 1.2rem; animation-delay: 4.2s; }
.sparkle-6 { top: 12%; left: 60%; font-size: .7rem; animation-delay: 5s; }

@keyframes sparkle-twinkle {
	0%, 100% {
		opacity: 0;
		transform: scale(.6) rotate(0deg);
	}
	50% {
		opacity: 0.7;
		transform: scale(1.15) rotate(15deg);
	}
}

.hero h1 {
	font-family: 'Playfair Display', serif;
	font-size: clamp(2.5rem, 6vw, 4.5rem);
	max-width: none;
	margin: 0 0 1rem;
	color: var(--ink);
	font-weight: 400;
	line-height: 1.1;
	position: relative;
	z-index: 5;
}

.hero p {
	font-family: 'Dancing Script', cursive;
	font-size: clamp(1.2rem, 3vw, 1.8rem);
	color: var(--rose);
	max-width: 700px;
	margin: 0 auto 3rem;
	line-height: 1.7;
	position: relative;
	z-index: 5;
}

.hero-buttons {
	display: flex;
	gap: 1.5rem;
	justify-content: center;
	flex-wrap: wrap;
	margin-top: 2rem;
    position: relative;
    z-index: 5;
}

.button {
	padding: 1rem 2.5rem;
	font-size: .9rem;
	letter-spacing: .5px;
}

.featured-sections {
	max-width: 1400px;
	margin: 0 auto;
}

@media (min-width: 1025px) {
	.featured-sections {
		padding: 5rem 2rem 1.5rem 2rem;
	}

	.recent-works {
		padding: 5rem 3rem 4.5rem 3rem;
	}

	.recent-columns {
		margin-bottom: 1rem;
	}
}

.featured-title {
	font: 400 clamp(2rem, 4vw, 3rem)/1.2 'Playfair Display', serif;
	text-align: center;
	color: var(--ink);
	margin: 0 0 1rem;
}

.featured-subtitle {
	font: clamp(1.1rem, 2.5vw, 1.4rem)/1.4 'Dancing Script', cursive;
	text-align: center;
	color: var(--rose);
	margin: 0 auto 1rem;
	max-width: 600px;
}

.sections-scroller {
	overflow: hidden;
	width: 100vw;
	position: relative;
	left: 50%;
	margin-left: -50vw;
}

.sections-grid {
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	width: max-content;
	gap: 2rem;
	padding: 3rem 1rem 4rem;
	animation: sections-scroll 40s linear infinite;
}

.sections-grid.is-paused {
	animation-play-state: paused;
}

@keyframes sections-scroll {
	0% {
		transform: translateX(0);
	}
	100% {
		transform: translateX(-50%);
	}
}

.section-card {
	border: 0;
	border-radius: 25px;
	box-shadow: 0 10px 35px rgba(59, 35, 107, .08);
	transition: all .4s ease;
	display: flex;
	flex-direction: column;
	flex: 0 0 auto;
	width: 350px;
	height: 472px;
}

.section-card:hover {
	transform: translateY(-10px);
	box-shadow: 0 25px 50px rgba(59, 35, 107, .15);
}

.section-card::before {
	display: none;
}

.section-image {
	aspect-ratio: 4/3;
	overflow: hidden;
	position: relative;
}

.section-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .4s ease;
}

.section-card:hover .section-image img {
	transform: scale(1.08);
}

.section-icon {
	font-size: 3rem;
	color: white;
}

.section-content {
	padding: 2rem;
	display: flex;
	flex-direction: column;
	flex: 1;
}

.section-content h3 {
	font: 400 1.6rem/1.2 'Playfair Display', serif;
	color: var(--ink);
	margin: 0 0 1rem;
}

.section-content p {
	color: var(--muted);
	line-height: 1.7;
	margin: 0;
	font-size: 1rem;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* Abaixo do desktop o carrossel contínuo vira grade estática: em telas
   pequenas o movimento automático atrapalha mais do que ajuda, e o
   scroll horizontal por rolagem lateral não é natural no toque. Os
   cards clonados pelo JS (sections-carousel.js) pra criar o loop do
   marquee ficam escondidos aqui, já que a grade mostra só os reais. */
@media (max-width: 1024px) {
	.featured-subtitle {
		margin-bottom: 4rem;
	}

	.sections-scroller {
		width: 100%;
		position: static;
		left: auto;
		margin-left: 0;
		overflow: visible;
	}

	.sections-grid {
		display: grid;
		grid-template-columns: repeat(2, 1fr);
		width: auto;
		animation: none;
		padding: 0 1rem;
		gap: 1.5rem;
	}

	.section-card {
		width: auto;
	}

	.section-card[aria-hidden="true"] {
		display: none;
	}
}

@media (max-width: 600px) {
	.sections-grid {
		grid-template-columns: 1fr;
	}
}

/* Em monitores extremamente largos os 5 cards cabem numa única linha,
   então o marquee é desligado e vira uma fileira estática (mesma lógica
   do breakpoint mobile acima, só que com flex/nowrap para manter 1 linha). */
@media (min-width: 1900px) {
	.sections-scroller {
		width: 100%;
		position: static;
		left: auto;
		margin-left: 0;
		overflow: visible;
	}

	.sections-grid {
		display: flex;
		flex-wrap: nowrap;
		justify-content: center;
		width: auto;
		animation: none;
	}

	.section-card[aria-hidden="true"] {
		display: none;
	}
}

.section-link {
	color: var(--rose);
	text-decoration: none;
	font-weight: 500;
	font-size: .9rem;
	letter-spacing: .3px;
	transition: all .3s ease;
	position: relative;
	align-self: flex-start;
	margin-top: auto;
}

.section-link:hover {
	color: var(--ink);
}

.section-link::after {
	content: '→';
	margin-left: .5rem;
	transition: transform .3s ease;
}

.section-link:hover::after {
	transform: translateX(5px);
}

.recent-works {
	background: var(--cream);
	width: 100vw;
	position: relative;
	left: 50%;
	margin-left: -50vw;
	text-align: center;
}

.recent-title {
	font: 400 clamp(1.8rem, 3vw, 2.5rem)/1.2 'Playfair Display', serif;
	color: var(--ink);
	margin: 0 0 3rem;
}

.recent-columns {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 3rem;
	margin: 0 auto 3rem;
	max-width: 1400px;
	text-align: left;
}

@media (min-width: 1025px) {
	.recent-row {
		height: 96px;
	}
}

.recent-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	min-height: 96px;
	padding: 1rem;
	margin: 0 -1rem;
	border-radius: 0 0 0 0;
	border-bottom: 1px solid var(--line);
	background: transparent;
	text-decoration: none;
	transition: background-color .25s ease;
}

.recent-row:hover {
	background: #fff;
}

.recent-row-thumb {
	width: 64px;
	height: 64px;
	border-radius: 12px;
	overflow: hidden;
	flex-shrink: 0;
	position: relative;
}

.recent-row-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.recent-row-main {
	flex: 1;
	min-width: 0;
}

.recent-row-title {
	font: 500 1.05rem/1.3 'Playfair Display', serif;
	color: var(--ink);
	margin: 0 0 .3rem;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.recent-row-excerpt {
	color: var(--muted);
	font-size: .85rem;
	line-height: 1.4;
	margin: 0;
	display: -webkit-box;
	-webkit-line-clamp: 1;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.recent-row-meta {
	flex-shrink: 0;
	text-align: right;
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: .3rem;
}

.recent-row-tag {
	color: var(--rose);
	font-size: .75rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .5px;
}

.recent-row-date {
	color: var(--muted-light);
	font-size: .8rem;
}

@media (max-width: 1024px) {
	.recent-columns {
		grid-template-columns: 1fr;
		gap: 0rem;
	}
}

@media (max-width: 600px) {
	.section-content p {
		-webkit-line-clamp: 4;
	}

	.recent-columns {
		gap: 0;
	}

	.recent-row {
		flex-direction: column;
		align-items: flex-start;
		min-height: 0;
		padding: 1.15rem 1rem;
		gap: .3rem;
	}

	/* Some com o wrapper pra título e trecho virarem itens diretos de
	   .recent-row, aí dá pra posicionar cada um livremente (com `order` nas
	   linhas sem miniatura, ou como item de grid nas com miniatura) — como
	   .recent-row-meta é irmão de .recent-row-main no HTML, não dava pra
	   reorganizar só com CSS enquanto título/trecho ficavam agrupados
	   dentro de .recent-row-main. */
	.recent-row-main {
		display: contents;
	}

	.recent-row-title {
		padding-top: 0.15rem;
		order: 1;
	}

	.recent-row-meta {
		order: 2;
		flex-direction: row;
		align-items: center;
		text-align: left;
		gap: .6rem;
	}

	.recent-row-excerpt {
		order: 3;
	}

	/* Linhas com miniatura (coluna "Outros registros"): imagem à direita,
	   título e tag+data empilhados ao lado dela, trecho embaixo ocupando a
	   coluna de texto. row-gap igual ao gap de .recent-row (linha 438) pra
	   ficar com o mesmo espaçamento vertical da coluna de Textos. */
	.recent-row:has(.recent-row-thumb) {
		display: grid;
		grid-template-columns: 1fr 64px;
		grid-template-areas:
			"title   thumb"
			"meta    thumb"
			"excerpt .";
		column-gap: 1rem;
		row-gap: .3rem;
	}

	.recent-row:has(.recent-row-thumb) .recent-row-thumb {
		grid-area: thumb;
	}

	.recent-row:has(.recent-row-thumb) .recent-row-title {
		grid-area: title;
		margin: 0;
	}

	.recent-row:has(.recent-row-thumb) .recent-row-meta {
		grid-area: meta;
	}

	.recent-row:has(.recent-row-thumb) .recent-row-excerpt {
		grid-area: excerpt;
	}
}

.recent-item-overlay {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 60px;
	background: linear-gradient(45deg, var(--metanoia), var(--rose));
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	transform: translateY(100%);
	transition: opacity .3s ease, transform .3s ease;
}

.content-card:hover .recent-item-overlay, .poem-post:hover .recent-item-overlay {
	opacity: 1;
	transform: translateY(0);
}

.poem-search-card::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 4px;
	background: linear-gradient(90deg, var(--lavender), var(--metanoia));
	z-index: 1;
}

.poem-search-card .card-body {
	text-align: center;
	padding-top: 2rem;
}

.poem-search-meta {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: .75rem;
	flex-wrap: wrap;
	margin: 0 0 1rem;
	padding-bottom: 1rem;
	border-bottom: 1px solid var(--line);
}

.poem-search-date {
	font-size: .8rem;
	color: var(--muted-light);
}

.recent-item-overlay-text {
	color: #fff;
	font-size: .95rem;
	font-weight: 500;
	letter-spacing: .3px;
}

.featured-subtitle, .recent-title {
	position: relative;
}

.featured-subtitle::after, .recent-title::after {
	content: '';
	position: absolute;
	bottom: -24px;
	left: 50%;
	transform: translateX(-50%);
	width: 60px;
	height: 2px;
	background: linear-gradient(90deg, var(--metanoia), var(--lavender));
	border-radius: 2px;
}

.site-footer {
	background: linear-gradient(135deg, var(--ink) 0%, #2a1a4a 100%);
	color: white;
	padding: 3rem 2rem 2rem;
	text-align: center;
	margin-top: 0;
}

.footer-inner {
	max-width: 1200px;
	padding: 0;
	margin: 0 auto;
	color: var(--lavender);
	font-size: .9rem;
}

.site-search {
	background: #fff;
	padding: 2.3rem 2rem;
	text-align: center;
}

.site-search-inner {
	max-width: 600px;
	margin: 0 auto;
}

.site-search-form {
	display: flex;
	gap: .75rem;
	justify-content: center;
	flex-wrap: wrap;
}

.site-search-input {
	flex: 1;
	min-width: 220px;
	padding: 12px 20px;
	border: 2px solid var(--lavender);
	border-radius: 99px;
	font: inherit;
	font-size: .95rem;
	color: var(--ink);
	background: var(--paper);
}

.site-search-input:focus {
	outline: none;
	border-color: var(--rose);
}

.site-search-form .button {
	border: none;
}

@media (max-width: 520px) {
	.site-search {
		padding: 2.5rem 1.25rem;
	}
	.site-search-form {
		flex-direction: column;
	}
	.site-search-form .button {
		width: 100%;
	}
}

.screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.menu-toggle {
	display: none;
	background: none;
	border: none;
	padding: 8px;
	cursor: pointer;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
}

.menu-toggle span {
	display: block;
	width: 24px;
	height: 2px;
	background: var(--ink);
	border-radius: 2px;
	transition: transform .3s ease, opacity .3s ease;
}

.menu-toggle[aria-expanded="true"] span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:nth-child(2) {
	opacity: 0;
}

.menu-toggle[aria-expanded="true"] span:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 1024px) {
	.menu-toggle {
		display: flex;
	}
	.primary-menu {
		display: none;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		flex-direction: column;
		align-items: stretch;
		gap: 0;
		background: #fff;
		padding: .5rem 2rem 1.25rem;
		box-shadow: 0 15px 30px rgba(59, 35, 107, .12);
		border-radius: 0 0 20px 20px;
		white-space: normal;
		overflow-x: visible;
	}
	.primary-menu.is-open {
		display: flex;
	}
	.primary-menu a {
		display: block;
		margin: 0;
		padding: .5rem 0;
		font-size: .95rem;
		border-bottom: 1px solid var(--line);
	}
	.primary-menu li:last-child a {
		border-bottom: 0;
	}
	.primary-menu li:last-child {
		margin-left: 0;
	}
	.primary-menu li:not(:first-child):not(:last-child) {
		padding-left: 1rem;
	}
}

@media (max-width: 1024px) and (min-width: 769px) {
	.hero {
		height: 28rem;
	}
	.featured-sections {
		padding: 3rem 1.5rem 1.5rem 3rem ;
	}
	.recent-works {
		padding: 3.5rem 1.8rem 3.2rem 1.8rem ;
		margin-top: 2.5rem;
	}
	.recent-title {
		font-size: clamp(2rem, 4vw, 3rem);
	}
}

@media (max-width: 768px) {
	.recent-title {
		font-size: clamp(2rem, 4vw, 3rem);
	}
	.featured-subtitle {
		font-size: clamp(1.3rem, 4.25vw, 1.7rem);
	}
	.sparkle-2 {
		font-size: .9rem;
	}
	.site-header {
		padding: 0.3rem 1.25rem;
	}
	.header-inner {
		flex-direction: row;
		gap: .75rem;
		flex-wrap: nowrap;
	}
	.site-branding {
		font-size: 1.45rem;
	}
	.hero {
		/* height: 23rem;
		padding: 0 1rem; */
	}
	.hero p {
		font-size: clamp(1.4rem, 4vw, 1.8rem);
		line-height: 1.7;
	}
	.footer-credit {
		display: block;
	}
	.hero-buttons {
		flex-direction: column;
		align-items: center;
		gap: 1rem;
	}
	.button {
		width: 200px;
		text-align: center;
	}
	.hero-buttons .button, .recent-works > .button {
		width: 100%;
	}
	.featured-sections {
		padding: 4rem 1rem;
	}
	.recent-works {
		padding: 4rem 1rem;
		margin-top: 0.5rem;
	}
}

@media (max-width: 480px) {
	.poems .section {
		padding: 3rem 1rem;
	}
}

@media (max-width: 800px) {
	.header-inner {
		flex-direction: row;
		flex-wrap: nowrap;
	}
}

