/* =====================================================================
   CTL Services - feuille de style du site
   Couleurs reprises du logo. Aucun style n'est écrit dans les pages
   (la Content-Security-Policy l'interdit) : tout est ici.
   ===================================================================== */

:root {
    --ctl-bleu: #0b5f86;          /* couleur principale (logo) */
    --ctl-bleu-fonce: #084a69;
    --ctl-nuit: #0f2530;          /* menu et pied de page */
    --ctl-ciel: #eaf4f8;          /* fonds clairs */
    --ctl-texte: #1d2b33;
    --ctl-gris: #5a6b74;

    /* Bootstrap reprend ces couleurs */
    --bs-primary: var(--ctl-bleu);
    --bs-primary-rgb: 11, 95, 134;
    --bs-link-color: var(--ctl-bleu);
    --bs-link-color-rgb: 11, 95, 134;
    --bs-link-hover-color: var(--ctl-bleu-fonce);
    --bs-link-hover-color-rgb: 8, 74, 105;
    --bs-body-color: var(--ctl-texte);
    --bs-body-font-size: 1.125rem;   /* 18 px : plus lisible pour tous */
    --bs-body-line-height: 1.6;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}
main { flex: 1 0 auto; }

h1, h2, h3 { color: var(--ctl-nuit); line-height: 1.25; }
h1 { font-size: calc(1.6rem + 1.2vw); }
h2 { font-size: calc(1.35rem + .6vw); }
a { text-underline-offset: .2em; }

/* Contour bien visible au clavier */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible,
select:focus-visible, summary:focus-visible {
    outline: 3px solid #f0a020;
    outline-offset: 2px;
}

/* Lien « Aller au contenu » : visible seulement au clavier */
.lien-evitement {
    position: absolute;
    left: -10000px;
    top: 0;
    z-index: 2000;
    background: #fff;
    padding: .5rem 1rem;
}
.lien-evitement:focus { left: 1rem; top: 1rem; }

/* Boutons aux couleurs du logo */
.btn { --bs-btn-padding-y: .6rem; --bs-btn-padding-x: 1.2rem; --bs-btn-font-size: 1.05rem; }
.btn-sm { --bs-btn-padding-y: .3rem; --bs-btn-padding-x: .8rem; --bs-btn-font-size: .95rem; }
.btn-primary {
    --bs-btn-bg: var(--ctl-bleu);
    --bs-btn-border-color: var(--ctl-bleu);
    --bs-btn-hover-bg: var(--ctl-bleu-fonce);
    --bs-btn-hover-border-color: var(--ctl-bleu-fonce);
    --bs-btn-active-bg: var(--ctl-bleu-fonce);
    --bs-btn-active-border-color: var(--ctl-bleu-fonce);
}
.btn-outline-primary {
    --bs-btn-color: var(--ctl-bleu);
    --bs-btn-border-color: var(--ctl-bleu);
    --bs-btn-hover-bg: var(--ctl-bleu);
    --bs-btn-hover-border-color: var(--ctl-bleu);
    --bs-btn-active-bg: var(--ctl-bleu-fonce);
}

/* ---------- Menu ---------- */
.barre-menu { background: var(--ctl-nuit); }
.barre-menu .navbar-brand { font-weight: 600; letter-spacing: .02em; }
.barre-menu .nav-link { color: rgba(255, 255, 255, .85); }
.barre-menu .nav-link.active { color: #fff; text-decoration: underline; text-underline-offset: .35em; }

/* ---------- Bandeau de tête des pages ---------- */
.bandeau {
    background: linear-gradient(135deg, var(--ctl-ciel), #fff);
    border-bottom: 1px solid #d6e7ef;
    padding: 3rem 0 2.5rem;
}
.bandeau .lead { font-size: 1.25rem; color: var(--ctl-gris); max-width: 46rem; }
.bandeau-accueil { padding: 4rem 0 3.5rem; }

/* ---------- Sections ---------- */
.section { padding: 3rem 0; }
.section-claire { background: var(--ctl-ciel); }
.page-etroite { max-width: 820px; }
.texte-gris { color: var(--ctl-gris); }

/* Cartes des prestations */
.carte-prestation {
    height: 100%;
    border: 1px solid #d6e7ef;
    border-radius: .75rem;
    padding: 1.5rem;
    background: #fff;
}
.carte-prestation h3 { font-size: 1.25rem; margin-bottom: .5rem; }
.carte-prestation p { margin-bottom: 0; }

/* Étapes « comment ça se passe » */
.etape-numero {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.6rem;
    height: 2.6rem;
    border-radius: 50%;
    background: var(--ctl-bleu);
    color: #fff;
    font-weight: 700;
    margin-bottom: .75rem;
}

/* Liste « pourquoi me faire confiance » */
.liste-confiance { list-style: none; padding-left: 0; }
.liste-confiance li { padding-left: 2rem; position: relative; margin-bottom: .75rem; }
.liste-confiance li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--ctl-bleu);
    font-weight: 700;
}

/* ---------- Tarifs : une ligne par tarif, lisible sur téléphone ---------- */
.tarif {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: .25rem 1rem;
    padding: 1.1rem 0;
    border-bottom: 1px solid #d6e7ef;
}
.tarif-libelle { flex: 1 1 18rem; font-weight: 600; }
.tarif-prix { font-size: 1.5rem; font-weight: 700; color: var(--ctl-bleu); white-space: nowrap; }
.tarif-prix small { font-size: 1rem; font-weight: 400; color: var(--ctl-gris); }
.tarif-note { flex-basis: 100%; color: var(--ctl-gris); font-size: 1rem; }

/* ---------- Questions fréquentes (sans JavaScript) ---------- */
.faq details {
    border: 1px solid #d6e7ef;
    border-radius: .5rem;
    padding: .9rem 1.2rem;
    margin-bottom: .75rem;
    background: #fff;
}
.faq summary { cursor: pointer; font-weight: 600; }
.faq details[open] summary { margin-bottom: .6rem; }

/* ---------- À propos ---------- */
.photo-profil, .photo-attente {
    width: 220px;
    height: 220px;
    border-radius: 50%;
    object-fit: cover;
}
.photo-attente {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--ctl-ciel);
    border: 2px dashed #b7d3df;
    color: var(--ctl-gris);
    font-size: 1rem;
    text-align: center;
    padding: 1rem;
}

/* ---------- Formulaires ---------- */
.form-etroit { max-width: 440px; }
.form-moyen { max-width: 640px; }
.form-label { font-weight: 600; }

/* Champ piège anti-robots (inscription, contact) */
.champ-piege {
    position: absolute;
    left: -10000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* Informations à compléter dans ctlServices-prive/entreprise.php */
.a-completer { color: #b00020; font-weight: 700; }

/* Encadré d'information */
.encadre {
    border-left: 4px solid var(--ctl-bleu);
    background: var(--ctl-ciel);
    padding: 1rem 1.25rem;
    border-radius: 0 .5rem .5rem 0;
}

/* Tableaux des pages légales */
.table-legale th { white-space: nowrap; }

/* Page d'erreur */
.image-erreur { max-width: 360px; width: 100%; height: auto; }

/* ---------- Pied de page ---------- */
.pied-page { background: var(--ctl-nuit); color: rgba(255, 255, 255, .85); font-size: 1rem; }
.pied-page a { color: #fff; }
.pied-page li { margin-bottom: .4rem; }
.pied-titre { color: #fff; font-weight: 700; margin-bottom: .75rem; }
.pied-copyright {
    border-top: 1px solid rgba(255, 255, 255, .15);
    margin-top: 2rem;
    padding-top: 1rem;
    font-size: .9rem;
    color: rgba(255, 255, 255, .65);
}

/* Pages espace client / admin (anciennes largeurs écrites dans les pages) */
.largeur-700 { max-width: 700px; }
.largeur-800 { max-width: 800px; }

@media (max-width: 575.98px) {
    .bandeau, .bandeau-accueil { padding: 2rem 0 1.75rem; }
    .section { padding: 2rem 0; }
}

/* ---------- Bandeau cookies (bas de l'écran, ne bloque pas le site) ---------- */
.bandeau-cookies {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1050;
    background: var(--ctl-nuit);
    color: #fff;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, .25);
}
.bandeau-cookies a { color: #fff; }
/* « Tout accepter » et « Tout refuser » : exactement la même apparence */
.btn-choix-cookies { min-width: 10rem; font-weight: 600; }
body.avec-bandeau { padding-bottom: 14rem; }
@media (min-width: 768px) { body.avec-bandeau { padding-bottom: 9rem; } }

/* ---------- Calendrier public ---------- */
.jour-calendrier {
    height: 100%;
    border: 1px solid #d6e7ef;
    border-radius: .75rem;
    padding: 1rem;
    background: #fff;
}
.jour-titre { font-weight: 700; color: var(--ctl-nuit); }
.creneau { display: block; width: 100%; margin-bottom: .4rem; text-align: center; font-size: 1rem; }
.creneau-pris {
    padding: .45rem .5rem;
    border-radius: .375rem;
    background: #eef1f3;
    color: #5f6b72;
}

/* ---------- Planning administrateur ---------- */
.planning { font-size: .95rem; min-width: 900px; }
.planning td { min-width: 8rem; vertical-align: top; }
/* Bootstrap colore les cellules via --bs-table-bg : on remplace cette variable. */
.planning td.case-ouvert { --bs-table-bg: #e8f6ee; }
.planning td.case-rdv { --bs-table-bg: #e6f0fb; }
.planning td.case-ferme { --bs-table-bg: #f4f4f4; }
.legende { display: inline-block; width: 1rem; height: 1rem; border: 1px solid #ccc; vertical-align: middle; }
.legende-ouvert { background: #e8f6ee; }
.legende-rdv { background: #e6f0fb; }
.legende-ferme { background: #f4f4f4; }
meter { width: 8rem; }

.creneau-pris { text-decoration: line-through; }
.legende-calendrier { font-size: 1rem; }
.creneau-exemple { display: inline-block; padding: .1rem .6rem; border-radius: .375rem; margin-right: .25rem; }
.creneau-exemple-libre { background: var(--ctl-bleu); color: #fff; }
.creneau-exemple-pris { background: #eef1f3; color: #5f6b72; text-decoration: line-through; }

/* ---------- Page Formations ---------- */
.sommaire-themes { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding-left: 0; }
.sommaire-themes a {
    display: inline-block;
    padding: .35rem .9rem;
    border: 1px solid #c9dfe9;
    border-radius: 2rem;
    background: #fff;
    text-decoration: none;
}
.sommaire-themes a:hover { background: var(--ctl-ciel); }
.theme-formations { scroll-margin-top: 1rem; }
.carte-formation { display: flex; flex-direction: column; scroll-margin-top: 1rem; }
.carte-formation h3 { margin-top: .5rem; }
.ref-formation {
    display: inline-block;
    align-self: flex-start;
    font-size: .85rem;
    font-weight: 700;
    letter-spacing: .05em;
    color: #fff;
    background: var(--ctl-bleu);
    border-radius: .3rem;
    padding: .1rem .5rem;
}
.infos-formation { display: flex; flex-wrap: wrap; gap: .25rem 1rem; color: var(--ctl-gris); font-size: 1rem; margin: .75rem 0; }
.infos-formation b { color: var(--ctl-texte); }
.carte-formation details { margin-top: auto; padding-top: .75rem; border-top: 1px solid #e3eef3; }
.carte-formation summary { cursor: pointer; font-weight: 600; color: var(--ctl-bleu); }
.carte-formation details[open] summary { margin-bottom: .5rem; }
.carte-formation details ul { margin-bottom: .5rem; }
.carte-parcours { border-color: var(--ctl-bleu); border-width: 2px; }
