/* Responsive : page outils (fenêtre étroite → large). Tout est scopé body.embed. */
body.embed #page-outils{container-type:inline-size;container-name:outils}

/* grille fluide : 2 colonnes dès que chaque carte a ~380 px, sinon 1 colonne (jamais de débordement) */
body.embed #page-outils .dv-actions{
  grid-template-columns:repeat(auto-fit,minmax(min(100%,380px),1fr));
  gap:clamp(12px,2cqi,24px);
  max-width:1400px;
}
body.embed #page-outils .dv-action{
  gap:clamp(12px,1.6cqi,20px);
  padding:clamp(14px,2cqi,24px);
  min-width:0;
}
body.embed #page-outils .dv-action-body{overflow-wrap:anywhere}
body.embed #page-outils .dv-action-body h3{font-size:clamp(16px,1.2cqi + 12px,19px);line-height:1.3}
body.embed #page-outils .dv-action-body p{line-height:1.5}
body.embed #page-outils .dv-list{font-size:clamp(13px,.4cqi + 11.5px,14.5px);line-height:1.45}
body.embed #page-outils .dv-action-body .btn{
  min-height:40px;height:auto;padding-block:8px;
  white-space:normal;text-align:center;line-height:1.3;
}

/* fenêtre / carte étroite : icône au-dessus du texte, bouton pleine largeur */
@container outils (max-width:520px){
  body.embed #page-outils .dv-action{flex-direction:column;gap:10px}
  body.embed #page-outils .dv-action-ic{width:40px;height:40px;font-size:20px;border-radius:10px}
  body.embed #page-outils .dv-action-body{align-self:stretch;align-items:stretch}
  body.embed #page-outils .dv-action-body .btn{width:100%;min-height:44px}
}

/* très grand écran : texte plus aéré mais lignes de texte de longueur raisonnable */
@container outils (min-width:1500px){
  body.embed #page-outils .dv-action-body p,
  body.embed #page-outils .dv-list{max-width:62ch}
  body.embed #page-outils .dv-action-ic{width:56px;height:56px;font-size:28px}
}

/* fenêtre basse : espacements resserrés, le bouton reste atteignable sans gros défilement */
@media (max-height:680px){
  body.embed #page-outils .dv-list{margin:6px 0 10px}
  body.embed #page-outils .dv-action{padding-block:12px}
}

/* le message d'avancement ne doit jamais déborder */
body.embed #page-outils .dv-status{overflow-wrap:anywhere;line-height:1.4}

/* clavier : focus bien visible */
body.embed #page-outils .btn:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
