/* Theras · page d'aide (aide.theras.fr).
   Reprend la direction artistique du site (css/site.css) : encre, Manrope, pilules,
   cartes surface à 20 px, rosaces. Seule la mise en page de lecture est propre ici. */

/* ---------- En-tête de la page ---------- */
.aide-hero {
  position: relative; isolation: isolate; overflow: clip;
  padding: calc(72px + clamp(64px, 10vh, 120px)) var(--m) clamp(56px, 8vh, 96px);
}
.aide-hero__seal {
  position: absolute; z-index: -1; pointer-events: none;
  width: 90vh; height: 90vh; right: -22vh; top: -18vh; opacity: 0.55;
  -webkit-mask-image: radial-gradient(closest-side, #000 50%, transparent 100%); /* taste-skill-ignore: DA du site, la rosace s'efface sans bord dur */
          mask-image: radial-gradient(closest-side, #000 50%, transparent 100%); /* taste-skill-ignore: DA du site, la rosace s'efface sans bord dur */
}
.kicker { display: inline-flex; align-items: center; gap: 8px; font-size: var(--s-small); font-weight: 600; color: #b3c8ff; }
.kicker::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--cobalt); }
.aide-hero h1 { margin-top: 20px; font-size: var(--s-title); font-weight: 700; line-height: 1; letter-spacing: -0.035em; max-width: 14em; }
.aide-hero .lead { margin-top: 24px; color: var(--muted); }

/* Trois portes d'entrée, une par rôle */
.roles { margin-top: 48px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); max-width: 1120px; }
.role {
  display: grid; grid-template-columns: 44px 1fr; gap: 6px 16px; align-items: start;
  padding: 22px 22px 24px; border-radius: var(--r); background: var(--surface);
  text-decoration: none; transition: background-color 300ms ease, transform 400ms var(--ease-out);
}
.role:hover { background: var(--cobalt-field); transform: translateY(-3px); }
.role__glyph { grid-row: span 2; width: 44px; height: 44px; }
.role__glyph .ros__ring { stroke: var(--tone, var(--cobalt)); }
.role b { font-size: 19px; font-weight: 700; letter-spacing: -0.01em; }
.role span { font-size: var(--s-small); color: var(--muted); line-height: 1.45; }

/* ---------- Lecture : sommaire collant + contenu ---------- */
.doc {
  padding: 0 var(--m) clamp(96px, 14vh, 160px);
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 24px; align-items: start;
}
.toc { grid-column: 1 / span 3; position: sticky; top: 104px; display: grid; gap: 2px; }
.toc__h { font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.toc a {
  display: block; padding: 8px 14px; border-radius: 999px;
  font-size: var(--s-small); font-weight: 500; color: var(--muted); text-decoration: none;
  transition: color var(--t-hover) ease, background-color var(--t-ui) ease;
}
.toc a.is-sub { padding-left: 28px; font-size: 14px; }
.toc a:hover { color: var(--text); }
.toc a.is-current { color: var(--text); background: var(--raised); }
.content { grid-column: 4 / span 9; max-width: 860px; display: grid; gap: clamp(88px, 12vh, 140px); }

.part { scroll-margin-top: 96px; }
.part > h2 { font-size: var(--s-title); font-weight: 700; letter-spacing: -0.035em; line-height: 1; }
.part > .lead { margin-top: 20px; color: var(--muted); }
.part h3 { scroll-margin-top: 96px; margin: 56px 0 16px; font-size: var(--s-head); font-weight: 700; letter-spacing: -0.02em; line-height: 1.15; }
.part h4 { margin: 28px 0 10px; font-size: 19px; font-weight: 700; letter-spacing: -0.01em; }
.part p, .part li { color: #d5dcd8; line-height: 1.6; }
.part p + p { margin-top: 14px; }
.part strong { color: var(--text); font-weight: 650; }
.part a:not(.button):not(.link) { color: #c8d6ff; text-underline-offset: 3px; }

/* Listes à puces et numérotées, dans le ton du site */
.dots, .steps { display: grid; gap: 10px; margin-top: 16px; }
.dots li { position: relative; padding-left: 22px; }
.dots li::before { content: ''; position: absolute; left: 2px; top: 0.62em; width: 7px; height: 7px; border-radius: 50%; background: var(--cobalt); }
.steps { counter-reset: s; }
.steps li { position: relative; padding-left: 44px; counter-increment: s; min-height: 30px; }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: -1px;
  width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center;
  background: var(--cobalt-field); color: #b3c8ff; font-size: 14px; font-weight: 700;
}
.check li::before { content: ''; width: 16px; height: 16px; left: 0; top: 0.3em; border-radius: 5px; background: transparent; box-shadow: inset 0 0 0 2px #3b4846; }

/* Cartes et encadrés */
.cards { margin-top: 24px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); }
.card { padding: 24px; border-radius: var(--r); background: var(--surface); }
.card h4 { margin: 0 0 8px; }
.card p { font-size: var(--s-small); }
.card .dots { margin-top: 12px; }
.card .dots li { font-size: var(--s-small); }
.card--wide { grid-column: 1 / -1; }
.note {
  margin-top: 24px; padding: 18px 22px; border-radius: var(--r);
  background: var(--cobalt-field); color: #dbe5ff; font-size: var(--s-small); line-height: 1.55;
}
.note b { color: #ffffff; }
.note.is-warn { background: var(--review-field); color: var(--review-ink); }
.note.is-warn b { color: #ffe2ad; }

/* Le trajet en trois pastilles */
.flow { margin-top: 32px; display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: stretch; gap: 10px; }
.flow__box { padding: 20px; border-radius: var(--r); background: var(--surface); }
.flow__box b { display: block; font-size: 19px; font-weight: 700; }
.flow__box span { display: block; margin-top: 6px; font-size: 14px; color: var(--muted); line-height: 1.45; }
.flow__box.is-theras { background: var(--cobalt-field); }
.flow__box.is-theras b { color: #ffffff; }
.flow__arrow { align-self: center; color: var(--muted); font-size: 22px; }
.verdicts { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 8px; }

/* Blocs de commandes */
.code {
  position: relative; margin-top: 16px; border-radius: 16px; background: var(--surface);
  font-family: var(--mono); font-size: 14px; line-height: 1.6; color: #dbe5ff; /* taste-skill-ignore: DA de la console (Geist Mono pour le code) */
}
.code pre { margin: 0; padding: 18px 64px 18px 20px; overflow-x: auto; white-space: pre; }
.code .c { color: #7f8b86; }
.copy {
  position: absolute; top: 10px; right: 10px; min-height: 30px; padding: 0 12px;
  border: 0; border-radius: 999px; background: var(--hover); color: var(--muted);
  font-family: var(--font); font-size: 13px; font-weight: 600; cursor: pointer;
  transition: color var(--t-hover) ease, background-color var(--t-hover) ease;
}
.copy:hover { color: var(--text); background: var(--step-4); }
.copy.is-done { color: var(--allow-ink); }
code.inline { font-family: var(--mono); font-size: 0.88em; padding: 2px 7px; border-radius: 6px; background: rgba(236, 242, 238, 0.07); color: var(--text); overflow-wrap: anywhere; } /* taste-skill-ignore: DA de la console */

/* Choix du parcours / de l'agent (onglets en pilules) */
.tabs { margin-top: 28px; display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: 999px; background: var(--surface); }
.tabs button {
  min-height: 42px; padding: 0 20px; border: 0; border-radius: 999px; background: transparent;
  color: var(--muted); font-size: var(--s-small); font-weight: 600; cursor: pointer;
  transition: color var(--t-hover) ease, background-color var(--t-ui) ease;
}
.tabs button:hover { color: var(--text); }
.tabs button[aria-selected="true"] { background: var(--text); color: var(--ink); }
[role="tabpanel"] { margin-top: 8px; }
[role="tabpanel"][hidden] { display: none; }

/* Étapes repliables : mêmes cartes que les questions du site */
.fold { margin-top: 20px; display: grid; gap: var(--gap); }
.fold summary { font-size: 19px; min-height: 68px; padding: 18px 24px; }
.fold summary small { display: block; margin-top: 2px; font-size: 14px; font-weight: 500; color: var(--muted); }
.fold .answer > div { padding: 0 24px 26px; }
.fold .answer p, .fold .answer li { font-size: var(--s-small); }
.fold .answer p { padding: 0; max-width: none; }
.fold details[open] .answer .code { background: rgba(11, 15, 14, 0.55); }

/* Questions en bas de page : reprise de .questions, sur la colonne de contenu */
.content .questions { padding: 0; display: block; }
.content .questions__title { position: static; }
.content .questions__list { margin-top: 32px; }

@media (max-width: 1100px) {
  .roles { grid-template-columns: 1fr; max-width: 560px; }
  .toc { display: none; }
  .content { grid-column: 1 / -1; }
  .cards { grid-template-columns: 1fr; }
}
@media (max-width: 767px) {
  .aide-hero__seal { width: 70vh; height: 70vh; right: -40vh; }
  .flow { grid-template-columns: 1fr; }
  .flow__arrow { transform: rotate(90deg); justify-self: center; }
  .tabs { display: flex; border-radius: 22px; }
  .tabs button { flex: 1 1 auto; }
  .bar__nav { display: none; }
  .bar { grid-template-columns: 1fr auto; }
}
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-expo); }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
}
