/*
Theme Name: Les Euphoribes
Theme URI: https://leseuphoribes.fr
Author: Les Euphoribes
Author URI: https://leseuphoribes.fr
Description: Thème WordPress autonome pour l'association Les Euphoribes. Mobile-first, basé sur Tailwind CSS et shadcn/ui. Reproduit l'identité visuelle du site (vert #69b04c, rose #ec008c) sans dépendre de The7 ni de Visual Composer.
Version: 0.1.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: euphoribes
Tags: custom-menu, featured-images, threaded-comments, translation-ready, custom-logo, mobile-first
*/

/*
 * Les styles du thème sont compilés via Tailwind CSS dans `tailwind.css`.
 * Ce fichier sert uniquement à l'identification du thème par WordPress
 * et à fournir un point d'extension CSS minimal pour les overrides spécifiques
 * qui ne tiendraient pas dans Tailwind.
 */

/* =============================================
   FICHE ÉVÉNEMENT — single-evenement.php
   Le contenu rendu par the_content() est inséré dans .evs-content.
============================================= */
.evs-content h2 {
	margin-top: 20px;
	margin-bottom: 5px;
}
.evs-content h3 {
	margin-top: 16px;
	margin-bottom: 4px;
}
.evs-content > h2:first-child,
.evs-content > h3:first-child {
	margin-top: 0;
}


/* =============================================
   PAGES STATIQUES — typographie riche
   Le contenu the_content() des pages page.php est wrappé dans .eup-page-content.
   Tout ce qu'on style ici prend précédence sur les utilities Tailwind appliquées
   en page.php — ces règles définissent le langage typographique du contenu.

   Couvre : titres, paragraphes, drop cap, liens, gras/em, listes (puces & numérotées),
   citations, images (effet « pochoir » sticker), boutons inline, tables, hr décoratif,
   callouts (aside / .callout), code, video.
============================================= */

.eup-page-content {
	color: #334155;
	font-size: 1rem;
	line-height: 1.75;
	overflow: visible;
}

/* clearfix pour les images flottées */
.eup-page-content::after {
	content: '';
	display: block;
	clear: both;
}

/* ----- Titres ----- */
.eup-page-content > h1 { display: none; } /* le H1 est dans le hero */

.eup-page-content h2 {
	font-family: 'Cabinet Grotesk', 'Inter', ui-sans-serif, system-ui, sans-serif;
	font-weight: 800;
	font-size: clamp(1.4rem, 2.4vw, 1.875rem);
	color: #4f8c39; /* vert-dark */
	letter-spacing: -0.01em;
	line-height: 1.2;
	margin: 2rem 0 0.5rem;
	padding-left: 1rem;
	position: relative;
	scroll-margin-top: 6rem;
}
.eup-page-content h2::before {
	content: '';
	position: absolute;
	left: 0;
	top: 0.4rem;
	bottom: 0.4rem;
	width: 6px;
	border-radius: 9999px;
	background: linear-gradient(to bottom, #69b04c 0%, #ec008c 100%);
}

.eup-page-content h3 {
	font-family: 'Cabinet Grotesk', 'Inter', ui-sans-serif, system-ui, sans-serif;
	font-weight: 700;
	font-size: clamp(1.15rem, 2vw, 1.4rem);
	color: #b8006e; /* rose-dark */
	margin: 1.5rem 0 0.25rem;
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.eup-page-content h4 {
	font-family: 'Cabinet Grotesk', 'Inter', ui-sans-serif, system-ui, sans-serif;
	font-weight: 700;
	font-size: 1.1rem;
	color: #1a1a2e;
	margin: 1.25rem 0 0.25rem;
}

/* ----- Paragraphes ----- */
.eup-page-content p {
	margin: 0.875rem 0;
	line-height: 1.75;
}

.eup-page-content > p:first-of-type {
	font-size: 1.0625rem;
	color: #475569;
	margin-top: 0;
}

/* Drop cap — première lettre du tout premier paragraphe.
   Effet « lettrine de carnet de bord », inspiré des éditions illustrées. */
.eup-page-content > p:first-of-type::first-letter {
	font-family: 'Cabinet Grotesk', Georgia, serif;
	font-weight: 800;
	font-size: 4rem;
	line-height: 0.85;
	color: #ec008c;
	float: left;
	margin: 0.4rem 0.7rem 0 0;
	padding: 0.35rem 0.55rem;
	background: linear-gradient(135deg, #fff5fb 0%, #f5fff0 100%);
	border-radius: 0.75rem;
	border: 1px solid rgba(236, 0, 140, 0.18);
	box-shadow: 0 2px 6px rgba(236, 0, 140, 0.10);
}

/* ----- Liens ----- */
.eup-page-content a {
	color: #b8006e;
	font-weight: 600;
	text-decoration: underline;
	text-decoration-color: rgba(236, 0, 140, 0.35);
	text-underline-offset: 4px;
	text-decoration-thickness: 1.5px;
	transition: color 0.2s ease, text-decoration-color 0.2s ease;
}
.eup-page-content a:hover {
	color: #ec008c;
	text-decoration-color: #ec008c;
}

/* Lien externe : flèche discrète */
.eup-page-content a[href^='http']:not([href*='leseuphoribes.fr'])::after {
	content: ' \2197'; /* ↗ */
	font-size: 0.85em;
	opacity: 0.7;
	margin-left: 1px;
}

/* ----- Mise en valeur ----- */
.eup-page-content strong {
	color: #1a1a2e;
	font-weight: 700;
	background: linear-gradient(180deg, transparent 60%, rgba(105, 176, 76, 0.18) 60%);
	padding: 0 1px;
}

.eup-page-content em {
	font-style: italic;
	color: #4f8c39;
}

/* ----- Citations ----- */
.eup-page-content blockquote {
	position: relative;
	border-left: 4px solid rgba(236, 0, 140, 0.5);
	background: rgba(252, 228, 243, 0.4);
	border-radius: 0 1rem 1rem 0;
	padding: 1.25rem 1.5rem 1.25rem 2.75rem;
	margin: 1.75rem 0;
	font-style: normal;
	color: #334155;
	font-size: 1.05rem;
	line-height: 1.7;
}
.eup-page-content blockquote::before {
	content: '\201C'; /* " */
	position: absolute;
	left: 0.6rem;
	top: 0.4rem;
	font-family: 'Cabinet Grotesk', Georgia, serif;
	font-size: 3.75rem;
	line-height: 1;
	color: #ec008c;
	opacity: 0.32;
	font-weight: 800;
	pointer-events: none;
}
.eup-page-content blockquote p { margin: 0.5rem 0; }
.eup-page-content blockquote cite {
	display: block;
	margin-top: 0.75rem;
	font-style: normal;
	font-size: 0.85rem;
	color: #64748b;
	font-weight: 600;
}

/* ----- Listes à puces ----- */
.eup-page-content ul {
	list-style: none;
	padding-left: 0;
	margin: 1rem 0;
}
.eup-page-content ul li {
	position: relative;
	padding-left: 1.75rem;
	margin: 0.4rem 0;
	line-height: 1.65;
}
.eup-page-content ul li::before {
	content: '';
	position: absolute;
	left: 0;
	top: 0.55rem;
	width: 0.85rem;
	height: 0.85rem;
	border-radius: 9999px;
	background: rgba(105, 176, 76, 0.18);
	box-shadow: inset 0 0 0 2px rgba(105, 176, 76, 0.6);
}

/* ----- Listes numérotées ----- */
.eup-page-content ol {
	list-style: none;
	padding-left: 0;
	margin: 1rem 0;
	counter-reset: eup-list;
}
.eup-page-content ol li {
	position: relative;
	padding-left: 2.4rem;
	margin: 0.5rem 0;
	line-height: 1.65;
	counter-increment: eup-list;
	min-height: 1.6rem;
}
.eup-page-content ol li::before {
	content: counter(eup-list);
	position: absolute;
	left: 0;
	top: 0.15rem;
	width: 1.6rem;
	height: 1.6rem;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: 9999px;
	background: linear-gradient(135deg, #ec008c 0%, #b8006e 100%);
	color: #ffffff;
	font-size: 0.78rem;
	font-weight: 800;
	box-shadow: 0 2px 6px rgba(236, 0, 140, 0.30);
}

/* Listes imbriquées */
.eup-page-content li > ul,
.eup-page-content li > ol {
	margin: 0.4rem 0 0.5rem;
}

/* ----- Image « pochoir » ----- */
.eup-page-content img {
	border-radius: 1.25rem;
	box-shadow:
		0 0 0 6px #ffffff,
		8px 8px 0 -2px rgba(105, 176, 76, 0.22),
		-8px -8px 0 -2px rgba(236, 0, 140, 0.18),
		0 24px 48px -8px rgba(15, 23, 42, 0.18);
	transition: transform 0.5s ease, box-shadow 0.4s ease;
	max-width: 100%;
	height: auto;
}
.eup-page-content img:hover {
	transform: rotate(0) scale(1.01);
}
.eup-page-content img.alignright {
	float: right;
	margin: 0.6rem 0 1.25rem 1.75rem;
	max-width: 50%;
	transform: rotate(1.2deg);
}
.eup-page-content img.alignleft {
	float: left;
	margin: 0.6rem 1.75rem 1.25rem 0;
	max-width: 50%;
	transform: rotate(-1.2deg);
}
.eup-page-content img.aligncenter {
	display: block;
	margin: 1.5rem auto;
}
.eup-page-content img.size-full {
	max-width: 100%;
}
.eup-page-content figure {
	margin: 1.5rem 0;
	display: inline-block;
}
.eup-page-content figcaption {
	text-align: center;
	font-size: 0.8rem;
	color: #64748b;
	margin-top: 0.65rem;
	font-style: italic;
	font-weight: 500;
}

/* Mobile : pas de float pour les images alignées */
@media (max-width: 640px) {
	.eup-page-content img.alignright,
	.eup-page-content img.alignleft {
		float: none;
		display: block;
		max-width: 100%;
		margin: 1rem auto;
		transform: rotate(0);
	}
}

/* ----- Boutons / liens-boutons inline ----- */
.eup-page-content a.btn,
.eup-page-content a.button,
.eup-page-content .wp-block-button__link,
.eup-page-content button:not([type='reset']):not([type='submit']):not([class]) {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.65rem 1.4rem;
	border-radius: 9999px;
	background: linear-gradient(135deg, #ec008c 0%, #b8006e 100%);
	color: #ffffff !important;
	font-weight: 700;
	font-size: 0.875rem;
	text-decoration: none !important;
	box-shadow: 0 4px 14px rgba(236, 0, 140, 0.30);
	border: 0;
	cursor: pointer;
	transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
	line-height: 1.2;
}
.eup-page-content a.btn:hover,
.eup-page-content a.button:hover,
.eup-page-content .wp-block-button__link:hover,
.eup-page-content button:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 22px rgba(236, 0, 140, 0.40);
	color: #ffffff !important;
}

/* Bouton secondaire (variante via .btn-ghost ou .is-style-outline) */
.eup-page-content a.btn-ghost,
.eup-page-content .is-style-outline .wp-block-button__link {
	background: #ffffff;
	color: #4f8c39 !important;
	border: 2px solid rgba(105, 176, 76, 0.5);
	box-shadow: none;
}
.eup-page-content a.btn-ghost:hover,
.eup-page-content .is-style-outline .wp-block-button__link:hover {
	background: #69b04c;
	color: #ffffff !important;
	border-color: #69b04c;
}

/* ----- Tables ----- */
.eup-page-content table {
	width: 100%;
	border-collapse: separate;
	border-spacing: 0;
	border-radius: 1rem;
	overflow: hidden;
	margin: 1.75rem 0;
	box-shadow: 0 2px 14px rgba(0, 0, 0, 0.06);
	border: 1px solid #e2e8f0;
}
.eup-page-content thead th {
	background: linear-gradient(135deg, #69b04c 0%, #4f8c39 100%);
	color: #ffffff;
	font-weight: 700;
	text-align: left;
	padding: 0.875rem 1rem;
	font-size: 0.875rem;
}
.eup-page-content tbody td {
	padding: 0.75rem 1rem;
	border-top: 1px solid #f1f5f9;
	font-size: 0.95rem;
}
.eup-page-content tbody tr:nth-child(even) { background: #f5fff0; }
.eup-page-content tbody tr:hover { background: #fff5fb; }

/* ----- HR décoratif ----- */
.eup-page-content hr {
	border: 0;
	height: 2.5rem;
	margin: 2rem auto;
	position: relative;
	max-width: 280px;
	background-image: linear-gradient(to right,
		transparent 0%,
		rgba(105, 176, 76, 0.4) 25%,
		rgba(236, 0, 140, 0.4) 75%,
		transparent 100%);
	background-size: 100% 1px;
	background-position: center;
	background-repeat: no-repeat;
}
.eup-page-content hr::after {
	content: '\2724'; /* ✤ */
	position: absolute;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%);
	background: #ffffff;
	padding: 0.25rem 0.75rem;
	color: #ec008c;
	font-size: 1rem;
}

/* ----- Callouts / info boxes ----- */
.eup-page-content aside,
.eup-page-content .callout,
.eup-page-content .info-box,
.eup-page-content .wp-block-group.is-style-callout {
	background: linear-gradient(135deg, #f5fff0 0%, #fff5fb 100%);
	border: 1px solid rgba(105, 176, 76, 0.25);
	border-radius: 1rem;
	padding: 1rem 1.25rem;
	margin: 1.75rem 0;
	display: flex;
	gap: 0.875rem;
	align-items: flex-start;
	color: #334155;
	box-shadow: 0 2px 12px rgba(105, 176, 76, 0.08);
}
.eup-page-content aside::before,
.eup-page-content .callout::before,
.eup-page-content .info-box::before {
	content: '\f05a'; /* fa-circle-info */
	font-family: 'Font Awesome 6 Free', 'FontAwesome';
	font-weight: 900;
	color: #69b04c;
	font-size: 1.4rem;
	flex-shrink: 0;
	line-height: 1.2;
}
.eup-page-content aside p:first-child,
.eup-page-content .callout p:first-child {
	margin-top: 0;
}
.eup-page-content aside p:last-child,
.eup-page-content .callout p:last-child {
	margin-bottom: 0;
}

/* ----- Code ----- */
.eup-page-content code {
	font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
	font-size: 0.88em;
	padding: 0.15rem 0.5rem;
	border-radius: 0.4rem;
	background: rgba(252, 228, 243, 0.6);
	color: #b8006e;
	font-weight: 600;
}
.eup-page-content pre {
	background: #0f172a;
	color: #f1f5f9;
	border-radius: 1rem;
	padding: 1.25rem;
	margin: 1.5rem 0;
	overflow-x: auto;
	font-size: 0.88rem;
	line-height: 1.6;
}
.eup-page-content pre code {
	background: transparent;
	color: inherit;
	padding: 0;
	font-size: 1em;
	font-weight: 400;
}

/* ----- Vidéo embed ----- */
.eup-page-content iframe,
.eup-page-content video {
	border-radius: 1rem;
	box-shadow: 0 0 0 4px #ffffff, 0 12px 32px rgba(15, 23, 42, 0.15);
	max-width: 100%;
	margin: 1.5rem 0;
}

/* ----- Espacement final ----- */
.eup-page-content > :first-child { margin-top: 0; }
.eup-page-content > :last-child { margin-bottom: 0; }
