/* ═══════════════════════════════════════════════════════════════════════════
   OUTILS GRATUITS VINTED (27/10/2026) : pages statiques écrites par tools/outils.py, dans le bloc
   .ssr-home (sans l'application), et leur version à intégrer (/embed/…, body.ot-embed).
   Jetons du thème seulement (clair par défaut, sombre si choisi). Téléphone d'abord : à 375 px tout
   s'empile, champs à 16 px (iOS zoome en dessous), cibles de 44 px.
   ═══════════════════════════════════════════════════════════════════════════ */
.ot-page { display: block; }
.ot-fil { margin: 0 0 18px; font-size: .88rem; }
.ot-fil a { margin-left: 0; }
.ot-page p { margin: 0 0 12px; }
.ot-reponse { margin: 0 0 16px; padding: 14px 16px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border);
  box-shadow: var(--sh-sm); }
.ot-muted, .ot-sources .ot-muted { color: var(--slate-500); font-size: .88rem; }

/* L'outil : formulaire + résultat */
.ot-outil { margin: 26px 0 8px; }
.ot-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.ot-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 18px;
  box-shadow: var(--sh-sm); min-width: 0; }
.ot-card-t { margin: 0 0 12px; font-weight: 800; font-size: 1.02rem; color: var(--ink); }
.ot-form { display: grid; gap: 12px; }
.ot-champ { display: grid; gap: 5px; min-width: 0; }
.ot-label { font-weight: 700; font-size: .88rem; color: var(--ink); display: flex; flex-wrap: wrap;
  justify-content: space-between; gap: 2px 10px; }
.ot-label small { font-weight: 500; color: var(--slate-500); font-size: .78rem; }
.ot-input { display: flex; align-items: center; border: 1px solid var(--border-2); border-radius: 12px;
  background: var(--canvas); overflow: hidden; }
.ot-input input { flex: 1; min-width: 0; border: 0; outline: 0; padding: 11px 12px; font: inherit; font-size: 16px;
  font-weight: 700; color: var(--ink); background: transparent; min-height: 44px; }
.ot-input i { font-style: normal; padding: 0 12px; color: var(--slate-500); font-weight: 700; }
.ot-input:focus-within, .ot-select:focus { border-color: var(--blue-500); box-shadow: 0 0 0 3px var(--blue-50); }
.ot-select { width: 100%; min-height: 44px; border: 1px solid var(--border-2); border-radius: 12px; padding: 10px 12px;
  font: inherit; font-size: 16px; color: var(--ink); background: var(--canvas); }
.ot-trio { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.ot-articles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ot-case { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; color: var(--ink); min-height: 44px;
  padding-top: 4px; }
.ot-case input { width: 20px; height: 20px; flex-shrink: 0; margin: 1px 0 0; accent-color: var(--blue-500); }
.ot-prive { margin: 10px 0 0; text-align: center; }

/* Résultat */
.ot-res { position: sticky; top: 16px; }
.ot-res p { margin: 8px 0; }
.ot-verdict { font-weight: 800; font-size: 1.06rem; padding: 10px 12px; border-radius: 12px; margin: 0 0 10px !important; }
.ot-oui { background: var(--green-50); color: var(--green-600); }
.ot-non { background: var(--blue-50); color: var(--brand-text); }
.ot-ligne { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--border);
  font-size: .94rem; }
.ot-ligne span { color: var(--slate-600); min-width: 0; }
.ot-ligne b { color: var(--ink); white-space: nowrap; }
.ot-fort b, .ot-fort span { color: var(--ink); font-weight: 800; }
.ot-gros { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 6px; }
.ot-gros span { font-weight: 700; color: var(--slate-600); }
.ot-gros b { font-size: 1.6rem; font-weight: 900; color: var(--ink); letter-spacing: -.02em; white-space: nowrap; }
.ot-sep { border: 0; border-top: 1px dashed var(--border-2); margin: 12px 0; }
.ot-note, .ot-proj { font-size: .86rem; color: var(--slate-500); }
.ot-proj { color: var(--ink); font-weight: 600; }
.ot-jauge { margin: 12px 0; }
.ot-jauge-t { display: flex; justify-content: space-between; gap: 10px; font-size: .88rem; margin-bottom: 5px; }
.ot-jauge-t span { color: var(--slate-600); }
.ot-jauge-t b { color: var(--ink); white-space: nowrap; }
.ot-jauge-b { height: 10px; border-radius: 99px; background: var(--border); overflow: hidden; }
.ot-jauge-b i { display: block; height: 100%; border-radius: 99px; background: var(--blue-500); }
.ot-transp { list-style: none; padding: 0 !important; margin: 0 !important; display: grid; gap: 8px; }
.ot-transp li { display: flex; gap: 10px; align-items: flex-start; margin: 0 !important; padding: 9px 10px;
  border-radius: 12px; border: 1px solid var(--border); }
.ot-transp li div { display: grid; gap: 2px; min-width: 0; }
.ot-transp b { color: var(--ink); }
.ot-transp small { color: var(--slate-500); font-size: .8rem; }
.ot-transp .ot-tag { font-style: italic; }
.ot-pastille { flex-shrink: 0; font-size: .74rem; font-weight: 800; padding: 3px 8px; border-radius: 99px;
  white-space: nowrap; margin-top: 1px; }
.ot-ok .ot-pastille { background: var(--green-50); color: var(--green-600); }
.ot-ko .ot-pastille { background: var(--red-50); color: var(--red-600); }
.ot-na .ot-pastille { background: var(--border); color: var(--slate-600); }

/* Boutons (liens compris : .ssr-home a colore tous les liens) */
.ot-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px;
  padding: 10px 18px; border-radius: 12px; border: 1px solid transparent; font: inherit; font-weight: 800;
  font-size: .95rem; text-decoration: none; cursor: pointer; background: #0B5BD3; color: #fff; }
/* Les liens de .ssr-home sont colorés par le thème (html[data-theme] .ssr-home a) : le bouton reprend la main. */
html .ssr-home a.ot-btn, html[data-theme] .ssr-home a.ot-btn { color: #fff; }
.ot-btn-ghost { background: transparent; color: var(--brand-text); border-color: var(--border-2); }
.ot-btn-sm { min-height: 40px; padding: 8px 14px; font-size: .88rem; }
.ot-btn:disabled { opacity: .5; cursor: default; }

/* Tableaux de référence : défilent seuls, jamais la page */
.ot-table { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--border); border-radius: 14px;
  background: var(--surface); margin: 12px 0 8px; }
.ot-table table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.ot-large table { min-width: 520px; }
.ot-table th { text-align: left; font-size: .74rem; text-transform: uppercase; letter-spacing: .04em; color: var(--slate-500);
  padding: 10px 12px; border-bottom: 1px solid var(--border); }
.ot-table td { padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: top; color: var(--ink); }
.ot-table tr:last-child td { border-bottom: 0; }

/* Hub : cartes d'outils */
.ot-cartes { list-style: none; padding: 0 !important; margin: 22px 0 !important; display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.ot-carte { margin: 0 !important; }
.ot-carte a { display: grid; gap: 6px; height: 100%; padding: 16px 18px; border-radius: 16px; border: 1px solid var(--border);
  background: var(--surface); box-shadow: var(--sh-sm); text-decoration: none; }
.ot-carte a:hover { border-color: var(--blue-500); }
.ot-carte strong { font-size: 1.04rem; }
.ot-carte span { color: var(--slate-600); font-size: .92rem; line-height: 1.5; }

/* Listes, intégration, appel à l'action, liens proches */
.ot-sources li, .ot-liens li { overflow-wrap: anywhere; }
.ot-integrer { margin-top: 30px; }
.ot-code { width: 100%; box-sizing: border-box; font: 13px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace;
  color: var(--ink); background: var(--canvas); border: 1px solid var(--border-2); border-radius: 12px; padding: 10px 12px;
  resize: vertical; }
.ot-cta { margin: 34px 0 0; padding: 18px; border-radius: 16px; border: 1px solid var(--border); background: var(--surface);
  text-align: center; }
.ot-cta p { margin: 6px 0; }
.ot-cta-t { font-weight: 800; color: var(--ink); font-size: 1.05rem; }
.ot-proche { margin: 26px 0 0; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--border); }

/* Version à intégrer (iframe) */
body.ot-embed { margin: 0; padding: 12px; background: var(--canvas); color: var(--ink);
  font-family: 'Inter', system-ui, -apple-system, sans-serif; line-height: 1.5; }
.ot-embed .ot-embed-t { font-size: 1.1rem; }
.ot-embed-pied { margin: 12px 0 0; font-size: .85rem; color: var(--slate-500); text-align: center; }
.ot-embed-pied a { color: var(--brand-text); }

/* Téléphone : tout s'empile, le résultat suit le formulaire */
@media (max-width: 720px) {
  .ot-grid, .ot-cartes { grid-template-columns: 1fr; }
  .ot-res { position: static; }
  .ot-card { padding: 16px; }
  .ot-card-t, .ot-verdict, .ot-cta { text-align: center; }
  .ot-code { font-size: 16px; }
}
@media (max-width: 600px) {
  /* Tableaux larges en fiches : une ligne = une carte, l'intitulé de colonne devant chaque valeur. */
  .ot-large { overflow: visible; border: 0; background: transparent; }
  .ot-large table { min-width: 0; }
  .ot-large thead { display: none; }
  .ot-large tr { display: block; margin: 0 0 10px; border: 1px solid var(--border); border-radius: 14px;
    background: var(--surface); padding: 6px 12px; }
  .ot-large td { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; text-align: right; }
  .ot-large td::before { content: attr(data-l); color: var(--slate-500); font-size: .8rem; font-weight: 700;
    text-align: left; flex-shrink: 0; max-width: 46%; }
  .ot-large td:first-child { justify-content: center; text-align: center; font-size: 1rem; }
  .ot-large td:first-child::before { display: none; }
  .ot-large tr td:last-child { border-bottom: 0; }
}
@media (max-width: 380px) {
  .ot-trio { gap: 6px; }
  .ot-trio .ot-input i { padding: 0 6px; }
  .ot-trio .ot-input input { padding: 11px 6px 11px 9px; }
}
