/* =====================================================================
   CUENTOS DEL BOSQUE — gabrielaormaza.com
   TODO namespaceado bajo .cuentos-custom (no choca con Blocksy/Stackable).
   Misma familia estética que Inicio/Terapias/Ceremonias/Servicios, con dos
   diferencias propias de esta página: los fondos ilustrados del cuento
   (bosque y luciérnagas) y el marco de la ficha técnica.
   Fuentes: Poppins (cuerpo) · Cormorant Garamond (títulos) · Great Vibes (título del cuento).
   ===================================================================== */

.cuentos-custom {
	/* ---- Paleta compartida con las otras plantillas ---- */
	--cue-bg:       #0e0819;
	--cue-ink:      #f4eefc;
	--cue-text:     rgba(244, 238, 252, .80);
	--cue-soft:     rgba(244, 238, 252, .56);
	--cue-lila:     #bda7cc;
	--cue-lavanda:  #cdb8ec;
	--cue-violeta:  #9a7be0;
	--cue-rosa:     #e7b3d6;
	--cue-turquesa: #a9e2df;
	--cue-oro:      #e6c88c;
	--cue-verde:    #8fc79a;   /* propio de esta página: el bosque */
	--cue-line:     rgba(189, 167, 204, .26);
	--cue-radius:   20px;

	--cue-serif:  "Cormorant Garamond", Georgia, "Times New Roman", serif;
	--cue-script: "Great Vibes", "Cormorant Garamond", cursive;
	--cue-sans:   "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

	position: relative;
	isolation: isolate;
	overflow: hidden;
	color: var(--cue-text);
	font-family: var(--cue-sans);
	font-weight: 300;
	font-size: 17px;
	line-height: 1.9;
	letter-spacing: .01em;
	font-variant-numeric: lining-nums;   /* si no, "44" y "20 × 20" se ven raros */

	background:
		radial-gradient(88% 40% at 78% 6%,  rgba(154, 123, 224, .30) 0%, transparent 55%),
		radial-gradient(76% 36% at 12% 24%, rgba(143, 199, 154, .12) 0%, transparent 55%),
		radial-gradient(92% 44% at 86% 50%, rgba(132, 98, 216, .26) 0%, transparent 56%),
		radial-gradient(70% 34% at 10% 68%, rgba(169, 226, 223, .10) 0%, transparent 55%),
		radial-gradient(92% 46% at 60% 90%, rgba(189, 167, 204, .16) 0%, transparent 55%),
		linear-gradient(180deg, #110b22 0%, #1b1038 34%, #170d30 62%, #14092a 85%, #100a1e 100%);
	background-color: var(--cue-bg);
}

/* Reset acotado */
.cuentos-custom *,
.cuentos-custom *::before,
.cuentos-custom *::after { box-sizing: border-box; }
.cuentos-custom img { display: block; max-width: 100%; height: auto; }
.cuentos-custom p,
.cuentos-custom ul,
.cuentos-custom ol,
.cuentos-custom dl,
.cuentos-custom dd,
.cuentos-custom figure,
.cuentos-custom blockquote { margin: 0; padding: 0; }
.cuentos-custom li { list-style: none; }

.cuentos-custom .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;
}

/* ---- Polvo estelar (SVG tileable, muy liviano) ---- */
.cuentos-custom .cue-stars {
	position: absolute;
	inset: 0;
	z-index: 0;
	pointer-events: none;
	opacity: .5;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cg fill='%23ffffff'%3E%3Ccircle cx='18' cy='36' r='1' opacity='.9'/%3E%3Ccircle cx='120' cy='18' r='.7' opacity='.5'/%3E%3Ccircle cx='210' cy='54' r='1.1' opacity='.8'/%3E%3Ccircle cx='72' cy='96' r='.6' opacity='.45'/%3E%3Ccircle cx='168' cy='120' r='.9' opacity='.7'/%3E%3Ccircle cx='240' cy='150' r='.7' opacity='.5'/%3E%3Ccircle cx='30' cy='168' r='1' opacity='.75'/%3E%3Ccircle cx='108' cy='198' r='.7' opacity='.5'/%3E%3Ccircle cx='198' cy='216' r='1' opacity='.8'/%3E%3Ccircle cx='138' cy='246' r='.6' opacity='.4'/%3E%3Ccircle cx='60' cy='240' r='.8' opacity='.55'/%3E%3C/g%3E%3C/svg%3E");
}

/* =====================================================================
   Estructura
   ===================================================================== */
.cuentos-custom .cue-section { position: relative; z-index: 1; padding-block: 84px; }
.cuentos-custom .cue-wrap {
	width: 100%;
	max-width: 1120px;
	margin-inline: auto;
	padding-inline: 24px;
	position: relative;
	z-index: 1;
}
.cuentos-custom .cue-narrow { max-width: 760px; margin-inline: auto; }
.cuentos-custom .cue-center { text-align: center; }

/* Dos columnas imagen + texto */
.cuentos-custom .cue-split {
	display: grid;
	grid-template-columns: minmax(0, .9fr) minmax(0, 1fr);
	gap: 56px;
	align-items: center;
}
.cuentos-custom .cue-split--reverse > .cue-figure { order: 2; }
.cuentos-custom .cue-split__text > * + * { margin-top: 18px; }

/* =====================================================================
   Tipografía
   ===================================================================== */
.cuentos-custom .cue-h2 {
	font-family: var(--cue-serif);
	font-weight: 500;
	font-size: clamp(28px, 3.6vw, 42px);
	line-height: 1.16;
	color: var(--cue-ink);
	letter-spacing: .005em;
	text-wrap: balance;
	margin-bottom: 20px;
}
.cuentos-custom .cue-titulo-script {
	font-family: var(--cue-script);
	font-size: clamp(38px, 5.2vw, 58px);
	font-weight: 400;
	line-height: 1.2;
	color: var(--cue-oro);
	margin-bottom: 12px;
	padding-bottom: .1em;   /* aire para los rasgos descendentes de la cursiva */
	text-wrap: balance;
}
.cuentos-custom .cue-lead { margin-bottom: 16px; }
.cuentos-custom .cue-lead strong { color: var(--cue-ink); font-weight: 500; }
.cuentos-custom .cue-lead em,
.cuentos-custom .cue-hero__lema em { font-style: italic; }

.cuentos-custom .cue-destacado {
	font-family: var(--cue-serif);
	font-size: clamp(20px, 2.3vw, 25px);
	font-style: italic;
	line-height: 1.5;
	color: var(--cue-lavanda);
	text-wrap: balance;
	margin-top: 22px;
}

/* =====================================================================
   Bloque 1 — Portada del bosque
   ===================================================================== */
.cuentos-custom .cue-hero {
	position: relative;
	z-index: 1;
	overflow: hidden;
	padding-block: 110px 96px;
	text-align: center;
}
.cuentos-custom .cue-hero__fondo {
	position: absolute;
	inset: 0;
	z-index: 0;
	/* Se desvanece por abajo con máscara. Antes lo tapaba un degradado
	   oscuro que NO coincidía exactamente con el fondo de la página y
	   dejaba una costura horizontal visible. Con máscara desaparece la
	   imagen y se ve el fondo real: no hay borde posible. */
	-webkit-mask-image: linear-gradient(180deg, #000 0%, #000 82%, transparent 100%);
	        mask-image: linear-gradient(180deg, #000 0%, #000 82%, transparent 100%);
}
.cuentos-custom .cue-hero__fondo img {
	width: 100%; height: 100%;
	object-fit: cover;
	object-position: center;
	opacity: .9;
}
/* Velo: el bosque respira en los bordes y se oscurece detrás del texto */
.cuentos-custom .cue-hero__fondo::after {
	content: "";
	position: absolute;
	inset: 0;
	background: radial-gradient(66% 60% at 50% 44%, rgba(14, 8, 25, .76) 0%, rgba(14, 8, 25, .44) 100%);
}
.cuentos-custom .cue-hero__titulo {
	font-family: var(--cue-serif);
	font-weight: 500;
	font-size: clamp(32px, 5vw, 56px);
	line-height: 1.14;
	color: var(--cue-ink);
	text-wrap: balance;
	margin: 0 0 18px;
	text-shadow: 0 4px 26px rgba(8, 4, 20, .8);
}
.cuentos-custom .cue-hero__lema {
	font-family: var(--cue-serif);
	font-style: italic;
	font-size: clamp(19px, 2.3vw, 25px);
	line-height: 1.4;          /* si no, hereda el 1.9 del cuerpo y se desarma */
	color: var(--cue-lavanda);
	text-wrap: balance;
	margin-bottom: 34px;
}

/* Las tres líneas de cierre del bloque 1 */
.cuentos-custom .cue-triada {
	margin-top: 34px;
	padding: 28px 24px;
	border-top: 1px solid var(--cue-line);
	border-bottom: 1px solid var(--cue-line);
	font-family: var(--cue-serif);
	font-size: clamp(19px, 2.2vw, 24px);
	font-style: italic;
	line-height: 1.7;
	color: var(--cue-oro);
	text-wrap: balance;
}
.cuentos-custom .cue-triada p + p { margin-top: 8px; }

/* =====================================================================
   Bloque 2 — La Fuente de Amor Infinito (fondo de luciérnagas)
   ===================================================================== */
.cuentos-custom .cue-cuento { position: relative; overflow: hidden; padding-block: 96px; }
.cuentos-custom .cue-cuento__fondo {
	position: absolute;
	inset: 0;
	z-index: 0;
	-webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 12%, #000 88%, transparent 100%);
	        mask-image: linear-gradient(180deg, transparent 0%, #000 12%, #000 88%, transparent 100%);
}
.cuentos-custom .cue-cuento__fondo img {
	width: 100%; height: 100%;
	object-fit: cover;
	object-position: center;
	opacity: .85;
}
.cuentos-custom .cue-cuento__fondo::after {
	content: "";
	position: absolute;
	inset: 0;
	/* Más oscuro a la derecha, que es donde va el texto. El desvanecido
	   de arriba y abajo lo hace la máscara del contenedor. */
	background: linear-gradient(260deg, rgba(14, 8, 25, .86) 0%, rgba(14, 8, 25, .70) 34%, rgba(14, 8, 25, .26) 62%, rgba(14, 8, 25, .34) 100%);
}

/* =====================================================================
   Imágenes
   ===================================================================== */
.cuentos-custom .cue-figure {
	position: relative;
	border-radius: var(--cue-radius);
	overflow: hidden;
	box-shadow: 0 24px 60px rgba(8, 4, 20, .6);
}
.cuentos-custom .cue-figure::after {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	border-radius: inherit;
	box-shadow: inset 0 0 0 1px var(--cue-line);
}
.cuentos-custom .cue-figure--soft { border-radius: 26px; }

/* =====================================================================
   Bloque 3 — Los tres símbolos
   ===================================================================== */
.cuentos-custom .cue-simbolos {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 26px;
	margin-top: 44px;
}
.cuentos-custom .cue-simbolo {
	background: rgba(255, 255, 255, .045);
	border: 1px solid var(--cue-line);
	border-radius: var(--cue-radius);
	padding: 30px 26px;
}
.cuentos-custom .cue-simbolo__icono {
	display: block;
	font-size: 28px;
	line-height: 1;
	color: var(--cue-oro);
	margin-bottom: 14px;
}
.cuentos-custom .cue-simbolo__titulo {
	font-family: var(--cue-serif);
	font-size: 24px;
	font-weight: 500;
	line-height: 1.25;
	color: var(--cue-ink);
	margin: 0 0 10px;
}
.cuentos-custom .cue-simbolo p { font-size: 16px; line-height: 1.8; }

/* =====================================================================
   Bloque 5 — Ficha técnica dentro del marco ilustrado
   ===================================================================== */
.cuentos-custom .cue-marco {
	position: relative;
	max-width: 620px;
	margin-inline: auto;
}
.cuentos-custom .cue-marco > img {
	width: 100%;
	border-radius: 14px;
}
/* El texto va encima del centro morado del marco, sin tapar los bordes
   ilustrados (de ahí el recuadro interior en porcentajes). */
.cuentos-custom .cue-marco__contenido {
	position: absolute;
	inset: 13% 12% 12%;
	display: flex;
	flex-direction: column;
	justify-content: center;
	text-align: center;
}
.cuentos-custom .cue-marco__titulo {
	font-family: var(--cue-serif);
	font-size: clamp(24px, 3vw, 34px);
	font-weight: 500;
	color: var(--cue-ink);
	margin: 0 0 clamp(12px, 2.4vw, 24px);
}
/* Enumeración: NO se centra el contenido, se alinea en dos columnas */
.cuentos-custom .cue-ficha { text-align: left; }
.cuentos-custom .cue-ficha > div + div { margin-top: clamp(6px, 1.4vw, 14px); }
.cuentos-custom .cue-ficha dt {
	font-size: clamp(10px, 1.15vw, 12px);
	font-weight: 500;
	letter-spacing: .22em;
	text-transform: uppercase;
	color: var(--cue-lila);
	line-height: 1.5;
}
.cuentos-custom .cue-ficha dd {
	font-size: clamp(13px, 1.5vw, 17px);
	line-height: 1.5;
	color: var(--cue-ink);
}

/* =====================================================================
   Bloque 6 — Este cuento puede ser para ti si…
   ===================================================================== */
.cuentos-custom .cue-checklist {
	max-width: 40em;
	margin: 30px auto 34px;
	text-align: left;     /* las enumeraciones no se centran */
}
.cuentos-custom .cue-checklist li {
	position: relative;
	padding-left: 34px;
	margin-bottom: 14px;
}
.cuentos-custom .cue-checklist li::before {
	content: "\2726";     /* ✦ */
	position: absolute;
	left: 4px;
	top: 0;
	color: var(--cue-oro);
	font-size: 15px;
	line-height: 1.9;
}

/* =====================================================================
   Bloque 7 — La colección
   ===================================================================== */
.cuentos-custom .cue-coleccion {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 30px;
	max-width: 880px;
	margin: 46px auto 0;
	align-items: stretch;
}
.cuentos-custom .cue-tomo {
	display: flex;
	flex-direction: column;
	text-decoration: none;
	color: inherit;
	background: rgba(255, 255, 255, .045);
	border: 1px solid var(--cue-line);
	border-radius: var(--cue-radius);
	overflow: hidden;
	transition: transform .3s ease, box-shadow .3s ease;
}
a.cuentos-custom .cue-tomo:hover,
.cuentos-custom a.cue-tomo:hover,
.cuentos-custom a.cue-tomo:focus-visible {
	transform: translateY(-4px);
	box-shadow: 0 22px 50px rgba(8, 4, 20, .55);
}
.cuentos-custom .cue-tomo__figura { margin: 0; }
.cuentos-custom .cue-tomo__figura img {
	width: 100%;
	aspect-ratio: 1 / 1;
	object-fit: cover;
}
.cuentos-custom .cue-tomo__pie { padding: 22px 24px 26px; text-align: center; }
.cuentos-custom .cue-tomo__nombre {
	font-family: var(--cue-serif);
	font-size: 23px;
	line-height: 1.3;
	color: var(--cue-ink);
	text-wrap: balance;
	margin-bottom: 8px;
}
.cuentos-custom .cue-tomo__estado {
	font-size: 11px;
	font-weight: 500;
	letter-spacing: .24em;
	text-transform: uppercase;
	color: var(--cue-turquesa);
}
.cuentos-custom .cue-tomo--proximo .cue-tomo__estado { color: var(--cue-soft); }

/* La segunda tarjeta no es un hueco vacío: es una pieza ilustrada en CSS
   (brotes creciendo en el bosque). Cero peso de descarga. */
.cuentos-custom .cue-tomo__brotes {
	aspect-ratio: 1 / 1;
	position: relative;
	background:
		radial-gradient(52% 42% at 26% 22%, rgba(143, 199, 154, .30) 0%, transparent 60%),
		radial-gradient(48% 40% at 78% 34%, rgba(169, 226, 223, .22) 0%, transparent 60%),
		radial-gradient(60% 46% at 50% 96%, rgba(143, 199, 154, .34) 0%, transparent 62%),
		linear-gradient(180deg, #17102e 0%, #1d1440 52%, #14102c 100%);
}
.cuentos-custom .cue-tomo__brotes::after {
	content: "";
	position: absolute;
	inset: 0;
	background-repeat: no-repeat;
	background-position: center 62%;
	background-size: 62% auto;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200' fill='none' stroke='%23e6c88c' stroke-width='1.6' stroke-linecap='round'%3E%3Cpath d='M100 190V96' opacity='.85'/%3E%3Cpath d='M100 128c-16-4-27-16-30-33 17 1 28 12 30 33Z' opacity='.7'/%3E%3Cpath d='M100 112c15-5 25-18 27-35-17 2-27 14-27 35Z' opacity='.7'/%3E%3Cpath d='M100 156c-13-3-22-13-24-27 14 1 23 10 24 27Z' opacity='.5'/%3E%3Cg stroke='%23a9e2df'%3E%3Cpath d='M62 74l4-10 4 10 10 4-10 4-4 10-4-10-10-4z' opacity='.85'/%3E%3Cpath d='M140 52l3-8 3 8 8 3-8 3-3 8-3-8-8-3z' opacity='.7'/%3E%3Cpath d='M150 108l2.5-6 2.5 6 6 2.5-6 2.5-2.5 6-2.5-6-6-2.5z' opacity='.55'/%3E%3C/g%3E%3Cg stroke='none' fill='%23ffffff'%3E%3Ccircle cx='48' cy='120' r='1.6' opacity='.75'/%3E%3Ccircle cx='168' cy='84' r='1.4' opacity='.6'/%3E%3Ccircle cx='84' cy='42' r='1.5' opacity='.7'/%3E%3Ccircle cx='126' cy='168' r='1.3' opacity='.5'/%3E%3C/g%3E%3C/svg%3E");
}

/* =====================================================================
   Bloque 8 — Cita de cierre
   ===================================================================== */
.cuentos-custom .cue-cierre { padding-bottom: 96px; }
.cuentos-custom .cue-cita {
	text-align: center;
	padding: 40px 28px;
	border-top: 1px solid var(--cue-line);
	border-bottom: 1px solid var(--cue-line);
	position: relative;
}
.cuentos-custom .cue-cita::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: radial-gradient(70% 120% at 50% 50%, rgba(154, 123, 224, .16) 0%, transparent 70%);
}
.cuentos-custom .cue-cita p {
	font-family: var(--cue-serif);
	font-size: clamp(22px, 3vw, 32px);
	font-style: italic;
	line-height: 1.45;
	color: var(--cue-ink);
	text-wrap: balance;
	margin-bottom: 18px;
}
.cuentos-custom .cue-cita footer {
	font-family: var(--cue-script);
	font-size: clamp(24px, 2.8vw, 32px);
	color: var(--cue-oro);
	padding-bottom: .12em;
}

/* =====================================================================
   Botones
   ===================================================================== */
.cuentos-custom .cue-btn {
	display: inline-block;
	font-family: var(--cue-sans);
	font-size: 15px;
	font-weight: 500;
	letter-spacing: .06em;
	line-height: 1.3;
	text-decoration: none;
	text-align: center;
	color: #170e2b;
	background: linear-gradient(135deg, var(--cue-lavanda) 0%, var(--cue-rosa) 55%, var(--cue-oro) 100%);
	border: 0;
	border-radius: 999px;
	padding: 15px 34px;
	cursor: pointer;
	transition: transform .3s ease, box-shadow .3s ease, filter .3s ease;
	box-shadow: 0 10px 30px rgba(154, 123, 224, .35);
}
.cuentos-custom .cue-btn:hover,
.cuentos-custom .cue-btn:focus-visible {
	transform: translateY(-2px);
	filter: brightness(1.06);
	box-shadow: 0 16px 40px rgba(154, 123, 224, .5);
	color: #170e2b;
}
.cuentos-custom .cue-btn--grande { padding: 18px 44px; font-size: 16px; }

/* =====================================================================
   Centrado: el texto narrativo va centrado, las enumeraciones no
   ===================================================================== */
.cuentos-custom .cue-split__text { text-align: center; }
.cuentos-custom .cue-lead,
.cuentos-custom .cue-destacado { max-width: 56ch; margin-inline: auto; }
.cuentos-custom .cue-h2,
.cuentos-custom .cue-titulo-script { max-width: 24ch; margin-inline: auto; }
.cuentos-custom .cue-hero__titulo { max-width: 18ch; margin-inline: auto; }
.cuentos-custom .cue-hero__lema { max-width: 34ch; margin-inline: auto; }

/* =====================================================================
   Reveal al scroll
   Por defecto TODO es visible. Solo se oculta si hay JS (.cue-js),
   así que si el JS falla la página se ve igual.
   ===================================================================== */
.cue-js .cuentos-custom .cue-reveal {
	opacity: 0;
	transform: translateY(22px);
}
.cue-js .cuentos-custom .cue-reveal.is-in {
	opacity: 1;
	transform: none;
	transition:
		opacity .85s cubic-bezier(.22,.68,.35,1) calc(var(--cue-i, 0) * 90ms),
		transform .85s cubic-bezier(.22,.68,.35,1) calc(var(--cue-i, 0) * 90ms);
}

@media (prefers-reduced-motion: reduce) {
	.cue-js .cuentos-custom .cue-reveal { opacity: 1; transform: none; }
	.cuentos-custom .cue-btn,
	.cuentos-custom .cue-tomo { transition: none; }
}

/* =====================================================================
   Responsive
   ===================================================================== */
@media (max-width: 900px) {
	.cuentos-custom { font-size: 16px; }
	.cuentos-custom .cue-section { padding-block: 60px; }
	.cuentos-custom .cue-hero { padding-block: 76px 64px; }
	.cuentos-custom .cue-cuento { padding-block: 70px; }

	.cuentos-custom .cue-split {
		grid-template-columns: minmax(0, 1fr);
		gap: 30px;
	}
	.cuentos-custom .cue-split--reverse > .cue-figure { order: 0; }
	.cuentos-custom .cue-split > .cue-figure { max-width: 420px; margin-inline: auto; }

	.cuentos-custom .cue-simbolos { grid-template-columns: minmax(0, 1fr); gap: 18px; }

	/* En móvil el fondo del cuento se oscurece parejo: ya no hay columna
	   "clara" a un lado porque todo se apila. */
	.cuentos-custom .cue-cuento__fondo::after {
		background: linear-gradient(180deg, rgba(14, 8, 25, .30) 0%, rgba(14, 8, 25, .52) 34%, rgba(14, 8, 25, .84) 100%);
	}
}

@media (max-width: 720px) {
	/* El marco ilustrado no da de sí para tanto texto en pantalla chica:
	   se muestra la ficha en una caja propia y el marco se deja aparte. */
	.cuentos-custom .cue-marco > img { display: none; }
	.cuentos-custom .cue-marco__contenido {
		position: static;
		inset: auto;
		padding: 32px 24px;
		border: 1px solid var(--cue-line);
		border-radius: var(--cue-radius);
		background:
			radial-gradient(80% 60% at 50% 0%, rgba(154, 123, 224, .22) 0%, transparent 70%),
			rgba(255, 255, 255, .045);
	}
	.cuentos-custom .cue-ficha dt { font-size: 11px; }
	.cuentos-custom .cue-ficha dd { font-size: 16px; }
}

@media (max-width: 560px) {
	.cuentos-custom .cue-wrap { padding-inline: 20px; }
	.cuentos-custom .cue-triada { padding: 24px 14px; }
	.cuentos-custom .cue-cita { padding: 30px 16px; }
	.cuentos-custom .cue-coleccion { grid-template-columns: minmax(0, 1fr); gap: 20px; }
	.cuentos-custom .cue-btn { width: 100%; }
}
