/* =========================================================
   ONBOARDING ISFSC — module « Jeux »
   Quiz, jeu « Phishing ou pas ? », passeport de tampons.
   Chargé sur le site et dans l'éditeur (questions et e-mails
   écrits en blocs natifs). Sans JavaScript, les questions et
   les e-mails restent lisibles ; le JavaScript les transforme
   en jeux (classe .onb-jeu-source sur les blocs d'origine).
   ========================================================= */

/* Couleur d'un quiz ou d'un tampon : principale, pastel, texte lisible. */
.is-red { --onbj-c: var(--wp--preset--color--red); --onbj-soft: var(--wp--preset--color--red-soft); --onbj-text: var(--wp--preset--color--red-dark); --onbj-stamp: var(--wp--preset--color--red); }
.is-ochre { --onbj-c: var(--wp--preset--color--ochre); --onbj-soft: var(--wp--preset--color--ochre-soft); --onbj-text: #8A5A00; --onbj-stamp: #B47A00; }
.is-moss { --onbj-c: var(--wp--preset--color--moss); --onbj-soft: var(--wp--preset--color--moss-soft); --onbj-text: var(--wp--preset--color--moss); --onbj-stamp: var(--wp--preset--color--moss); }
.is-indigo { --onbj-c: var(--wp--preset--color--indigo); --onbj-soft: var(--wp--preset--color--indigo-soft); --onbj-text: var(--wp--preset--color--indigo); --onbj-stamp: var(--wp--preset--color--indigo); }

/* Texte discret lisible (contraste AA ≥ 4,5:1 sur blanc, crème et dégradé chaleureux). */
:root { --onbj-mute: #626262; }

.onb-jeu-source { display: none !important; }
.onb-ink-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* =========================================================
   TAMPONS (SVG : anneaux, texte circulaire, icône, date)
   ========================================================= */
.onb-tampon {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  color: var(--onbj-stamp, var(--wp--preset--color--red));
  transform: rotate(var(--tilt, 0deg));
}
.onb-tampon__ring { fill: rgba(255, 255, 255, .6); stroke: currentColor; stroke-width: 3.5; }
.onb-tampon__thin { fill: none; stroke: currentColor; stroke-width: 1.2; stroke-dasharray: 2 3; }
.onb-tampon__core { fill: currentColor; fill-opacity: .1; stroke: currentColor; stroke-width: 2; }
.onb-tampon__text {
  fill: currentColor;
  font-family: var(--wp--preset--font-family--sans, system-ui, sans-serif);
  font-weight: 800;
  letter-spacing: .04em;
}
.onb-tampon__date {
  fill: currentColor;
  font-family: var(--wp--preset--font-family--mono, ui-monospace, monospace);
  font-size: 7.5px;
  font-weight: 700;
  letter-spacing: .06em;
}
.onb-tampon.is-preview { opacity: .92; }
.onb-tampon.is-locked { color: #A8A49A; }
.onb-tampon.is-locked .onb-tampon__ring { fill: rgba(255, 255, 255, .5); stroke-width: 2; stroke-dasharray: 6 4; }
.onb-tampon.is-locked .onb-tampon__core { fill: none; stroke-dasharray: 3 3; }
.onb-tampon.is-locked .onb-tampon__icon { opacity: .75; }

/* =========================================================
   BOUTONS DES JEUX
   ========================================================= */
.onb-jeu-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: .75rem 1.4rem;
  border-radius: 999px;
  border: 1.5px solid transparent;
  font-family: var(--wp--preset--font-family--sans);
  font-size: .95rem;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
  cursor: pointer;
  transition: transform .25s var(--onb-spring, ease), background-color .2s, color .2s, border-color .2s, box-shadow .2s;
}
.onb-jeu-btn .onb-icon { width: 18px; height: 18px; vertical-align: 0; }
/* Plus spécifique que le style global des liens (:root :where(a)). */
a.onb-jeu-btn { text-decoration: none; }
.onb-jeu-btn.is-primary,
a.onb-jeu-btn.is-primary { background: var(--wp--preset--color--ink); color: #fff; }
.onb-jeu-btn.is-primary:hover,
a.onb-jeu-btn.is-primary:hover { background: var(--onb-red-fill, #E0161E); color: #fff; }
.onb-jeu-btn.is-ghost,
a.onb-jeu-btn.is-ghost { background: transparent; color: var(--wp--preset--color--ink); border-color: currentColor; }
.onb-jeu-btn.is-ghost:hover,
a.onb-jeu-btn.is-ghost:hover { background: var(--wp--preset--color--ink); border-color: var(--wp--preset--color--ink); color: #fff; }
.onb-jeu-btn.is-red { background: var(--onb-red-fill, #E0161E); color: #fff; }
.onb-jeu-btn.is-red:hover { background: var(--wp--preset--color--red-dark); color: #fff; }
.onb-jeu-btn.is-small { padding: .5rem 1rem; font-size: .85rem; }
.onb-jeu-btn.is-small .onb-icon { width: 16px; height: 16px; }
.onb-jeu-btn:focus-visible { outline: 3px solid var(--wp--preset--color--red); outline-offset: 3px; }
.onb-jeu-btn[hidden] { display: none !important; }

/* =========================================================
   AIDE À L'ÉCRITURE (paragraphe visible seulement dans l'éditeur)
   ========================================================= */
.onb-editor-help { display: none; }
.editor-styles-wrapper .onb-editor-help {
  display: block;
  position: relative;
  padding: 14px 16px 14px 46px;
  border-radius: 12px;
  border: 1px dashed #D9A441;
  background: var(--wp--preset--color--ochre-soft);
  color: #5C3D00;
  font-size: 14px;
  line-height: 1.55;
}
.editor-styles-wrapper .onb-editor-help::before {
  content: "i";
  position: absolute;
  left: 14px;
  top: 14px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #8A5A00;
  color: #fff;
  font: 700 13px/1 Georgia, serif;
}
.editor-styles-wrapper .onb-quiz-intro { border-left: 3px solid var(--wp--preset--color--ochre); padding-left: 14px; }

/* =========================================================
   QUESTIONS DE QUIZ (style « Question de quiz »)
   Lisibles sans JavaScript ; mode d'emploi visible dans l'éditeur.
   ========================================================= */
.onb-quiz-content,
.editor-styles-wrapper { counter-reset: onb-q; }
.is-style-onb-question {
  counter-increment: onb-q;
  position: relative;
  box-sizing: border-box;
  background: var(--wp--preset--color--paper);
  border: 1px solid var(--wp--preset--color--line);
  border-radius: var(--onb-radius-card, 14px);
  padding: 22px 24px !important;
  margin-block: 0 16px;
}
.is-style-onb-question::before {
  content: "Question " counter(onb-q);
  display: inline-block;
  margin-bottom: 8px;
  font-family: var(--wp--preset--font-family--mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--wp--preset--color--red-dark);
}
.editor-styles-wrapper .is-style-onb-question { border: 1.5px dashed #CFCBC1; }
.editor-styles-wrapper .is-style-onb-question::before {
  content: "Question de quiz · la réponse en gras est la bonne";
  display: block;
  color: #8A5A00;
}
.is-style-onb-question > * { margin-block: 0; }
.is-style-onb-question > * + * { margin-top: 12px; }
.is-style-onb-question h2,
.is-style-onb-question h3,
.is-style-onb-question h4 {
  font-size: clamp(1.2rem, 2.2vw, 1.45rem);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.01em;
}
.is-style-onb-question ul,
.is-style-onb-question ol {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 6px;
}
.is-style-onb-question li {
  position: relative;
  padding: 9px 14px 9px 40px;
  border-radius: 10px;
  border: 1px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--cream);
  color: var(--wp--preset--color--ink-soft);
  font-size: 15px;
  line-height: 1.45;
}
.is-style-onb-question li::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 50%;
  width: 14px;
  height: 14px;
  margin-top: -7px;
  border-radius: 50%;
  border: 2px solid #CFCBC1;
  box-sizing: border-box;
}
/* La bonne réponse (en gras) : coche verte. */
.is-style-onb-question li:has(strong, b) {
  border-color: var(--wp--preset--color--moss);
  background: var(--wp--preset--color--moss-soft);
  color: var(--wp--preset--color--ink);
}
.is-style-onb-question li:has(strong, b)::before {
  border: 0;
  background: var(--wp--preset--color--moss) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 9px no-repeat;
}
.is-style-onb-question ul + p,
.is-style-onb-question ol + p {
  padding: 2px 0 2px 14px;
  border-left: 3px solid var(--wp--preset--color--ochre);
  color: var(--wp--preset--color--ink-soft);
  font-size: 15px;
}
.is-style-onb-question figure img { border-radius: 12px; }

/* =========================================================
   JEU « PHISHING OU PAS ? » — e-mails écrits en blocs
   ========================================================= */
.onb-phish-box > .is-style-onb-phishing { margin-top: var(--wp--preset--spacing--30); }
.is-style-onb-phishing:not(.is-ready) { display: grid; gap: 16px; }
@media (min-width: 782px) {
  .is-style-onb-phishing:not(.is-ready) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.is-style-onb-phishing:not(.is-ready) > .is-style-onb-mail { margin: 0 !important; max-width: none !important; }
.editor-styles-wrapper .is-style-onb-phishing::before {
  content: "Jeu « Phishing ou pas ? » · chaque groupe « E-mail du jeu » devient une carte à trier";
  grid-column: 1 / -1;
  font-family: var(--wp--preset--font-family--mono);
  font-size: 12px;
  font-weight: 700;
  color: #8A5A00;
}
.is-style-onb-mail {
  position: relative;
  box-sizing: border-box;
  background: var(--wp--preset--color--paper);
  border: 1px solid var(--wp--preset--color--line);
  border-radius: var(--onb-radius-card, 14px);
  padding: 18px 20px !important;
  box-shadow: var(--onb-shadow-sm, 0 4px 12px rgba(20, 20, 20, .05));
  font-size: 15px;
  line-height: 1.5;
}
.is-style-onb-mail > * { margin-block: 0; }
.is-style-onb-mail > * + * { margin-top: 10px; }
.is-style-onb-mail > p:nth-of-type(1),
.is-style-onb-mail > p:nth-of-type(2) { font-size: 13.5px; color: var(--wp--preset--color--ink-soft); overflow-wrap: anywhere; }
.is-style-onb-mail > p:nth-of-type(2) + * { margin-top: 0; }
.is-style-onb-mail > p:nth-of-type(1) + p { margin-top: 2px; padding-bottom: 10px; border-bottom: 1px dashed var(--wp--preset--color--line); }
.is-style-onb-mail > p:nth-of-type(2) + p { margin-top: 10px; }
.is-style-onb-mail > ul,
.is-style-onb-mail > ol {
  padding: 12px 14px 12px 32px;
  border-radius: 10px;
  background: var(--wp--preset--color--cream);
  font-size: 14px;
  color: var(--wp--preset--color--ink-soft);
}
.is-style-onb-mail > ul::before,
.is-style-onb-mail > ol::before {
  content: "Les indices";
  display: block;
  margin: 0 0 4px -18px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--onbj-mute);
}
.is-style-onb-mail > p:last-child {
  display: table;
  margin-inline: 0 !important;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--wp--preset--color--ink);
  color: #fff;
  font-size: 13px;
}
.is-style-onb-mail > p:last-child strong { color: #fff; }
.editor-styles-wrapper .is-style-onb-mail::before {
  content: "E-mail du jeu · De : / Objet : / texte / indices / Verdict :";
  display: block;
  margin-bottom: 8px;
  font-family: var(--wp--preset--font-family--mono);
  font-size: 11px;
  font-weight: 700;
  color: #8A5A00;
}

/* Bloc du jeu : grande enveloppe décorative à droite, sur grand écran. */
@media (min-width: 1100px) {
  .onb-phish-box::after {
    content: "";
    position: absolute;
    right: 48px;
    top: 72px;
    width: 300px;
    height: 300px;
    background: var(--wp--preset--color--red);
    opacity: .07;
    transform: rotate(-12deg);
    pointer-events: none;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 10.5V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v12c0 1.1.9 2 2 2h12.5'/%3E%3Cpath d='m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7'/%3E%3Cpath d='M20 14v4'/%3E%3Cpath d='M20 22v.01'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 10.5V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v12c0 1.1.9 2 2 2h12.5'/%3E%3Cpath d='m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7'/%3E%3Cpath d='M20 14v4'/%3E%3Cpath d='M20 22v.01'/%3E%3C/svg%3E") center / contain no-repeat;
  }
  .onb-phish-box > * { position: relative; z-index: 1; }
}

/* =========================================================
   QUIZ — écran de départ, questions, score
   ========================================================= */
.onb-quiz { margin-block: var(--wp--preset--spacing--20) var(--wp--preset--spacing--50); }
.onb-quiz__stage {
  position: relative;
  max-width: 860px;
  box-sizing: border-box;
  padding: clamp(22px, 4vw, 40px);
  border-radius: var(--onb-radius-block, 22px);
  border: 1px solid var(--wp--preset--color--line);
  background-color: var(--wp--preset--color--paper);
  background-image: radial-gradient(480px circle at 100% 0%, var(--onbj-soft, #FFEFEF), transparent 70%);
  box-shadow: var(--onb-shadow-md, 0 8px 24px rgba(20, 20, 20, .06));
  overflow: hidden;
}
.onb-quiz__start {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 32px;
  align-items: center;
}
.onb-quiz__visual { position: relative; }
.onb-quiz__body > * { margin-block: 0; }
.onb-quiz__body > * + * { margin-top: 14px; }
.onb-quiz__kicker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--onbj-text, var(--wp--preset--color--red-dark));
}
.onb-quiz__kicker .onb-icon { width: 16px; height: 16px; }
.onb-quiz__body .onb-quiz__kicker + .onb-quiz__title { margin-top: 4px; }
.onb-quiz .onb-quiz__title,
.onb-quiz .onb-quiz__q,
.onb-quiz .onb-quiz__result-title,
.onb-quiz-card .onb-quiz-card__title,
.onb-phish .onb-phish__end-title,
.onb-pass .onb-pass__name { color: var(--wp--preset--color--ink); text-transform: none; }
.onb-quiz .onb-quiz__title {
  font-size: clamp(1.7rem, 3.4vw, 2.3rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.onb-quiz__intro p { margin: 0; color: var(--wp--preset--color--ink-soft); }
.onb-quiz__intro p + p { margin-top: 8px; }
.onb-quiz__facts {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.onb-quiz__facts li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--wp--preset--color--line);
  background: rgba(255, 255, 255, .8);
  font-size: 13.5px;
  color: var(--wp--preset--color--ink-soft);
}
.onb-quiz__facts .onb-icon { width: 15px; height: 15px; color: var(--onbj-text, var(--wp--preset--color--red-dark)); }
.onb-quiz__facts li[hidden] { display: none; }
.onb-quiz__facts li.onb-quiz__best { border-color: var(--wp--preset--color--moss); color: var(--wp--preset--color--moss); font-weight: 600; }
.onb-quiz__facts li.onb-quiz__best .onb-icon { color: var(--wp--preset--color--moss); }
.onb-quiz__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.onb-quiz__nojs,
.onb-quiz__empty { font-size: 14px; color: var(--wp--preset--color--ink-soft); }
.onb-quiz__editor-note {
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px dashed #D9A441;
  background: var(--wp--preset--color--ochre-soft);
  font-size: 14px;
  color: #5C3D00;
}
.onb-quiz__editor-note p,
.onb-quiz__editor-note ul { margin: 0; }
.onb-quiz__editor-note > * + * { margin-top: 6px; }
html:not(.onb-js) .onb-quiz__actions,
html:not(.onb-js) .onb-quiz__intro { display: none; }
.onb-js .onb-quiz__nojs { display: none; }

/* Partie en cours */
.onb-quiz__run { display: grid; gap: 20px; }
.onb-quiz__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
}
.onb-quiz__step {
  margin: 0;
  font-family: var(--wp--preset--font-family--mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--wp--preset--color--ink-soft);
}
.onb-quiz__step strong { color: var(--wp--preset--color--ink); }
.onb-quiz__dots,
.onb-phish__dots {
  display: flex;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.onb-quiz__dots li,
.onb-phish__dots li {
  width: 26px;
  height: 7px;
  border-radius: 999px;
  background: var(--wp--preset--color--line);
  transition: background-color .3s, transform .3s var(--onb-spring, ease);
}
.onb-quiz__dots li.is-on,
.onb-phish__dots li.is-on { background: var(--onbj-c, var(--wp--preset--color--ink)); transform: scaleY(1.4); }
.onb-quiz__dots li.is-ok,
.onb-phish__dots li.is-ok { background: var(--wp--preset--color--moss); }
.onb-quiz__dots li.is-ko,
.onb-phish__dots li.is-ko { background: var(--wp--preset--color--red); }
.onb-quiz__quit {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--paper);
  color: var(--wp--preset--color--ink-soft);
  font: 600 13px var(--wp--preset--font-family--sans);
  cursor: pointer;
}
.onb-quiz__quit:hover { border-color: var(--wp--preset--color--ink); color: var(--wp--preset--color--ink); }
.onb-quiz__quit .onb-icon { width: 15px; height: 15px; }
.onb-quiz__card { display: grid; gap: 18px; }
.onb-quiz .onb-quiz__q {
  margin: 0;
  font-size: clamp(1.35rem, 2.8vw, 1.9rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  outline: none;
}
.onb-quiz__img { margin: 0; }
.onb-quiz__img img { display: block; max-width: 100%; max-height: 320px; height: auto; border-radius: 12px; }
.onb-quiz__choices { display: grid; gap: 10px; }
@media (min-width: 700px) {
  .onb-quiz__choices.is-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.onb-quiz__choice {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 24px;
  align-items: center;
  gap: 14px;
  width: 100%;
  margin: 0;
  padding: 11px 14px 11px 11px;
  border-radius: 14px;
  border: 1.5px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--cream);
  color: var(--wp--preset--color--ink);
  font-family: var(--wp--preset--font-family--sans);
  font-size: 1rem;
  line-height: 1.4;
  text-align: left;
  cursor: pointer;
  transition: transform .25s var(--onb-spring, ease), border-color .2s, background-color .2s, box-shadow .2s, opacity .3s;
}
.onb-quiz__choice:hover:not(:disabled) {
  border-color: var(--wp--preset--color--ink);
  background: var(--wp--preset--color--paper);
  box-shadow: var(--onb-shadow-sm, 0 4px 12px rgba(20, 20, 20, .05));
}
.onb-quiz__choice:disabled { cursor: default; color: var(--wp--preset--color--ink); }
.onb-quiz__letter {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1.5px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--paper);
  font-family: var(--wp--preset--font-family--mono);
  font-size: 14px;
  font-weight: 700;
  transition: background-color .2s, color .2s, border-color .2s, transform .3s var(--onb-spring, ease);
}
.onb-quiz__choice:hover:not(:disabled) .onb-quiz__letter { background: var(--wp--preset--color--ink); border-color: var(--wp--preset--color--ink); color: #fff; }
.onb-quiz__mark { display: grid; place-items: center; }
.onb-quiz__mark .onb-icon { width: 22px; height: 22px; }
.onb-quiz__choice.is-right { border-color: var(--wp--preset--color--moss); background: var(--wp--preset--color--moss-soft); }
.onb-quiz__choice.is-right .onb-quiz__letter { background: var(--wp--preset--color--moss); border-color: var(--wp--preset--color--moss); color: #fff; }
.onb-quiz__choice.is-right .onb-quiz__mark { color: var(--wp--preset--color--moss); }
.onb-quiz__choice.is-wrong { border-color: var(--wp--preset--color--red); background: var(--wp--preset--color--red-soft); }
.onb-quiz__choice.is-wrong .onb-quiz__letter { background: var(--onb-red-fill, #E0161E); border-color: var(--onb-red-fill, #E0161E); color: #fff; }
.onb-quiz__choice.is-wrong .onb-quiz__mark { color: var(--wp--preset--color--red-dark); }
.onb-quiz__choice.is-dim { opacity: .55; }
.onb-quiz__keys { margin: -6px 0 0; font-size: 12.5px; color: var(--onbj-mute); }
@media (hover: none) { .onb-quiz__keys { display: none; } }
.onb-quiz__feedback { display: grid; gap: 14px; justify-items: start; }
.onb-quiz__feedback:empty { display: none; }
.onb-quiz__verdict,
.onb-phish__verdict {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
  margin: 0;
  padding: 12px 16px;
  border-radius: 14px;
  font-size: 15.5px;
  line-height: 1.45;
}
.onb-quiz__verdict .onb-icon,
.onb-phish__verdict .onb-icon { width: 22px; height: 22px; margin-top: 1px; }
.onb-quiz__verdict.is-ok,
.onb-phish__verdict.is-ok { background: var(--wp--preset--color--moss-soft); color: #2C5A36; }
.onb-quiz__verdict.is-ko,
.onb-phish__verdict.is-ko { background: var(--wp--preset--color--red-soft); color: #8E0A10; }
.onb-quiz__verdict p { margin: 0; }
.onb-quiz__expl { padding-left: 14px; border-left: 3px solid var(--onbj-c, var(--wp--preset--color--ochre)); color: var(--wp--preset--color--ink-soft); }
.onb-quiz__expl p { margin: 0; }
.onb-quiz__expl p + p { margin-top: 6px; }

/* Score */
.onb-quiz__result {
  display: grid;
  justify-items: center;
  gap: 14px;
  text-align: center;
  --onbj-ring: var(--wp--preset--color--moss);
}
.onb-quiz__result.is-fail { --onbj-ring: var(--wp--preset--color--ochre); }
.onb-quiz__result > * { margin: 0; }
.onb-quiz__ring { position: relative; width: 168px; height: 168px; }
.onb-quiz__ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.onb-quiz__ring-track { fill: none; stroke: var(--wp--preset--color--line); stroke-width: 10; }
.onb-quiz__ring-bar {
  fill: none;
  stroke: var(--onbj-ring);
  stroke-width: 10;
  stroke-linecap: round;
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  transition: stroke-dashoffset 1.2s var(--onb-ease, ease-out);
}
.onb-quiz__ring-val {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--wp--preset--font-family--display);
  font-size: 2.6rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.onb-quiz__ring-val small { font-size: .45em; font-weight: 700; margin-left: 2px; }
.onb-quiz .onb-quiz__result-title {
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  outline: none;
}
.onb-quiz__result-text { max-width: 52ch; color: var(--wp--preset--color--ink-soft); }
.onb-quiz__result-stamp { width: 128px; }
.onb-quiz__result-best { font-family: var(--wp--preset--font-family--mono); font-size: 13px; color: var(--onbj-mute); }
.onb-quiz__result-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.onb-quiz__recap {
  width: 100%;
  max-width: 640px;
  text-align: left;
  border: 1px solid var(--wp--preset--color--line);
  border-radius: 12px;
  background: var(--wp--preset--color--cream);
}
.onb-quiz__recap > summary {
  padding: 12px 16px;
  font-weight: 600;
  cursor: pointer;
}
.onb-quiz__recap ol { margin: 0; padding: 0 16px 14px 36px; display: grid; gap: 10px; font-size: 14.5px; }
.onb-quiz__recap li span { display: block; color: var(--wp--preset--color--ink-soft); font-size: 13.5px; }
.onb-quiz__recap .is-ok::marker { color: var(--wp--preset--color--moss); }
.onb-quiz__recap .is-ko::marker { color: var(--wp--preset--color--red); }
.onb-quiz__recap mark { padding: 0 4px; border-radius: 4px; }
.onb-quiz__recap .is-ok mark { background: var(--wp--preset--color--moss-soft); color: #2C5A36; }
.onb-quiz__recap .is-ko mark { background: var(--wp--preset--color--red-soft); color: #8E0A10; }

@media (max-width: 640px) {
  .onb-quiz__start { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .onb-quiz__visual { width: 120px; }
  .onb-quiz__quit { margin-left: 0; }
  .onb-quiz__top { justify-content: space-between; }
}

/* =========================================================
   LISTE DES QUIZ (cartes)
   ========================================================= */
.onb-quiz-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 440px), 1fr));
  gap: 18px;
}
.onb-quiz-card {
  position: relative;
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
  padding: 24px;
  border-radius: var(--onb-radius-card, 14px);
  border: 1px solid var(--wp--preset--color--line);
  background-color: var(--wp--preset--color--paper);
  background-image: radial-gradient(260px circle at 0% 0%, var(--onbj-soft), transparent 70%);
  transition: transform .35s var(--onb-ease, ease), box-shadow .35s, border-color .35s;
}
.onb-quiz-card:hover,
.onb-quiz-card:focus-within {
  border-color: var(--onbj-c);
  box-shadow: 0 14px 34px rgba(20, 20, 20, .12);
}
.onb-quiz-card__stamp .onb-tampon { width: 112px; transition: transform .5s var(--onb-spring, ease); }
.onb-quiz-card__body { display: grid; gap: 8px; justify-items: start; min-width: 0; }
.onb-quiz-card__body > * { margin: 0; }
.onb-quiz-card__meta { display: flex; flex-wrap: wrap; gap: 6px; }
.onb-quiz-card__state.onb-chip { border-color: var(--wp--preset--color--moss); background: var(--wp--preset--color--moss-soft); color: #2C5A36; font-weight: 600; }
.onb-quiz-card__state.onb-chip.is-try { border-color: #D9A441; background: var(--wp--preset--color--ochre-soft); color: #8A5A00; }
.onb-quiz-card .onb-quiz-card__title {
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.onb-quiz-card__title a { color: inherit; text-decoration: none; }
.onb-quiz-card__title a::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: var(--onb-radius-card, 14px);
}
.onb-quiz-card__title a:focus-visible { outline: none; }
.onb-quiz-card__title a:focus-visible::after { outline: 3px solid var(--wp--preset--color--red); outline-offset: 3px; }
.onb-quiz-card__excerpt { font-size: 14.5px; line-height: 1.5; color: var(--wp--preset--color--ink-soft); }
.onb-quiz-card__tampon { font-size: 13.5px; color: var(--wp--preset--color--ink-soft); }
.onb-quiz-card__tampon strong { color: var(--onbj-text); }
.onb-quiz-card__best {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--wp--preset--font-family--mono);
  font-size: 12.5px;
  color: var(--wp--preset--color--ink-soft);
}
.onb-quiz-card__best[hidden] { display: none; }
.onb-quiz-card__bar { position: relative; width: 120px; height: 6px; border-radius: 999px; background: var(--wp--preset--color--line); overflow: hidden; }
.onb-quiz-card__bar > span {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--pct, 0%);
  border-radius: inherit;
  background: var(--onbj-c);
  transition: width .9s var(--onb-ease, ease-out);
}
.onb-quiz-card__cta { margin-top: 6px !important; pointer-events: none; }
.onb-quiz-card:hover .onb-quiz-card__cta { background: var(--onb-red-fill, #E0161E); }
.onb-quiz-card.is-earned { border-color: color-mix(in srgb, var(--onbj-c) 45%, var(--wp--preset--color--line)); }
@media (max-width: 520px) {
  .onb-quiz-card { grid-template-columns: 76px minmax(0, 1fr); gap: 16px; padding: 18px; }
  .onb-quiz-card__stamp .onb-tampon { width: 76px; }
}

/* =========================================================
   JEU « PHISHING OU PAS ? » — pile de cartes (JavaScript)
   ========================================================= */
.onb-phish { display: grid; gap: 16px; max-width: 680px; }
.onb-phish__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  font-family: var(--wp--preset--font-family--mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--wp--preset--color--ink-soft);
}
.onb-phish__count { margin: 0; }
.onb-phish__count strong { color: var(--wp--preset--color--ink); }
.onb-phish__dots li { width: 18px; }
.onb-phish__score {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--paper);
  color: var(--wp--preset--color--ink);
}
.onb-phish__score .onb-icon { width: 15px; height: 15px; color: #B47A00; }
.onb-phish__stack { position: relative; display: grid; padding-bottom: 18px; }
.onb-phish__ghost,
.onb-mail { grid-area: 1 / 1; }
.onb-phish__ghost {
  border-radius: 18px;
  border: 1px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--paper);
  box-shadow: var(--onb-shadow-sm, 0 4px 12px rgba(20, 20, 20, .05));
  transform: translateY(calc(var(--k) * 9px)) scale(calc(1 - var(--k) * .04));
  transform-origin: 50% 100%;
  opacity: calc(1 - var(--k) * .3);
  z-index: calc(3 - var(--k));
}
.onb-mail {
  position: relative;
  z-index: 3;
  min-width: 0;
  border-radius: 18px;
  border: 1.5px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--paper);
  box-shadow: var(--onb-shadow-lg, 0 16px 36px rgba(20, 20, 20, .10));
  overflow: hidden;
  touch-action: pan-y;
  -webkit-user-select: none;
  user-select: none;
  cursor: grab;
  transition: transform .45s var(--onb-ease, ease), opacity .45s, border-color .3s, box-shadow .3s;
}
.onb-mail:focus { outline: none; }
.onb-mail:focus-visible { outline: 3px solid var(--wp--preset--color--red); outline-offset: 3px; }
.onb-mail.is-dragging { transition: none; cursor: grabbing; }
.onb-mail.is-answered { cursor: default; }
.onb-mail__bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--cream);
  font-size: 12px;
  font-weight: 600;
  color: var(--onbj-mute);
}
.onb-mail__dots { display: inline-flex; gap: 6px; }
.onb-mail__dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--wp--preset--color--red); opacity: .85; }
.onb-mail__dots i:nth-child(2) { background: var(--wp--preset--color--ochre); }
.onb-mail__dots i:nth-child(3) { background: var(--wp--preset--color--moss); }
.onb-mail__bar .onb-icon { width: 15px; height: 15px; }
.onb-mail__head { margin: 0; padding: 16px 20px 6px; display: grid; gap: 6px; }
.onb-mail__head > div { display: grid; grid-template-columns: 4.6em minmax(0, 1fr); gap: 8px; align-items: baseline; }
.onb-mail__head dt {
  font-family: var(--wp--preset--font-family--mono);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--onbj-mute);
}
.onb-mail__head dd { margin: 0; overflow-wrap: anywhere; font-size: 15px; }
.onb-mail__subject { font-weight: 700; color: var(--wp--preset--color--ink); }
.onb-mail__body { padding: 8px 20px 24px; color: var(--wp--preset--color--ink-soft); font-size: 15.5px; line-height: 1.55; }
.onb-mail__body p { margin: 0; }
.onb-mail__body p + p { margin-top: 8px; }
/* Inclinaison pendant le glisser : l'étiquette du côté choisi apparaît. */
.onb-mail::before,
.onb-mail::after {
  position: absolute;
  top: 54px;
  z-index: 5;
  padding: 6px 12px;
  border-radius: 8px;
  border: 3px solid currentColor;
  font-family: var(--wp--preset--font-family--display);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: .06em;
  background: rgba(255, 255, 255, .9);
  opacity: 0;
  pointer-events: none;
  transition: opacity .15s;
}
.onb-mail::before { content: "PHISHING ?"; right: 18px; color: var(--wp--preset--color--red); transform: rotate(10deg); }
.onb-mail::after { content: "FIABLE ?"; left: 18px; color: var(--wp--preset--color--moss); transform: rotate(-10deg); }
.onb-mail.lean-left::before,
.onb-mail.lean-right::after { opacity: 1; }
.onb-mail.is-right { border-color: var(--wp--preset--color--moss); }
.onb-mail.is-wrong { border-color: var(--wp--preset--color--red); }
.onb-mail.fly-left { transform: translateX(-135%) rotate(-20deg) !important; opacity: 0; }
.onb-mail.fly-right { transform: translateX(135%) rotate(20deg) !important; opacity: 0; }
.onb-mail__stamp {
  position: absolute;
  left: 50%;
  top: 46%;
  z-index: 6;
  width: min(250px, 66%);
  height: auto;
  overflow: visible;
  transform: translate(-50%, -50%) rotate(-14deg);
  pointer-events: none;
}
.onb-mail__stamp.is-phish { color: var(--wp--preset--color--red); }
.onb-mail__stamp.is-safe { color: var(--wp--preset--color--moss); }
.onb-mail__stamp rect { fill: rgba(255, 255, 255, .78); stroke: currentColor; }
.onb-mail__stamp text {
  fill: currentColor;
  font-family: var(--wp--preset--font-family--display, system-ui, sans-serif);
  font-weight: 800;
  font-size: 36px;
  letter-spacing: .04em;
}
.onb-phish__hint { margin: -4px 0 0; text-align: center; font-size: 12.5px; color: var(--onbj-mute); }
.onb-phish__hint kbd { margin-inline: 2px; }
.onb-phish__actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.onb-phish__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 18px;
  border-radius: 999px;
  border: 2px solid currentColor;
  background: var(--wp--preset--color--paper);
  font-family: var(--wp--preset--font-family--sans);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: transform .25s var(--onb-spring, ease), background-color .2s, color .2s, box-shadow .2s, opacity .2s;
}
.onb-phish__btn .onb-icon { width: 20px; height: 20px; }
.onb-phish__btn.is-phish { color: var(--wp--preset--color--red-dark); }
.onb-phish__btn.is-safe { color: var(--wp--preset--color--moss); }
.onb-phish__btn.is-phish:hover:not(:disabled) { background: var(--onb-red-fill, #E0161E); border-color: var(--onb-red-fill, #E0161E); color: #fff; }
.onb-phish__btn.is-safe:hover:not(:disabled) { background: var(--wp--preset--color--moss); border-color: var(--wp--preset--color--moss); color: #fff; }
.onb-phish__btn:disabled { opacity: .45; cursor: default; }
.onb-phish__feedback { display: grid; gap: 12px; justify-items: start; }
.onb-phish__feedback:empty { display: none; }
.onb-phish__verdict strong { font-weight: 800; }
.onb-phish__clues-title {
  margin: 4px 0 0;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--onbj-mute);
}
.onb-phish__clues { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; width: 100%; }
.onb-phish__clues li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--paper);
  font-size: 15px;
  line-height: 1.45;
}
.onb-phish__clues .onb-icon { width: 18px; height: 18px; margin-top: 2px; color: var(--wp--preset--color--indigo); }
.onb-phish__end {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 30px 22px;
  border-radius: var(--onb-radius-block, 22px);
  border: 1px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--paper);
  text-align: center;
}
.onb-phish__end > * { margin: 0; }
.onb-phish__end-visual { width: 132px; color: var(--wp--preset--color--indigo); }
.onb-phish__end-visual > .onb-icon { width: 72px; height: 72px; }
.onb-phish__end-score {
  font-family: var(--wp--preset--font-family--display);
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
}
.onb-phish__end-score span { font-size: .5em; color: var(--onbj-mute); }
.onb-phish .onb-phish__end-title {
  font-size: 1.5rem;
  font-weight: 800;
  outline: none;
}
.onb-phish__end p { max-width: 46ch; color: var(--wp--preset--color--ink-soft); }
.onb-phish__end-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
@media (max-width: 520px) {
  .onb-phish__actions { grid-template-columns: minmax(0, 1fr); }
  .onb-mail__head > div { grid-template-columns: minmax(0, 1fr); gap: 0; }
}

/* =========================================================
   PASSEPORT (en ligne et dans la boîte de dialogue)
   ========================================================= */
.onb-pass--inline { margin-top: var(--wp--preset--spacing--20); scroll-margin-top: calc(var(--onb-header-h, 72px) + 24px); }
.onb-pass--inline:focus { outline: none; }
.onb-pass__book {
  position: relative;
  overflow: hidden;
  border-radius: var(--onb-radius-block, 22px);
  border: 1px solid var(--wp--preset--color--line);
  background-color: #FFFDF7;
  background-image: radial-gradient(rgba(26, 26, 26, .055) 1px, transparent 1.2px);
  background-size: 16px 16px;
  box-shadow: var(--onb-shadow-md, 0 8px 24px rgba(20, 20, 20, .06));
}
.onb-pass__head {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px 18px;
  padding: 22px 26px;
  background-color: var(--wp--preset--color--ink);
  background-image: radial-gradient(520px circle at 100% 0%, rgba(237, 28, 36, .28), transparent 60%), repeating-linear-gradient(135deg, rgba(255, 255, 255, .025) 0 2px, transparent 2px 9px);
  color: #EDEAE2;
}
.onb-pass__emblem {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 2px dashed rgba(255, 255, 255, .35);
  color: var(--wp--preset--color--ochre);
}
.onb-pass__emblem .onb-icon { width: 26px; height: 26px; }
.onb-pass__titles > * { margin: 0; }
.onb-pass__kicker { font-size: 11.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: rgba(255, 255, 255, .68); }
.onb-pass .onb-pass__title {
  margin: 2px 0 0;
  font-size: clamp(1.4rem, 3vw, 1.8rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #fff;
}
.onb-pass__count { margin-top: 4px !important; font-size: 14.5px; color: #EDEAE2; }
.onb-pass__count strong { color: #fff; font-size: 1.15em; }
.onb-pass__bar {
  grid-column: 1 / -1;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .14);
  overflow: hidden;
}
.onb-pass__bar > span {
  display: block;
  height: 100%;
  width: var(--pct, 0%);
  border-radius: inherit;
  background: linear-gradient(90deg, var(--wp--preset--color--ochre), var(--wp--preset--color--red));
  transition: width 1s var(--onb-ease, ease-out);
}
.onb-pass__close {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .3);
  background: transparent;
  color: #fff;
  cursor: pointer;
  transition: background-color .2s, color .2s, transform .25s var(--onb-spring, ease);
}
.onb-pass__close:hover { background: #fff; color: var(--wp--preset--color--ink); }
.onb-pass__close .onb-icon { width: 20px; height: 20px; }
.onb-pass__close:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.onb-pass.is-complete .onb-pass__emblem { border-style: solid; border-color: var(--wp--preset--color--ochre); background: rgba(232, 165, 47, .15); }
.onb-pass__grid {
  list-style: none;
  margin: 0;
  padding: 26px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 24px 18px;
}
.onb-pass__cell {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 4px;
  padding: 6px 4px 10px;
  text-align: center;
}
.onb-pass__cell > * { margin: 0; }
.onb-pass__cell .onb-tampon { width: 112px; margin-bottom: 8px; }
.onb-pass .onb-pass__name {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.onb-pass__desc { font-size: 13px; line-height: 1.45; color: var(--wp--preset--color--ink-soft); }
.onb-pass__date {
  display: block;
  text-align: center;
  line-height: 1.4;
  margin-top: 4px !important;
  font-family: var(--wp--preset--font-family--mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--wp--preset--color--moss);
}
.onb-pass__date .onb-icon { display: inline-block; width: 14px; height: 14px; margin-right: 4px; vertical-align: -2px; }
.onb-pass__go,
a.onb-pass__go {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px !important;
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid var(--wp--preset--color--line);
  background: var(--wp--preset--color--paper);
  color: var(--wp--preset--color--ink);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition: border-color .2s, background-color .2s, color .2s;
}
.onb-pass__go:hover { border-color: var(--wp--preset--color--ink); background: var(--wp--preset--color--ink); color: #fff; }
.onb-pass__go .onb-icon { width: 14px; height: 14px; }
.onb-pass__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
  padding: 16px 26px 22px;
  border-top: 1px dashed var(--wp--preset--color--line);
}
.onb-pass__privacy {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  max-width: 60ch;
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--wp--preset--color--ink-soft);
}
.onb-pass__privacy .onb-icon { width: 16px; height: 16px; margin-top: 2px; flex: 0 0 auto; }
.onb-pass__confirm {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(237, 28, 36, .3);
  background: var(--wp--preset--color--red-soft);
}
.onb-pass__confirm[hidden] { display: none; }
.onb-pass__confirm p { margin: 0; font-size: 14px; font-weight: 600; color: #8E0A10; }

.onb-pass-dialog {
  width: min(960px, calc(100% - 32px));
  max-width: none;
  max-height: calc(100vh - 40px);
  max-height: calc(100dvh - 40px);
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: var(--onb-radius-block, 22px);
  background: transparent;
  color: var(--wp--preset--color--ink);
  box-shadow: 0 30px 80px rgba(20, 20, 20, .35);
  overflow: auto;
  overscroll-behavior: contain;
}
.onb-pass-dialog::backdrop {
  background: rgba(26, 26, 26, .55);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.onb-pass-dialog .onb-pass__book { border: 0; box-shadow: none; }
.onb-pass-dialog .onb-pass__head { position: sticky; top: 0; z-index: 2; }
html.onb-pass-open { overflow: hidden; }
@media (max-width: 600px) {
  .onb-pass__head { padding: 18px; grid-template-columns: auto minmax(0, 1fr) auto; }
  .onb-pass__emblem { width: 44px; height: 44px; }
  .onb-pass__grid { padding: 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 10px; }
  .onb-pass__cell .onb-tampon { width: 96px; }
  .onb-pass__foot { padding: 14px 18px 18px; }
  .onb-pass-dialog { width: calc(100% - 20px); max-height: calc(100vh - 20px); max-height: calc(100dvh - 20px); }
}

/* =========================================================
   MOMENT « TAMPON » (nouveau tampon : il claque au centre)
   ========================================================= */
.onb-stamp-moment {
  position: fixed;
  inset: 0;
  z-index: 1002;
  display: grid;
  place-items: center;
  padding: 20px;
  background: radial-gradient(circle at 50% 46%, rgba(255, 253, 247, .95) 0, rgba(250, 250, 247, .78) 38%, rgba(26, 26, 26, .28) 100%);
  opacity: 0;
  cursor: pointer;
  transition: opacity .3s ease;
}
.onb-stamp-moment.is-in { opacity: 1; }
.onb-stamp-moment.is-out,
.onb-stamp-moment.is-flying { opacity: 0; transition-duration: .5s; }
.onb-stamp-moment__inner { display: grid; justify-items: center; gap: 4px; text-align: center; }
.onb-stamp-moment__inner > * { margin: 0; }
.onb-stamp-moment__stamp {
  position: relative;
  width: min(240px, 58vw);
  transition: transform .55s cubic-bezier(.55, 0, .75, .2);
}
.onb-stamp-moment__stamp::after {
  content: "";
  position: absolute;
  inset: -6%;
  border-radius: 50%;
  border: 4px solid rgba(237, 28, 36, .5);
  opacity: 0;
}
.onb-stamp-moment.is-flying .onb-stamp-moment__stamp { transform: translate(var(--fx, 0), var(--fy, 0)) scale(.12) rotate(24deg); }
.onb-stamp-moment__kicker {
  margin-top: 14px !important;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--wp--preset--color--red-dark);
}
.onb-stamp-moment__name {
  font-family: var(--wp--preset--font-family--display);
  font-size: clamp(1.7rem, 4.5vw, 2.6rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--wp--preset--color--ink);
}
.onb-stamp-moment__hint { margin-top: 10px !important; font-size: 12.5px; color: var(--onbj-mute); }

/* =========================================================
   ANIMATIONS (désactivées si l'utilisateur réduit les mouvements)
   ========================================================= */
@keyframes onbj-slam {
  0% { opacity: 0; transform: rotate(var(--tilt, 0deg)) scale(2.3); }
  55% { opacity: 1; transform: rotate(var(--tilt, 0deg)) scale(.9); }
  75% { transform: rotate(var(--tilt, 0deg)) scale(1.05); }
  100% { opacity: 1; transform: rotate(var(--tilt, 0deg)) scale(1); }
}
@keyframes onbj-slam-big {
  0% { opacity: 0; transform: rotate(calc(var(--tilt, 0deg) - 25deg)) scale(3.2); filter: blur(4px); }
  60% { opacity: 1; transform: rotate(var(--tilt, 0deg)) scale(.88); filter: blur(0); }
  78% { transform: rotate(var(--tilt, 0deg)) scale(1.06); }
  100% { opacity: 1; transform: rotate(var(--tilt, 0deg)) scale(1); }
}
@keyframes onbj-verdict-slam {
  0% { opacity: 0; transform: translate(-50%, -50%) rotate(-30deg) scale(2.6); }
  60% { opacity: 1; transform: translate(-50%, -50%) rotate(-14deg) scale(.9); }
  80% { transform: translate(-50%, -50%) rotate(-14deg) scale(1.05); }
  100% { opacity: 1; transform: translate(-50%, -50%) rotate(-14deg) scale(1); }
}
@keyframes onbj-splash {
  0% { opacity: .9; transform: scale(.7); }
  100% { opacity: 0; transform: scale(1.5); }
}
@keyframes onbj-bounce {
  0% { transform: none; }
  30% { transform: translateY(-6px) scale(1.03); }
  55% { transform: translateY(0) scale(.98); }
  75% { transform: translateY(-2px) scale(1.01); }
  100% { transform: none; }
}
@keyframes onbj-shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-9px); }
  40% { transform: translateX(8px); }
  60% { transform: translateX(-6px); }
  80% { transform: translateX(4px); }
}
@keyframes onbj-in-right { from { opacity: 0; transform: translateX(48px); } to { opacity: 1; transform: none; } }
@keyframes onbj-out-left { to { opacity: 0; transform: translateX(-48px); } }
@keyframes onbj-fade-up { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes onbj-pop { from { opacity: 0; transform: translateY(16px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes onbj-card-in { from { opacity: .4; transform: translateY(9px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes onbj-thud {
  0%, 100% { transform: none; }
  20% { transform: translate(3px, 4px); }
  40% { transform: translate(-4px, -2px); }
  60% { transform: translate(2px, 2px); }
  80% { transform: translate(-1px, -1px); }
}
@keyframes onbj-bump {
  0%, 100% { transform: none; }
  30% { transform: scale(1.18) rotate(-6deg); }
  60% { transform: scale(.95) rotate(3deg); }
}
@keyframes onbj-float {
  0%, 100% { transform: translateY(0) rotate(0); }
  50% { transform: translateY(-8px) rotate(-3deg); }
}
@keyframes onbj-score-pop {
  0% { transform: scale(1); }
  40% { transform: scale(1.3); }
  100% { transform: scale(1); }
}
@keyframes onbj-pulse {
  0% { box-shadow: 0 0 0 0 rgba(237, 28, 36, .45); }
  70% { box-shadow: 0 0 0 14px rgba(237, 28, 36, 0); }
  100% { box-shadow: 0 0 0 0 rgba(237, 28, 36, 0); }
}
@keyframes onbj-flash {
  0% { box-shadow: 0 0 0 0 rgba(237, 28, 36, .5); }
  100% { box-shadow: 0 0 0 18px rgba(237, 28, 36, 0); }
}

@media (prefers-reduced-motion: no-preference) {
  .onb-jeu-btn:hover { transform: translateY(-2px) scale(1.03); }
  .onb-quiz__choice:hover:not(:disabled) { transform: translateX(4px); }
  .onb-quiz-card:hover .onb-quiz-card__stamp .onb-tampon { transform: rotate(calc(var(--tilt, 0deg) - 14deg)) scale(1.07); }
  .onb-pass__close:hover { transform: rotate(90deg); }
  .onb-jeu-btn:active { transform: scale(.96); }
  .onb-quiz__go { animation: onbj-pulse 2.4s ease-out 1.2s infinite; }
  .onb-quiz__visual .onb-tampon { animation: onbj-slam .7s var(--onb-ease, ease-out) .2s both; }
  .onb-quiz__visual { animation: onbj-float 6s ease-in-out 1.2s infinite; }
  .onb-quiz__start,
  .onb-quiz__result { animation: onbj-pop .45s var(--onb-ease, ease-out) both; }
  .onb-quiz__card.is-entering { animation: onbj-in-right .4s var(--onb-ease, ease-out) both; }
  .onb-quiz__card.is-leaving { animation: onbj-out-left .25s ease-in both; }
  .onb-quiz__card.is-entering .onb-quiz__choice { animation: onbj-fade-up .4s var(--onb-ease, ease-out) both; animation-delay: calc(.08s + var(--i, 0) * .06s); }
  .onb-quiz__choice.is-right { animation: onbj-bounce .6s var(--onb-spring, ease) both; }
  .onb-quiz__choice.is-right .onb-quiz__letter { animation: onbj-score-pop .5s var(--onb-spring, ease); }
  .onb-quiz__choice.is-wrong { animation: onbj-shake .45s ease both; }
  .onb-quiz__feedback > * { animation: onbj-fade-up .35s var(--onb-ease, ease-out) both; }
  .onb-quiz__feedback > :nth-child(2) { animation-delay: .08s; }
  .onb-quiz__feedback > :nth-child(3) { animation-delay: .16s; }
  .onb-quiz__result-stamp .onb-tampon { animation: onbj-slam .65s var(--onb-ease, ease-out) .5s both; }
  .onb-quiz-card .onb-tampon.is-earned { animation: onbj-slam .6s var(--onb-ease, ease-out) both; animation-delay: calc(.2s + var(--i, 0) * .12s); }
  .onb-phish.is-start .onb-phish__stack { animation: onbj-pop .5s var(--onb-ease, ease-out) both; }
  .onb-mail.is-entering { animation: onbj-card-in .4s var(--onb-ease, ease-out) both; }
  .onb-mail.is-wrong { animation: onbj-shake .45s ease .15s both; }
  .onb-mail__stamp { animation: onbj-verdict-slam .45s cubic-bezier(.2, .9, .3, 1.2) both; }
  .onb-phish__score.is-pop { animation: onbj-score-pop .45s var(--onb-spring, ease); }
  .onb-phish__feedback > * { animation: onbj-fade-up .35s var(--onb-ease, ease-out) both; }
  .onb-phish__clues li { animation: onbj-fade-up .4s var(--onb-ease, ease-out) both; animation-delay: calc(.1s + var(--i, 0) * .09s); }
  .onb-phish__end { animation: onbj-pop .45s var(--onb-ease, ease-out) both; }
  .onb-phish__end-visual .onb-tampon { animation: onbj-slam .65s var(--onb-ease, ease-out) .3s both; }
  .onb-pass-dialog[open] { animation: onbj-pop .35s var(--onb-spring, ease) both; }
  .onb-pass-dialog[open]::backdrop { animation: onb-fade-in .25s ease-out; }
  .onb-pass.is-animating .onb-pass__cell.is-earned .onb-tampon { animation: onbj-slam .55s var(--onb-ease, ease-out) both; animation-delay: calc(.15s + var(--i, 0) * .09s); }
  .onb-pass.is-animating .onb-pass__cell.is-locked { animation: onbj-fade-up .4s var(--onb-ease, ease-out) both; animation-delay: calc(.1s + var(--i, 0) * .05s); }
  .onb-pass__cell:hover .onb-tampon { transform: rotate(calc(var(--tilt, 0deg) - 10deg)) scale(1.06); }
  .onb-pass__cell .onb-tampon { transition: transform .4s var(--onb-spring, ease); }
  .onb-pass--inline.is-flash .onb-pass__book { animation: onbj-flash .9s ease-out 2; }
  .onb-stamp-moment.is-in .onb-tampon { animation: onbj-slam-big .5s cubic-bezier(.2, .9, .3, 1.15) both; }
  .onb-stamp-moment.is-in .onb-stamp-moment__stamp::after { animation: onbj-splash .6s ease-out .3s both; }
  .onb-stamp-moment.is-in .onb-stamp-moment__kicker { animation: onbj-fade-up .4s var(--onb-ease, ease-out) .45s both; }
  .onb-stamp-moment.is-in .onb-stamp-moment__name { animation: onbj-fade-up .4s var(--onb-ease, ease-out) .55s both; }
  .onb-stamp-moment.is-in .onb-stamp-moment__hint { animation: onbj-fade-up .4s var(--onb-ease, ease-out) .9s both; }
  html.onb-thud .wp-site-blocks { animation: onbj-thud .35s ease-out; }
  .onb-bump { animation: onbj-bump .6s var(--onb-spring, ease); }
}

/* Impression : les questions et les e-mails d'origine, sans les jeux. */
@media print {
  .onb-jeu-source { display: block !important; }
  .onb-quiz__stage,
  .onb-phish,
  .onb-pass__foot,
  .onb-pass-dialog,
  .onb-stamp-moment { display: none !important; }
  .is-style-onb-question,
  .is-style-onb-mail,
  .onb-pass__cell { break-inside: avoid; }
}
