/*==============================================================================
//
//  Theme "epure / magazine" - complement pour la page d'accueil (index2.php)
//
//  S'ajoute a theme-magazine.css (charge avant). Ne contient que les
//  elements propres a l'accueil : hero, grille de decouverte, bande de
//  saison, colonnes d'actualites, bande chiffres.
//
//==============================================================================*/

/*---------- Largeur : desormais commune a tout le site (1560 px), definie
            dans theme-magazine.css. Les blocs de texte long gardent une
            largeur de lecture raisonnable (voir plus bas).              */

/*---------- Chapo : presentation courte du site, sous le menu -----------------*/
.cf-chapo {
	font-family: 'Lora', Georgia, serif;
	font-size: 1.3rem;
	line-height: 1.5;
	margin: 1.5rem 0 .2rem;
	color: var(--cf-muted);
}
/* le <small> hérite de 1.3rem : on fixe une taille absolue, et on repasse
   en sans-serif car c'est un lien d'interface, pas du texte editorial   */
.cf-chapo small {
	display: inline-block;
	margin-top: .25rem;
	font-family: 'Inter', system-ui, sans-serif;
	font-size: .9rem;
}

/*---------- Hero : la recette de la semaine -----------------------------------*/
.cf-kicker {
	text-align: center;
	text-transform: uppercase;
	letter-spacing: .14em;
	font-size: .85rem;
	color: var(--cf-muted);
	margin-top: 1.6rem;
}
.cf-hero-titre {
	text-align: center;
	font-size: clamp(1.9rem, 3.8vw, 2.9rem);
	font-weight: 600;
	margin: .3rem 0 1.2rem;
}
.cf-hero-photo { text-align: center; margin-bottom: 0; }
.cf-hero-photo img {
	width: 100%;
	max-width: 600px;
	height: auto;
	border-radius: var(--cf-radius);
}
.cf-hero-intro {
	max-width: 72ch;
	margin: 1.2rem auto 0;
	background-color: #FFFFFF;
	border: 1px solid var(--cf-line);
	border-radius: var(--cf-radius);
	padding: 1rem 1.4rem;
}

/*---------- Sections : titre editorial + eventuel bouton a droite --------------*/
.cf-sec { margin: 2.4rem 0; }
.cf-sec-head {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 1rem;
	border-bottom: 2px solid var(--cf-ink);
	padding-bottom: .45rem;
	margin-bottom: 1.1rem;
}
.cf-sec-head h2, .cf-sec-head h3 {
	font-size: 1.05rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .1em;
	margin: 0;
}

/*---------- Grille de decouverte (recettes aleatoires) -------------------------*/
/* colonnes calees sur la taille native des vignettes (150x112) : au-dela,
   l'image serait etiree et donc floue                                     */
.cf-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, 150px);
	justify-content: space-between;
	gap: 1.1rem;
}
.cf-card { text-align: center; width: 150px; }
.cf-card img {
	width: 150px;
	height: 112px;
	object-fit: cover;
	border-radius: 8px;
	transition: transform .15s ease;
}
.cf-card a:hover img { transform: scale(1.04); }
.cf-card-t {
	display: block;
	margin-top: .45rem;
	font-size: .85rem;
	line-height: 1.3;
	color: var(--cf-ink);
}
.cf-card a { text-decoration: none; }

/*---------- Bande de saison -----------------------------------------------------*/
.cf-saison p { margin-bottom: .4rem; }
.cf-saison .img-thumbnail {
	width: 64px;
	height: 64px;
	object-fit: cover;
	border-radius: 50%;
	padding: 0;
	border: 1px solid var(--cf-line);
	background: none;
}

/*---------- Colonnes d'actualites (dernieres, commentaires, modifiees, blog) ---*/
.cf-col-titre {
	font-size: .92rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .08em;
	border-bottom: 2px solid var(--cf-ink);
	padding-bottom: .35rem;
	margin-bottom: .4rem;
}
.cf-col-titre a { color: var(--cf-ink); }
.cf-item {
	display: flex;
	gap: .65rem;
	padding: .6rem 0;
	border-bottom: 1px solid var(--cf-line);
	font-size: .88rem;
	line-height: 1.45;
}
.cf-item img {
	width: 80px;
	height: 80px;
	object-fit: cover;
	border-radius: 8px;
	flex: none;
}
.cf-item:last-child { border-bottom: 0; }

/*---------- Boites (intro du site, Ma cuisine facile) ---------------------------*/
.cf-box {
	background-color: #FFFFFF;
	border: 1px solid var(--cf-line);
	border-radius: var(--cf-radius);
	padding: 1.2rem 1.4rem;
}
/* les deux boites s'ajustent a leur contenu (pas d'etirement vertical) */
.cf-sec .row:has(.cf-box) { align-items: start; }
/* lignes de texte pas trop longues malgre la page elargie */
.cf-box p, .cf-box ul { max-width: 80ch; }
/* le lien du chapo amene ici : un peu d'air au-dessus a l'arrivee */
#bienvenue { scroll-margin-top: 1.5rem; }

/*---------- Bouton tertiaire ("En savoir plus...") -------------------------------
   Plus lisible que .btn-outline-secondary, qui a cote de deux boutons
   marques donnait l'impression d'etre desactive.                           */
.cf-btn-plus {
	background-color: #FFFFFF;
	border: 1px solid var(--cf-ink);
	color: var(--cf-ink);
}
.cf-btn-plus:hover, .cf-btn-plus:focus {
	background-color: var(--cf-ink);
	border-color: var(--cf-ink);
	color: #FFFFFF;
}
[data-bs-theme="dark"] .cf-btn-plus { background-color: #242320; color: var(--cf-ink); }
[data-bs-theme="dark"] .cf-btn-plus:hover, [data-bs-theme="dark"] .cf-btn-plus:focus {
	background-color: var(--cf-ink);
	color: #1B1A18;
}

/*---------- Bande chiffres / quoi de neuf ---------------------------------------*/
.cf-chiffres {
	background-color: var(--cf-soft);
	border-radius: var(--cf-radius);
	padding: 1.2rem 1.4rem;
}

/*---------- Mode sombre ----------------------------------------------------------*/
[data-bs-theme="dark"] .cf-hero-intro,
[data-bs-theme="dark"] .cf-box { background-color: #242320; }
