/*
 * SHELL.CSS — ce qui entoure toutes les pages : en-tête, menu mobile, bouton d'achat du livre,
 * barre collante du bas, bandeau des partenaires et pied de page. Les couleurs viennent de base.css.
 */

/* --- Lien d'évitement et fond de page : voir base.css --- */

/* --- En-tête --- */
.site-header { position: sticky; top: 0; z-index: 50; padding: 1rem 0; background: #fff; border-bottom: 1px solid #F3F4F6; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); }
.site-header__inner { max-width: 64rem; margin: 0 auto; padding: 0 1rem; }
.site-header__row { display: flex; align-items: center; justify-content: space-between; }
@media (min-width: 640px) { .site-header__inner { padding: 0 1.5rem; } }
@media (min-width: 1024px) { .site-header__inner { padding: 0 2rem; } }
.site-header__brand { display: flex; align-items: center; gap: 0.625rem; text-decoration: none; }
.site-header__brand img { flex: none; width: 2.25rem; height: 2.25rem; }
.site-header__brand .logo-word { font-family: var(--font-heading); font-weight: 800; font-size: 1.125rem; color: var(--color-primary); }
@media (min-width: 640px) { .site-header__brand .logo-word { font-size: 1.25rem; } }

/* Nom du site : « alternance » surligné en violet pâle */
.logo-word { letter-spacing: -0.035em; line-height: 1; }
.logo-word em { font-style: normal; background: linear-gradient(transparent 60%, var(--color-secondary-light) 60%); }
.logo-word__tld { font-weight: 700; color: #64748b; }
@media (max-width: 400px) { .logo-word__tld { display: none; } }

/* Navigation du haut (ordinateur) */
.main-nav-desktop { display: none; align-items: center; gap: 1.5rem; }
@media (min-width: 768px) { .main-nav-desktop { display: flex; } }
.main-nav-desktop a { font-size: 0.875rem; line-height: 1.25rem; text-transform: uppercase; letter-spacing: 0.025em; color: var(--color-primary); text-decoration: none; transition: color 0.15s; }
.main-nav-desktop a:hover { color: var(--color-accent); }
.main-nav-desktop a.is-current { text-decoration: underline; text-decoration-style: solid; text-decoration-thickness: 2px; text-underline-offset: 4px; }

/* Bouton « MENU » (mobile) */
.site-header__burger-wrap { display: flex; align-items: center; }
@media (min-width: 768px) { .site-header__burger-wrap { display: none; } }
.site-header__burger { position: relative; z-index: 50; display: flex; align-items: center; padding: 0; background: none; border: 0; color: var(--color-accent); cursor: pointer; }
.site-header__burger span { padding-right: 0.5rem; font-family: var(--font-heading); font-weight: 800; font-size: 1rem; line-height: 1.5rem; color: var(--color-primary); }
.site-header__burger svg { width: 1.5rem; height: 1.5rem; }
.site-header__burger svg path { transform-origin: center; transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out; }
.site-header__burger.is-open #burger-top { transform: translateY(6px) rotate(45deg); }
.site-header__burger.is-open #burger-middle { opacity: 0; }
.site-header__burger.is-open #burger-bottom { transform: translateY(-6px) rotate(-45deg); }

/* Menu plein écran (mobile) */
.site-menu { position: fixed; inset: 0; z-index: 40; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 2rem 1rem; overflow-y: auto; background: rgba(255, 255, 255, 0.9); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); opacity: 0; pointer-events: none; transform: translateY(-2.5rem); transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out; }
.site-menu[hidden] { display: none; }
.site-menu.is-open { opacity: 1; pointer-events: auto; transform: none; }
.site-menu__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem 1rem; width: 100%; max-width: 32rem; text-align: center; }
.site-menu__card { position: relative; display: block; padding: 1.5rem 0.5rem; border-radius: 7px; text-decoration: none; transition: transform 0.15s; }
.site-menu__card:nth-child(odd) { transform: rotate(-2deg); }
.site-menu__card:nth-child(even) { transform: rotate(2deg); }
.site-menu__card:hover { transform: scale(1.05) rotate(-2deg); }
.site-menu__card:nth-child(even):hover { transform: scale(1.05) rotate(2deg); }
.site-menu__tag { display: inline-flex; align-items: center; justify-content: center; padding: 0.25rem 0.75rem; border-radius: 7px; background: rgba(26, 43, 72, 0.2); font: 800 1.125rem/1.75rem var(--font-heading); letter-spacing: 0.05em; text-transform: uppercase; color: var(--color-primary); }
.site-menu__tag--home { background: rgba(255, 127, 50, 0.2); }
.site-menu__tag--app { background: #E5E7EB; }
.site-menu__tag.is-current { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }
.site-menu__card p { margin: 0.5rem 0 1.5rem; font-size: 1.15rem; line-height: 1.6; color: var(--color-text); }
.site-menu__card .material-icons { margin-right: 0.5rem; font-size: 1.125rem; line-height: 1.75rem; }

/* --- Bouton d'achat du livre (composant cta_button) : orange du site, cadre marine, coins arrondis comme les autres boutons --- */
.cta-buy-btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.8rem 1.4rem; background: var(--color-accent-dark); border: 2px solid var(--color-primary); border-radius: 12px; box-shadow: 0 6px 16px rgba(26, 43, 72, 0.25); font-family: var(--font-heading); font-weight: 800; font-size: 0.85rem; line-height: 1.3; letter-spacing: 0.04em; color: #fff; text-transform: uppercase; text-decoration: none; white-space: nowrap; cursor: pointer; transition: background 0.15s, transform 0.15s, box-shadow 0.15s; }
.cta-buy-btn:hover, .cta-buy-btn:focus-visible { background: var(--color-primary); color: #fff; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(26, 43, 72, 0.3); }
.cta-buy-btn:active { transform: none; box-shadow: 0 2px 6px rgba(26, 43, 72, 0.25); }
.cta-buy-btn__icon { font-size: 1.125rem; line-height: 1; }

/* Barre collante du bas : bouton d'achat, qui apparaît après un peu de défilement */
.site-sticky { position: fixed; bottom: 30px; left: 1rem; right: 104px; z-index: 110; align-items: center; justify-content: center; gap: 0.75rem; opacity: 0; transform: translateY(5rem); pointer-events: none; transition: all 0.3s; }
.site-sticky.is-visible { opacity: 1; transform: none; }
.site-sticky.is-visible > * { pointer-events: auto; }
@media (min-width: 640px) { .site-sticky { left: auto; justify-content: flex-start; } }

/* --- Bandeau des partenaires --- */
.hm-ticker { padding: 2rem 0; overflow: hidden; }
.hm-ticker__title { margin: 0 0 1.5rem; font: 800 0.75rem/1rem var(--font-heading); letter-spacing: 0.1em; text-align: center; text-transform: uppercase; color: #6B7280 !important; }
.hm-ticker__track { margin-top: 1rem; position: relative; display: flex; width: 100%; overflow-x: hidden; }
.hm-ticker__fade { position: absolute; top: 0; bottom: 0; z-index: 10; width: 4rem; pointer-events: none; }
.hm-ticker__fade--l { left: 0; }
.hm-ticker__fade--r { right: 0; }
.hm-ticker__set { display: flex; align-items: center; gap: 4rem; padding-right: 4rem; white-space: nowrap; }
.hm-ticker__set a { display: inline-block; transition: opacity 0.15s; }
.hm-ticker__set a:hover { opacity: 0.8; }
.hm-ticker__set img { width: auto; max-width: 150px; height: 2.5rem; object-fit: contain; filter: grayscale(1); opacity: 0.6; transition: filter 0.3s, opacity 0.3s; }
@media (min-width: 640px) { .hm-ticker__set img { height: 3rem; } }
.hm-ticker__set a:hover img { filter: none; opacity: 1; }
.hm-ticker__name { font: 700 0.75rem/1rem var(--font-heading); letter-spacing: 0.05em; text-transform: uppercase; color: #1F2937; }
.hm-ticker__since { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.75rem; margin-top: 1rem; padding: 1.5rem 1rem 0; text-align: center; }
@media (min-width: 640px) { .hm-ticker__since { flex-direction: row; text-align: left; } }
.hm-ticker__since .material-icons { font-size: 1.5rem; color: var(--color-accent); }
.hm-ticker__since p { margin: 0; font: 800 0.75rem/1rem var(--font-heading); letter-spacing: 0.05em; text-transform: uppercase; color: var(--color-primary); }

/* --- Pied de page --- */
.site-footer { margin-top: 4rem; padding: 2.5rem 0 2rem; background: var(--color-primary); color: #CBD5E1; border-top: 4px dashed #fff; }
.site-footer__inner { display: grid; justify-items: center; gap: 1.5rem; max-width: 64rem; margin: 0 auto; padding: 0 1rem; text-align: center; }
@media (min-width: 640px) { .site-footer__inner { padding: 0 1.5rem; } }
@media (min-width: 1024px) { .site-footer__inner { padding: 0 2rem; } }
.site-footer__brand { display: inline-flex; align-items: center; gap: 0.7rem; font-family: var(--font-heading); font-weight: 800; font-size: 1.35rem; letter-spacing: -0.035em; color: #fff; text-decoration: none; }
.site-footer__brand img { width: 2.75rem; height: 2.75rem; }
.site-footer__brand em { font-style: normal; background: linear-gradient(transparent 60%, rgba(233, 213, 255, 0.45) 60%); }
.site-footer__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem; }
.site-footer__links a { padding: 0.45rem 0.9rem; border-radius: 999px; background: rgba(255, 255, 255, 0.1); font-family: var(--font-heading); font-weight: 700; font-size: 0.78rem; color: #fff; text-decoration: none; transition: background 0.15s; }
.site-footer__links a:hover { background: var(--color-accent-dark); }
.site-footer__copy { margin: 0; font-size: 0.85rem; color: #94A3B8; }
.site-footer__copy a { color: #CBD5E1; text-decoration: underline; text-underline-offset: 3px; }
.site-footer__copy a:hover { color: #fff; }
.site-footer .sources-footer { position: relative; width: 100%; padding-top: 1rem; text-align: left; }
.sources-list { margin: 0; padding: 0; list-style: none; font-size: 0.875rem; line-height: 1.375; }
.sources-list > li { break-inside: avoid; }
.sources-list > li + li { margin-top: 0.5rem; }
@media (min-width: 640px) { .sources-list { column-count: 2; column-gap: 2rem; } }
@media (min-width: 1024px) { .sources-list { column-count: 3; } }
.sources-note { margin: 0.75rem 0 1.5rem; font-size: 0.75rem; line-height: 1rem; }

/* Message d'un formulaire d'inscription (marketing.js) : la couleur est posée par le script (vert en cas de succès, rouge en cas d'erreur) */
.form-message { margin-bottom: 1.5rem; font: 700 1.125rem/1.75rem var(--font-heading); text-align: center; }

/* Bouton flottant « Obtenir le livre » masqué pour le moment (décision du 20/11/2026). Pour le remettre : supprimer cette règle. */
.site-sticky { display: none; }
