/* Certification CT – styles du site public. Palette : marine, bleus, rouge, blanc. */
:root {
	--ct-navy: #0B1F3A;
	--ct-navy-2: #12294A;
	--ct-navy-line: #1E3A5F;
	--ct-red: #C8102E;
	--ct-red-dark: #9A0F25;
	--ct-ink: #1B2B44;
	--ct-muted: #44546A;
	--ct-line: #D7E0EC;
	--ct-ground: #F4F7FB;
	--ct-on-dark: #C6D2E3;
	--ct-display: 'Barlow Condensed', 'Arial Narrow', sans-serif;
}

.ct-muted { color: var(--ct-muted); }
.ct-small { font-size: 14px; }
.ct-code { font-family: var(--ct-display); font-weight: 700; color: var(--ct-level, var(--ct-navy)); min-width: 1.8em; display: inline-block; }

/* Message affiché après une formation remise à zéro */
.ct-notice-bar { background: #FDECEE; border-bottom: 1px solid #F3B8C1; color: var(--ct-red-dark); padding: 12px 20px; text-align: center; font-weight: 500; }
.ct-notice-bar p { margin: 0; }

/* Boutons */
.ct-btn, .ct-btn-outline { display: inline-block; padding: 11px 18px; border-radius: 6px; font-weight: 600; text-decoration: none; line-height: 1.2; }
.ct-btn { background: var(--ct-red); color: #fff; }
.ct-btn:hover { background: var(--ct-red-dark); color: #fff; }
.ct-btn-outline { border: 1px solid var(--ct-navy); color: var(--ct-navy); align-self: flex-start; }
.ct-btn-outline:hover { background: var(--ct-navy); color: #fff; }

/* Encadré d'information */
.ct-note { background: #fff; border: 1px solid var(--ct-line); border-left: 4px solid #1B4A9C; border-radius: 8px; padding: 14px 18px; }
.ct-note p { margin: 0; }

/* Cartes de niveau (accueil) */
.ct-levels { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px; margin: 24px 0; }
.ct-level-card { background: #fff; border: 1px solid var(--ct-line); border-radius: 12px; overflow: hidden; display: flex; flex-direction: column; }
.ct-level-card__head { background: var(--ct-level); color: #fff; padding: 22px 24px; display: flex; align-items: center; gap: 16px; }
.ct-level-card__body { padding: 22px 24px; display: flex; flex-direction: column; gap: 14px; flex-grow: 1; }
.ct-level-card__body p { margin: 0; }
.ct-level-badge { flex-shrink: 0; width: 52px; height: 52px; border: 2px solid currentColor; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; font-family: var(--ct-display); font-weight: 700; font-size: 30px; }
.ct-level-step { display: block; font-size: 13px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; opacity: .9; }
.ct-level-name { display: block; font-family: var(--ct-display); font-weight: 700; font-size: 26px; line-height: 1.1; text-transform: uppercase; }
.ct-course-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 15px; }
.ct-course-list a { color: var(--ct-ink); text-decoration: none; }
.ct-course-list a:hover { color: var(--ct-red); text-decoration: underline; }
.ct-level-rule { margin-top: auto !important; padding-top: 14px; border-top: 1px solid var(--ct-line); font-size: 14px; color: var(--ct-muted); }
.ct-level-link { color: var(--ct-level); font-weight: 600; text-decoration: none; }

/* Catalogue */
.ct-filters { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 32px; }
.ct-filter { min-height: 44px; padding: 0 20px; border-radius: 22px; border: 1px solid #B9C7DB; background: #fff; color: var(--ct-navy); font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; }
.ct-filter.is-active { background: var(--ct-navy); border-color: var(--ct-navy); color: #fff; }
.ct-cat-level { margin-bottom: 48px; }
.ct-cat-level[hidden] { display: none; }
.ct-cat-level__head { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; padding-bottom: 14px; margin-bottom: 22px; border-bottom: 3px solid var(--ct-level); }
.ct-cat-level__head .ct-level-badge { background: var(--ct-level); border-color: var(--ct-level); color: #fff; }
.ct-cat-level__title { flex: 1 1 260px; }
.ct-cat-level__title h2 { margin: 0; font-size: 34px; }
.ct-cat-level__rule { font-size: 14px; max-width: 420px; }
.ct-course-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 20px; }
.ct-course-card { background: #fff; border: 1px solid var(--ct-line); border-radius: 12px; padding: 22px; display: flex; flex-direction: column; gap: 12px; }
.ct-course-card h3 { margin: 0; font-family: inherit; font-size: 19px; line-height: 1.3; font-weight: 600; text-transform: none; }
.ct-course-card p { margin: 0; flex-grow: 1; font-size: 15px; }
.ct-course-card__top { display: flex; justify-content: space-between; align-items: center; }
.ct-course-card__top .ct-code { font-size: 22px; }
.ct-course-card__level { font-size: 12px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--ct-muted); }
.ct-tags { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13px; }
.ct-tags span { background: #EAF0F7; padding: 4px 10px; border-radius: 4px; }

/* Vérification d'un certificat */
.ct-verify__form label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 6px; }
.ct-verify__row { display: flex; flex-wrap: wrap; gap: 8px; }
.ct-verify__row input { flex: 1 1 220px; min-width: 0; height: 48px; padding: 0 14px; border-radius: 6px; border: 1px solid #8FA3BF; font-size: 16px; }
.ct-verify__row button { height: 48px; padding: 0 24px; border: 0; border-radius: 6px; background: var(--ct-red); color: #fff; font-weight: 600; font-size: 16px; cursor: pointer; }
.ct-verify__row button:hover { background: var(--ct-red-dark); }
.ct-verify__result { margin-top: 16px; padding: 14px 18px; border-radius: 8px; background: #fff; color: var(--ct-ink); border: 1px solid var(--ct-line); }
.ct-verify__result p { margin: 0 0 4px; }
.ct-verify__result.is-valid { border-left: 4px solid #1F7A3A; }
.ct-verify__result.is-revoked, .ct-verify__result.is-unknown { border-left: 4px solid var(--ct-red); }

/* Espace apprenant : mon parcours */
.ct-parcours { display: flex; flex-direction: column; gap: 24px; }
.ct-parcours__level { background: #fff; border: 1px solid var(--ct-line); border-radius: 12px; padding: 22px; }
.ct-parcours__head { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-bottom: 14px; color: var(--ct-level); }
.ct-parcours__head .ct-level-name { color: var(--ct-navy); }
.ct-pill { margin-left: auto; background: #EAF0F7; color: var(--ct-navy); font-size: 13px; font-weight: 600; padding: 4px 12px; border-radius: 12px; }
.ct-parcours__list { list-style: none; margin: 0; padding: 0; }
.ct-parcours__list li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid #E8EEF5; font-size: 15px; }
.ct-parcours__list a { color: var(--ct-ink); text-decoration: none; }
.ct-parcours__summary { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; margin-top: 14px; font-size: 15px; }

/* Accueil : blocs construits dans l'éditeur (classes CSS ajoutées aux groupes) */
.ct-hero { background: var(--ct-navy); color: #fff; }
.ct-hero h1 { color: #fff; font-size: clamp(40px, 6vw, 68px); line-height: 1; margin: 0 0 20px; }
.ct-hero p { color: var(--ct-on-dark); font-size: 19px; }
.ct-hero .ct-kicker { color: #9EC5FF; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 16px; }
.ct-hero .wp-block-button.is-style-outline .wp-block-button__link { color: #fff !important; border-color: #6F8DB8 !important; background: transparent !important; }
.ct-hero .wp-block-button.is-style-outline .wp-block-button__link:hover { background: #fff !important; color: var(--ct-navy) !important; }
.ct-schema { margin: 0; background: var(--ct-navy-2); border: 1px solid var(--ct-navy-line); border-radius: 12px; padding: 24px; }
.ct-schema svg { width: 100%; height: auto; display: block; }
.ct-schema figcaption { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 18px; margin-top: 16px; font-size: 14px; color: var(--ct-on-dark); }
.ct-schema figcaption strong { color: #fff; }
.ct-stats { background: #fff; border-bottom: 1px solid var(--ct-line); }
.ct-stats .ct-stat-value { font-family: var(--ct-display); font-weight: 700; font-size: 36px; line-height: 1; color: var(--ct-navy); margin: 0 0 6px; text-transform: none; }
.ct-stats p { margin: 0; color: var(--ct-muted); }
.ct-white { background: #fff; border-top: 1px solid var(--ct-line); border-bottom: 1px solid var(--ct-line); }
.ct-step-num { width: 48px; height: 48px; border-radius: 50%; background: var(--ct-navy); color: #fff !important; display: flex; align-items: center; justify-content: center; font-family: var(--ct-display); font-weight: 700; font-size: 24px; margin: 0 0 12px !important; }
.ct-steps h3 { font-family: inherit; text-transform: none; font-size: 19px; font-weight: 600; margin: 0 0 8px; }
.ct-verify-band { background: var(--ct-navy); color: #fff; border-radius: 12px; }
.ct-verify-band h2 { color: #fff; }
.ct-verify-band p { color: var(--ct-on-dark); }
.ct-verify-band .ct-verify__form label { color: #E3EAF4; }


/* Leçons : figures, encadrés, étapes, emplacement vidéo */
.ct-figure { margin: 24px 0; text-align: center; }
.ct-figure img, .ct-figure svg { max-width: 100%; height: auto; border-radius: 8px; }
.ct-figure img { width: 100%; border: 1px solid var(--ct-line); background: #fff; }
.ct-figure figcaption { margin-top: 8px; font-size: 13px; color: var(--ct-muted); }
.ct-figures { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin: 24px 0; }
.ct-figures .ct-figure { margin: 0; }
.ct-box { margin: 20px 0; padding: 14px 18px; border-radius: 8px; border-left: 5px solid var(--ct-navy); background: var(--ct-ground); }
.ct-box > :last-child { margin-bottom: 0; }
.ct-box__title { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.ct-box--retenir { border-color: #1B4A9C; background: #EEF4FC; }
.ct-box--retenir .ct-box__title { color: #1B4A9C; }
.ct-box--erreur { border-color: var(--ct-red); background: #FDECEE; }
.ct-box--erreur .ct-box__title { color: var(--ct-red-dark); }
.ct-box--exemple { border-color: #2F6FC4; background: #fff; border: 1px solid var(--ct-line); border-left: 5px solid #2F6FC4; }
.ct-box--exemple .ct-box__title { color: #2F6FC4; }
.ct-box--question { border-color: var(--ct-navy); background: #fff; border: 1px dashed #8FA3BF; border-left: 5px solid var(--ct-navy); }
.ct-box--question .ct-box__title { color: var(--ct-navy); }
.ct-box--question details summary { cursor: pointer; font-weight: 600; color: var(--ct-red); }
ol.ct-steps { counter-reset: ct-step; list-style: none; padding-left: 0; }
ol.ct-steps > li { counter-increment: ct-step; position: relative; padding: 4px 0 10px 44px; }
ol.ct-steps > li::before { content: counter(ct-step); position: absolute; left: 0; top: 2px; width: 30px; height: 30px; border-radius: 50%; background: var(--ct-navy); color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center; font-size: 15px; }
.ct-video { margin: 0 0 24px; padding: 28px 20px; border: 2px dashed #B9C7DB; border-radius: 10px; text-align: center; color: var(--ct-muted); background: #fff; }
.ct-video strong { display: block; color: var(--ct-navy); }
.ct-table-simple { width: 100%; border-collapse: collapse; margin: 16px 0; }
.ct-table-simple th, .ct-table-simple td { border: 1px solid var(--ct-line); padding: 8px 10px; text-align: left; vertical-align: top; }
.ct-table-simple th { background: var(--ct-ground); }


/* Mon espace */
.ct-espace { display: flex; flex-direction: column; gap: 36px; }
.ct-espace__hello { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px; background: var(--ct-navy); color: #fff; border-radius: 12px; padding: 32px; }
.ct-espace__hello h2 { color: #fff; margin: 0 0 6px; font-size: clamp(30px, 4vw, 42px); }
.ct-espace__hello p { margin: 0; color: var(--ct-on-dark); }
.ct-espace__kicker { color: #9EC5FF !important; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 6px !important; }
.ct-espace__links { display: flex; flex-wrap: wrap; gap: 10px; }
.ct-espace__links a { color: #fff; text-decoration: none; font-weight: 600; font-size: 14px; padding: 10px 14px; border: 1px solid #6F8DB8; border-radius: 6px; }
.ct-espace__links a:hover { background: #fff; color: var(--ct-navy); }
.ct-espace__stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; }
.ct-espace__stats div { background: #fff; border: 1px solid var(--ct-line); border-radius: 12px; padding: 18px 20px; display: flex; flex-direction: column; gap: 4px; }
.ct-espace__stats strong { font-family: var(--ct-display); font-size: 36px; line-height: 1; color: var(--ct-navy); }
.ct-espace__stats span { color: var(--ct-muted); font-size: 14px; }
.ct-espace__section > h2 { font-size: 30px; margin: 0 0 16px; }
.ct-progress { height: 8px; background: #E3EAF3; border-radius: 4px; overflow: hidden; }
.ct-progress span { display: block; height: 100%; background: var(--ct-level, var(--ct-navy)); }
.ct-espace__certs { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.ct-espace__certs li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; background: #fff; border: 1px solid var(--ct-line); border-radius: 10px; padding: 14px 18px; }
.ct-espace--login { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; }
.ct-espace__card { background: #fff; border: 1px solid var(--ct-line); border-radius: 12px; padding: 28px; }
.ct-espace__card h2 { margin: 0 0 8px; font-size: 30px; }
.ct-espace__card--dark { background: var(--ct-navy); color: #fff; border-color: var(--ct-navy); }
.ct-espace__card--dark h2 { color: #fff; }
.ct-espace__benefits { margin: 16px 0 24px; padding-left: 20px; color: var(--ct-on-dark); }
.ct-espace__benefits li { margin-bottom: 6px; }
.ct-espace #loginform p { margin: 0 0 14px; }
.ct-espace #loginform label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 6px; }
.ct-espace #loginform input[type=text], .ct-espace #loginform input[type=password] { width: 100%; height: 46px; padding: 0 12px; border: 1px solid #8FA3BF; border-radius: 6px; font-size: 16px; }
.ct-espace #loginform .login-remember label { display: flex; align-items: center; gap: 8px; font-weight: 400; }
.ct-espace #loginform input[type=submit] { background: var(--ct-red); color: #fff; border: 0; border-radius: 6px; padding: 12px 24px; font-weight: 600; font-size: 16px; cursor: pointer; }
.ct-espace #loginform input[type=submit]:hover { background: var(--ct-red-dark); }

/* Pied de page : liens vers les pages légales */
.ct-footer-links { margin: 6px 0 0; font-size: 14px; }
.ct-footer-links a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.ct-footer-links a:hover { color: #fff; }
