/* Feuille commune aux pages JPS Contrôle × Tulip Conseil (propal.jps.tulip-saas.fr).
   Servie sous /commun.css. Une page peut ajouter ses propres règles dans un <style> placé après le lien. */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&family=Space+Grotesk:wght@400;500;600;700&display=swap");

:root {
  --paper: #fbf9f3;
  --paper-deep: #f4f1e8;
  --ink: #161616;
  --ink-soft: #5c5c58;
  --ink-muted: #8a8a85;
  --hairline: #dcdad2;
  --hairline-soft: #eae7dd;
  --teal: #0a8f86;
  --teal-soft: #e5f2f1;
  --gold: #c9a961;
  --gold-soft: #f7f1e2;
  --dev: #b85c38;
  --dev-soft: #f6e9e3;
  --green: #1b7a3c;
  --green-soft: #e4f1e8;
  --display: "Space Grotesk", sans-serif;
  --body: "Inter", sans-serif;
  --mono: "JetBrains Mono", monospace;
}
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
body {
  font-family: var(--body);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 3rem 1.5rem 5rem;
}
.wrap .eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-muted);
}
.wrap .eyebrow a {
  color: var(--teal);
  text-decoration: none;
}
.wrap .eyebrow a:hover {
  text-decoration: underline;
}
.wrap h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0.75rem 0 1rem;
}
.wrap h2 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.4rem;
  letter-spacing: -0.01em;
  margin: 3.5rem 0 0.4rem;
}
.wrap .lede {
  color: var(--ink-soft);
  max-width: 70ch;
}
.wrap .lede strong {
  color: var(--ink);
  font-weight: 600;
}

/* ---------- Synthèse ---------- */
.kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--hairline);
  border: 1px solid var(--hairline);
  margin-top: 2.5rem;
}
.kpi {
  background: var(--paper);
  padding: 1.25rem 1.25rem 1.1rem;
}
.kpi-value {
  font-family: var(--display);
  font-size: 2.2rem;
  font-weight: 600;
  line-height: 1;
}
.kpi-value small {
  font-size: 1rem;
  color: var(--ink-muted);
  font-weight: 500;
}
.kpi-label {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.kpi.done .kpi-value {
  color: var(--green);
}
.kpi.wip .kpi-value {
  color: var(--teal);
}
.kpi.wait .kpi-value {
  color: var(--dev);
}

.bar {
  display: flex;
  height: 10px;
  margin-top: 1.25rem;
  border-radius: 2px;
  overflow: hidden;
  background: var(--hairline-soft);
}
.bar span {
  display: block;
  height: 100%;
}
.bar-note {
  margin-top: 0.5rem;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
}

/* ---------- Statuts ---------- */
.pill {
  display: inline-block;
  white-space: nowrap;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid;
}
.s-fait {
  color: var(--green);
  background: var(--green-soft);
  border-color: #bcdcc6;
}
.s-cours {
  color: var(--teal);
  background: var(--teal-soft);
  border-color: #b5dcd8;
}
.s-afaire {
  color: var(--ink-soft);
  background: var(--paper-deep);
  border-color: var(--hairline);
}
.s-attente {
  color: var(--dev);
  background: var(--dev-soft);
  border-color: #e6c6b8;
}
.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin-top: 1.25rem;
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.legend div {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ---------- Tableau par jalon ---------- */
.jalon {
  margin-top: 2.25rem;
}
.jalon-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.25rem 1rem;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--ink);
}
.jalon-code {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--teal);
  font-weight: 500;
}
.jalon-title {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.1rem;
}
.jalon-meta {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
}
.jalon.now .jalon-head {
  border-bottom-color: var(--teal);
}
.now-tag {
  font-family: var(--mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--paper);
  background: var(--teal);
  padding: 2px 6px;
  border-radius: 2px;
}

.wrap table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.wrap th {
  text-align: left;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-muted);
  padding: 0.7rem 0.75rem 0.5rem;
  border-bottom: 1px solid var(--hairline);
}
.wrap td {
  padding: 0.85rem 0.75rem;
  border-bottom: 1px solid var(--hairline-soft);
  vertical-align: top;
}
.wrap td.lot {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-soft);
  white-space: nowrap;
  width: 4.5rem;
}
.wrap td.title {
  font-weight: 600;
  width: 24%;
}
.wrap td.charge {
  font-family: var(--mono);
  font-size: 12px;
  white-space: nowrap;
  width: 3.5rem;
}
.wrap td.status {
  width: 7rem;
}
.wrap td.comment {
  color: var(--ink-soft);
}
.wrap td.comment b {
  color: var(--ink);
  font-weight: 600;
}
.frb {
  margin: 0 0 0.3rem;
}
.frb .k {
  display: inline-block;
  min-width: 3.6rem;
  font-weight: 600;
  color: var(--ink);
}
.frb.bloque,
.frb.bloque .k {
  color: var(--dev);
}
.proof {
  display: block;
  margin-top: 0.35rem;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
}

/* ---------- Attentes ---------- */
.waits {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--hairline);
  border: 1px solid var(--hairline);
  margin-top: 1.5rem;
}
.wait-block {
  background: var(--paper);
  padding: 1.25rem;
}
.wait-block h3 {
  font-family: var(--display);
  font-size: 1rem;
  font-weight: 600;
}
.wait-block .who {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dev);
  margin: 0.15rem 0 0.75rem;
}
.wait-block ul {
  list-style: none;
}
.wait-block li {
  position: relative;
  padding-left: 1.1rem;
  font-size: 0.88rem;
  color: var(--ink-soft);
  margin-bottom: 0.45rem;
}
.wait-block li::before {
  content: "○";
  position: absolute;
  left: 0;
  color: var(--dev);
  font-size: 0.8rem;
  top: 0.1rem;
}
.wait-block li b {
  color: var(--ink);
  font-weight: 600;
}
.wait-block .lots {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
}

.extras {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--ink-soft);
}
.extras li {
  margin: 0.35rem 0 0.35rem 1.1rem;
}
.wrap footer {
  margin-top: 4rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--hairline);
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem;
}
.wrap footer a {
  color: var(--teal);
  text-decoration: none;
}

@media (max-width: 760px) {
  .wrap {
    padding: 2rem 1rem 4rem;
  }
  .kpis {
    grid-template-columns: repeat(2, 1fr);
  }
  .waits {
    grid-template-columns: 1fr;
  }
  .jalon-meta {
    margin-left: 0;
    width: 100%;
  }
  .wrap thead {
    display: none;
  }
  .wrap table,
  .wrap tbody,
  .wrap tr,
  .wrap td {
    display: block;
    width: 100% !important;
  }
  .wrap tr {
    padding: 0.9rem 0;
    border-bottom: 1px solid var(--hairline);
  }
  .wrap td {
    border: 0;
    padding: 0.15rem 0;
  }
  .wrap td.lot,
  .wrap td.charge {
    display: inline-block;
    width: auto !important;
    margin-right: 0.75rem;
  }
  .wrap td.status {
    margin: 0.3rem 0;
  }
}
@media print {
  body {
    background: #fff;
  }
  .wrap {
    padding: 0;
  }
  .jalon {
    break-inside: avoid;
  }
}

.doc h2 {
  margin-top: 2.5rem;
}
.doc h3 {
  font-family: var(--display);
  font-size: 1.05rem;
  margin: 2rem 0 0.6rem;
  color: var(--teal);
}
.doc p {
  margin: 0.6rem 0;
  max-width: 72ch;
}
.doc ul {
  margin: 0.5rem 0 1rem 1.2rem;
}
.doc li {
  margin: 0.25rem 0;
}
.doc table {
  margin: 0.8rem 0 1.4rem;
}
.doc td,
.doc th {
  vertical-align: top;
}
.doc td:first-child {
  font-family: var(--mono);
  color: var(--ink-muted);
  white-space: nowrap;
}
.doc code {
  font-family: var(--mono);
  font-size: 0.85em;
  background: var(--paper-deep);
  padding: 0 0.25em;
  border-radius: 3px;
}
.prio {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  padding: 1px 7px;
  border-radius: 99px;
  white-space: nowrap;
}
.p1 {
  background: var(--dev-soft);
  color: var(--dev);
}
.p2 {
  background: var(--gold-soft);
  color: #8a6d2a;
}
.p3 {
  background: var(--paper-deep);
  color: var(--ink-soft);
}
.doc input[type="checkbox"] {
  margin-right: 0.4rem;
  accent-color: var(--teal);
}

.todo {
  list-style: none;
  margin: 0.4rem 0 1.2rem;
  padding: 0;
}
.todo li {
  display: grid;
  grid-template-columns: 1.4rem 1fr auto;
  gap: 0.2rem 0.6rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--hairline-soft);
}
.todo li::before {
  content: "";
  width: 14px;
  height: 14px;
  margin-top: 0.3rem;
  border: 1.5px solid var(--teal);
  border-radius: 4px;
  background: var(--paper);
  box-sizing: border-box;
}
.todo .q {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
  white-space: nowrap;
  padding-top: 0.2rem;
}
.todo .why {
  grid-column: 2 / 4;
  color: var(--ink-soft);
  font-size: 0.92em;
}
.callout {
  background: var(--teal-soft);
  border-left: 3px solid var(--teal);
  padding: 0.9rem 1.1rem;
  margin: 1.2rem 0;
  border-radius: 0 6px 6px 0;
  max-width: 78ch;
}
.doc a {
  color: var(--teal);
}

/* ---------- Trame de séance (atelier-1.html, <body class="trame">) ---------- */
.trame .nav {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgba(251, 249, 243, 0.94);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--hairline);
}
.trame .nav .in {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0.6rem 1.5rem;
  display: flex;
  gap: 0.4rem;
  overflow-x: auto;
  scrollbar-width: none;
}
.trame .nav a {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-soft);
  text-decoration: none;
  padding: 0.35rem 0.75rem;
  border-radius: 99px;
  white-space: nowrap;
  border: 1px solid transparent;
}
.trame .nav a:hover,
.trame .nav a.on {
  color: var(--teal);
  border-color: #b5dcd8;
  background: var(--teal-soft);
}
.trame .timeline {
  display: flex;
  gap: 4px;
  margin: 2rem 0 0;
}
.trame .timeline a {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
  padding: 0.7rem 0.75rem;
  background: var(--teal-soft);
  border-top: 3px solid var(--teal);
  text-decoration: none;
  color: var(--ink);
}
.trame .timeline a:nth-child(1) {
  background: var(--gold-soft);
  border-color: var(--gold);
}
.trame .timeline b {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--teal);
  font-weight: 500;
}
.trame .timeline a:nth-child(1) b {
  color: #8a6d2a;
}
.trame .timeline span {
  font-size: 0.85rem;
  line-height: 1.3;
}
.trame section {
  scroll-margin-top: 3.5rem;
}
.trame .wrap h2 .num {
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--teal);
  margin-right: 0.6rem;
  vertical-align: middle;
}
.trame .wrap h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.15rem;
  margin: 2.2rem 0 0.3rem;
  scroll-margin-top: 3.5rem;
}
.trame .sub {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
  margin-bottom: 0.4rem;
}
.trame .panel {
  border: 1px solid var(--hairline);
  background: #fff;
  border-radius: 10px;
  padding: 1.6rem 1.6rem 1.4rem;
  margin-top: 1.4rem;
}
.trame .panel h3 {
  margin-top: 0.1rem;
}
.trame .pn {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 0.06em;
}
.trame .fig {
  margin: 1.2rem 0 0.6rem;
  overflow-x: auto;
}
.trame .fig svg {
  display: block;
  width: 100%;
  min-width: 620px;
  height: auto;
  max-height: 340px;
}
.trame .fig svg text {
  font-family: var(--body);
}
.trame .odoo {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.6rem;
  margin-top: 0.8rem;
}
.trame .odoo .cap {
  grid-column: 1/-1;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #8a6d2a;
}
.trame .odoo div {
  background: var(--paper);
  border: 1px solid var(--hairline-soft);
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
}
.trame .odoo dt {
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--teal);
}
.trame .odoo dd {
  font-size: 0.86rem;
  color: var(--ink-soft);
  margin-top: 0.15rem;
}
.trame .k {
  font-family: var(--mono);
  font-size: 0.78rem;
  background: var(--teal-soft);
  color: var(--ink);
  padding: 0 0.35rem;
  border-radius: 4px;
}
.trame .steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1.4rem;
  counter-reset: s;
}
.trame .step {
  background: #fff;
  border: 1px solid var(--hairline);
  border-radius: 10px;
  padding: 1.1rem 1.1rem 1rem;
  position: relative;
}
.trame .sn {
  display: inline-grid;
  place-items: center;
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 50%;
  background: var(--teal);
  color: #fff;
  font-family: var(--mono);
  font-size: 12px;
}
.trame .step h4 {
  font-family: var(--display);
  font-size: 1.02rem;
  margin: 0.6rem 0 0.3rem;
}
.trame .step p {
  font-size: 0.9rem;
  color: var(--ink-soft);
}
.trame .step .where {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
  margin-top: 0.5rem;
}
.trame .qtags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: 0.7rem;
}
.trame .qtag {
  font-family: var(--mono);
  font-size: 11px;
  padding: 1px 8px;
  border-radius: 99px;
  background: var(--gold-soft);
  color: #8a6d2a;
  border: 1px solid #e8d9b3;
  text-decoration: none;
}
.trame .qtag:hover {
  background: var(--gold);
  color: #fff;
}
.trame .filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 1.2rem;
}
.trame .filters button {
  font-family: var(--mono);
  font-size: 12px;
  padding: 0.3rem 0.8rem;
  border-radius: 99px;
  border: 1px solid var(--hairline);
  background: #fff;
  color: var(--ink-soft);
  cursor: pointer;
}
.trame .filters button.on {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.trame .qlist {
  list-style: none;
  border-top: 1px solid var(--hairline);
}
.trame .qrow {
  display: grid;
  grid-template-columns: 2.2rem 2.6rem 1fr auto;
  gap: 0.2rem 0.8rem;
  align-items: start;
  padding: 0.85rem 0.4rem;
  border-bottom: 1px solid var(--hairline-soft);
  scroll-margin-top: 4rem;
  transition: background 0.3s;
}
.trame .qrow:target {
  background: var(--gold-soft);
}
.trame .qn {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--gold);
  line-height: 1.2;
}
.trame .qrow .prio {
  margin-top: 0.2rem;
  justify-self: start;
}
.trame .qbody b {
  display: block;
  font-weight: 600;
  margin-bottom: 0.1rem;
}
.trame .qbody span {
  color: var(--ink-soft);
  font-size: 0.92rem;
}
.trame .qwhy {
  margin-top: 0.35rem;
  font-size: 0.88rem;
  color: var(--ink-soft);
}
.trame .qwhy summary {
  cursor: pointer;
  width: fit-content;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--teal);
}
.trame .qwhy p {
  margin: 0.4rem 0 0;
}
.trame .qwhy .pq {
  padding-left: 0.7rem;
  border-left: 2px solid var(--hairline);
}
.trame .dafl {
  list-style: disc;
  padding-left: 1.2rem;
}
.trame .dafl li {
  margin: 0.3rem 0;
}
.trame .lede a,
.trame .next a {
  color: var(--teal);
}
.trame .done {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
  cursor: pointer;
  margin-top: 0.2rem;
  white-space: nowrap;
}
.trame .done input,
.trame .decs input {
  accent-color: var(--teal);
  width: 15px;
  height: 15px;
}
.trame .qrow.is-done {
  opacity: 0.5;
}
.trame .qrow.is-done .qbody b {
  text-decoration: line-through;
}
.trame .qrow.hide {
  display: none;
}
.trame .decs {
  list-style: none;
  columns: 2;
  column-gap: 2rem;
  margin-top: 1.2rem;
}
.trame .decs li {
  break-inside: avoid;
  border-bottom: 1px solid var(--hairline-soft);
  padding: 0.6rem 0;
}
.trame .decs label {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  cursor: pointer;
  font-size: 0.93rem;
}
.trame .decs input {
  margin-top: 0.25rem;
  flex: none;
}
.trame .decs input:checked + span {
  color: var(--green);
}
.trame .next {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 1.6rem;
}
.trame .next div {
  background: var(--teal-soft);
  border-radius: 10px;
  padding: 1rem 1.2rem;
}
.trame .next h4 {
  font-family: var(--display);
  font-size: 1rem;
  margin-bottom: 0.3rem;
}
.trame .next p {
  font-size: 0.9rem;
  color: var(--ink-soft);
}
.trame .progress {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
  margin-left: auto;
  align-self: center;
  white-space: nowrap;
}
.trame .flux {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 1rem;
  margin: 0.6rem 0 1.2rem;
}
.trame .fcol {
  border-radius: 10px;
  padding: 1rem 1.1rem;
  border: 1px solid var(--hairline-soft);
}
.trame .fcol.out {
  background: var(--gold-soft);
}
.trame .fcol.back {
  background: var(--teal-soft);
}
.trame .fh {
  font-size: 0.82rem;
  color: var(--ink-soft);
  margin-bottom: 0.6rem;
}
.trame .fh span {
  display: block;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.02rem;
  color: #8a6d2a;
}
.trame .fcol.back .fh span {
  color: var(--teal);
}
.trame .fcol ul {
  list-style: none;
}
.trame .fcol li {
  display: grid;
  grid-template-columns: 9.5rem 1fr;
  gap: 0.6rem;
  padding: 0.4rem 0;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  font-size: 0.88rem;
}
.trame .fcol li b {
  font-weight: 600;
}
.trame .fcol li span {
  color: var(--ink-soft);
}
.trame .fnote {
  margin-top: 0.7rem;
  font-size: 0.82rem;
  color: var(--ink-soft);
}
@media (max-width: 760px) {
  .trame .flux {
    grid-template-columns: 1fr;
  }
  .trame .fcol li {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .trame .nav .in {
    padding: 0.5rem 1rem;
  }
  .trame .timeline {
    flex-direction: column;
  }
  .trame .timeline a {
    flex: none !important;
  }
  .trame .steps {
    grid-template-columns: 1fr;
  }
  .trame .panel {
    padding: 1.1rem 1rem;
  }
  .trame .qrow {
    grid-template-columns: 2rem 1fr;
  }
  .trame .qrow .prio {
    grid-column: 2;
    grid-row: 1;
  }
  .trame .qbody {
    grid-column: 1/-1;
  }
  .trame .done {
    grid-column: 1/-1;
  }
  .trame .decs {
    columns: 1;
  }
  .trame .next {
    grid-template-columns: 1fr;
  }
  .trame .progress {
    display: none;
  }
}
@media print {
  .trame .nav,
  .trame .filters,
  .trame .done {
    display: none;
  }
  .trame .panel,
  .trame .step,
  .trame .qrow {
    break-inside: avoid;
  }
}
.trame .qlist.sans-num .qrow {
  grid-template-columns: 1fr;
}
