/*
Theme Name: Alowa
Theme URI: 
Author: Alowa Studio
Author URI: 
Description: Un thème créé par Alowa Studio !
Requires at least: 7.1
Tested up to: 7.1
Requires PHP: 5.7
Version: 0.1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: alowa
Tags: 
*/

/* Alowa : CSS global (front uniquement, un seul fichier).
   Le CSS de chaque module est dans modules/{slug}/{slug}.css. */

/* ========== Lenis (règles officielles de lenis.css) ========== */
html.lenis,
html.lenis body {
	height: auto;
}
.lenis.lenis-smooth {
	scroll-behavior: auto !important;
}
.lenis.lenis-smooth [data-lenis-prevent] {
	overscroll-behavior: contain;
}
.lenis.lenis-stopped {
	overflow: clip;
}
.lenis.lenis-smooth iframe {
	pointer-events: none;
}

/* ========== État initial des animations data-anim ========== */
/* Masqué seulement si le JS est actif, que les animations ne sont pas réduites
   et que le script n'a pas échoué. Sinon le contenu reste visible. */
@media (prefers-reduced-motion: no-preference) {
	.js:not(.alowa-anim-failed) [data-anim]:not([data-anim-stagger]),
	.js:not(.alowa-anim-failed) [data-anim][data-anim-stagger] > * {
		opacity: 0;
		visibility: hidden;
	}

	.js:not(.alowa-anim-failed) .alowa-letter-reveal:not(.alowa-letter-reveal--ready) {
		opacity: 0.1;
	}
}

.alowa-letter-reveal__word {
	display: inline-block;
	white-space: nowrap;
}

/* ========== Patterns styles ========== */
/* ========== Header ========== */
/* Liens du header : héritent de la couleur du texte, sans soulignement. */
.alowa-header a:where(:not(.wp-element-button)) {
	color: inherit;
	text-decoration: none;
}

/* Header transparent : superposé au premier bloc de la page.
/* ajouter la classe `alowa-header--transparent` au groupe racine du header. */
   /* Texte clair par défaut ; pour un hero clair, repasser la couleur sur `contrast` dans l'enfant. */
.wp-block-template-part:has(> .alowa-header--transparent) {
	position: sticky;
	top: 0;
	left: 0;
	right: 0;
	z-index: 100;
}
.alowa-header--transparent {
	color: var(--wp--preset--color--base);
	background: transparent;
}
/* header transparent sur mobile menu ouvert : prend toute la hauteur de l'écran, ajuste le padding */
header .wp-block-navigation__responsive-container.has-modal-open#modal-1{
	height: 100dvh;
}
/* header .wp-block-navigation__responsive-container.has-modal-open#modal-1{
	padding-top: var(--wp--preset--spacing--40);
	padding-left: var(--wp--preset--spacing--40);
	padding-right: var(--wp--preset--spacing--40);
} */

/* Évite le block gap entre l’en-tête et le contenu principal. */
.wp-site-blocks > main {
	margin-block-start: 0;
}

/* Barre d'administration WordPress */
.admin-bar .alowa-header--transparent {
	top: 46px;
}
@media (min-width: 783px) {
	.admin-bar .alowa-header--transparent {
		top: 32px;
	}
}

/* ========== CSS de footer ========== */
footer{
	margin-block-start: 0!important;
}

/* ========== CSS de inc/carte-lien.php pour transformer les blocs cover en cartes cliquables ========== */
.carte-lien-wrapper {
	display: block;
	color: inherit;
	text-decoration: none;
}
.carte-lien-wrapper:focus-visible {
	outline: none;
}
.carte-lien-wrapper:focus-visible .wp-block-cover {
	outline: 1px solid currentColor;
	outline-offset: 1px;
}

/* ========== CSS de inc/boutons-actifs.php pour les boutons actifs ========== */
.boutons-catégories .wp-block-button__link {
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.boutons-catégories .wp-block-button__link[aria-current="page"] {
	background-color: var(--wp--preset--color--contrast);
	border-color: var(--wp--preset--color--contrast);
	color: var(--wp--preset--color--base) !important;
}

/* ========== CSS Global du thème parent ========== */
/* html scroll: attention au conflit avec Lenis, utiliser smooth casse le fonctionnement des ancres. les liens vers #contact, par exemple, ne fonctionneront plus */
html {
	scroll-behavior: auto !important;
}
.alowa-full-width {
    width: 100%;
}
.alowa-full-height {
    height: 100%;
}
.alowa-stretch{
  /* Fallback de secours (pour les très vieux navigateurs) */
  height: 100%; 
  /* Compatibilité Safari / WebKit */
  height: -webkit-fill-available;
  /* Compatibilité anciens Firefox (principalement pour la largeur, mais recommandé en sécurité) */
  height: -moz-available;
  /* Propriété standard moderne (Chrome 138+, Edge 138+) */
  height: stretch;
}
.alowa-aspect-ratio-square {
    aspect-ratio: 1 / 1;
}
.alowa-zindex-1 {
	position: relative;
	z-index: 1;
}