/* AI training pages (ai-training*.html, ai-office-setup.html, ai-talk.html).
   Loaded after v2.css; uses only v2 tokens, so light and dark themes both work.
   Training sits in part 2 of the business (custom software and services), so
   its accent is the custom-software teal. */

.training { --accent: var(--custom); }

/* Price facts at the top of a product page */
.facts { display: grid; gap: var(--space-2); margin: var(--space-3) 0 0; padding: 0; list-style: none; }
.facts li { background: var(--surface); border-top: 4px solid var(--line); border-radius: 0 0 var(--radius-sm) var(--radius-sm); padding: var(--space-2); }
.facts li:first-child { border-top-color: var(--accent); }
.facts .k { display: block; font-size: var(--step--1); color: var(--muted); font-weight: 600; }
.facts .v { display: block; font-weight: 650; }
.facts .v.price { font-family: var(--font-display); font-size: var(--step-3); font-weight: 750; letter-spacing: -0.02em; line-height: 1.1; }
@media (min-width: 48em) { .facts { grid-template-columns: repeat(4, 1fr); } }

/* Product cards on the hub */
.offer-grid { display: grid; gap: var(--space-3); list-style: none; padding: 0; margin: 0; }
@media (min-width: 56em) { .offer-grid { grid-template-columns: repeat(2, 1fr); } }
.offer { background: var(--surface); border-top: 6px solid var(--line); border-radius: 0 0 var(--radius) var(--radius); padding: var(--space-3); display: flex; flex-direction: column; gap: 0.5rem; }
.offer.lead-offer { border-top-color: var(--accent); }
.offer h3 { margin: 0; }
.offer h3 a { color: var(--ink); text-decoration: none; }
.offer h3 a:hover { text-decoration: underline; }
.offer .price { font-family: var(--font-display); font-size: var(--step-2); font-weight: 750; }
.offer .price small { font-family: var(--font-body); font-size: var(--step--1); font-weight: 500; color: var(--muted); }
.offer p { margin: 0; }
.offer .more { margin-top: auto; padding-top: 0.5rem; font-weight: 600; }

/* (a) Before and after */
.ba { display: grid; gap: var(--space-3); }
@media (min-width: 48em) { .ba { grid-template-columns: 1fr 1fr; } }
.ba-side { background: var(--surface); border-top: 6px solid var(--line); border-radius: 0 0 var(--radius) var(--radius); padding: var(--space-3); }
.ba-side.after { border-top-color: var(--accent); }
.ba-side h3 { font-size: var(--step-1); margin-bottom: var(--space-2); }
.ba-side.after h3 { color: var(--accent); }
.ba-side ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.75rem; }
.ba-side li { padding-left: 1.75rem; position: relative; }
.ba-side li::before { content: ""; position: absolute; left: 0; top: 0.55em; width: 0.75rem; height: 0.75rem; border-radius: 50%; border: 2px solid var(--muted); }
.ba-side.after li::before { background: var(--accent); border-color: var(--accent); }

/* (b) Three steps with a connecting line */
.flow { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-3); counter-reset: flow; }
.flow li { counter-increment: flow; position: relative; padding: var(--space-3); padding-top: calc(var(--space-3) + 2.75rem); background: var(--surface); border-radius: var(--radius); }
.flow li::before { content: counter(flow); position: absolute; left: var(--space-3); top: var(--space-3); width: 2.25rem; height: 2.25rem; border-radius: 50%; background: var(--accent); color: var(--bg); display: grid; place-items: center; font-family: var(--font-display); font-weight: 750; }
.flow .when { display: block; font-size: var(--step--1); color: var(--muted); font-weight: 650; }
.flow h3 { margin: 0.25rem 0 0.5rem; font-size: var(--step-1); }
.flow p { margin: 0; }
@media (min-width: 56em) {
  .flow { grid-template-columns: repeat(3, 1fr); }
  .flow li:not(:last-child)::after { content: ""; position: absolute; top: calc(var(--space-3) + 1.1rem); left: calc(var(--space-3) + 2.5rem); right: calc(-1 * var(--space-3)); height: 3px; background: var(--accent); opacity: 0.45; }
}

/* (c) Chooser table */
.chooser th[scope="row"] { font-weight: 650; }
.chooser td a { font-weight: 650; }
.chooser .pick { white-space: nowrap; }

/* (d) Safe-use card */
.safe-card { border: 3px solid var(--warn-line); background: var(--warn-bg); border-radius: var(--radius); padding: var(--space-3); }
.safe-card h3 { font-size: var(--step-2); margin-bottom: var(--space-2); }
.safe-card ol { margin: 0; padding: 0; list-style: none; counter-reset: safe; display: grid; gap: 0.75rem; }
.safe-card li { counter-increment: safe; padding-left: 2.75rem; position: relative; }
.safe-card li::before { content: counter(safe); position: absolute; left: 0; top: 0; width: 2rem; height: 2rem; border-radius: 50%; border: 2px solid var(--warn-line); display: grid; place-items: center; font-weight: 750; }
.safe-card li strong { display: block; }
.safe-card .note { margin-top: var(--space-2); color: var(--ink); }
@media (min-width: 56em) { .safe-card ol { grid-template-columns: 1fr 1fr; } }

/* Three parts of JMS Dev Lab */
.parts { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-2); }
@media (min-width: 48em) { .parts { grid-template-columns: repeat(3, 1fr); } }
.parts li { border-top: 4px solid var(--part); padding-top: 0.75rem; }
.parts li.here { background: var(--surface); padding: 0.75rem var(--space-2) var(--space-2); border-radius: 0 0 var(--radius-sm) var(--radius-sm); }
.parts h3 { font-size: var(--step-1); margin-bottom: 0.25rem; }
.parts p { margin: 0; color: var(--muted); }

.enquire { background: var(--surface); border-radius: var(--radius); padding: var(--space-4) var(--space-3); }
.enquire h2 { margin-bottom: var(--space-2); }

/* Notes and download links under a graphic need air above them */
.offer-grid + .note, .ba + .note, .table-scroll + .note, .flow + .note, .safe-card + .note, .note + .note { margin-top: var(--space-2); }
.training .note a[download] { font-weight: 600; }

/* Chooser on a phone: one card per row instead of a squeezed four-column table */
@media (max-width: 40em) {
  .chooser, .chooser tbody, .chooser tr, .chooser th, .chooser td { display: block; }
  .chooser thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .chooser tr { padding: 0.75rem 1rem; border-bottom: 1px solid var(--line); }
  .chooser tbody tr:last-child { border-bottom: 0; }
  .chooser th[scope="row"], .chooser td { padding: 0.15rem 0; border: 0; }
  .chooser td:nth-child(2)::before { content: "Team size: "; color: var(--muted); }
  .chooser td:nth-child(4) { font-weight: 650; }
}

/* Trusted by: organisation names as clean text badges (no logos) */
.trusted-badges { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 0.5rem 0.75rem; }
.trusted-badges li { border: 2px solid var(--accent); border-radius: 999px; padding: 0.2rem 0.9rem; font-weight: 700; font-size: var(--step--1); color: var(--ink); background: var(--bg); }
.trusted-badges-lg li { font-family: var(--font-display); font-size: var(--step-1); padding: 0.4rem 1.2rem; }
.trusted-line { margin: var(--space-3) 0 0; font-size: var(--step-1); font-weight: 600; max-width: 44rem; }
.trusted-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; margin-top: var(--space-3); }
.trusted-label { font-size: var(--step--1); font-weight: 650; color: var(--muted); }
