/* GaliVue V3.9.52 — multilingual text-fit safety layer.
   This stylesheet is intentionally narrow: it improves translated label fit
   without changing workflow logic or the approved Client Selection layout. */

html[data-language] button,
html[data-language] .primary,
html[data-language] .secondary,
html[data-language] .accent-button,
html[data-language] .danger-button,
html[data-language] .danger-outline,
html[data-language] [role="button"]{
  min-width:0;
  max-width:100%;
  box-sizing:border-box;
}

/* Text actions may wrap naturally in FR / ES / DE. Icon-only controls keep
   their existing geometry because they are explicitly excluded below. */
html[data-language] button:not(.icon):not(.icon-button):not(.menu-button):not(.menu-close):not(.profile-avatar-button):not(.lightbox-nav):not(.lightbox-close),
html[data-language] .primary,
html[data-language] .secondary,
html[data-language] .accent-button,
html[data-language] .danger-button,
html[data-language] .danger-outline{
  white-space:normal;
  overflow-wrap:anywhere;
  word-break:normal;
  text-wrap:balance;
  line-height:1.18;
  height:auto;
}

/* Confirmation and decision rows are the most translation-sensitive areas. */
html[data-language] #confirmDialog .confirm-actions,
html[data-language] .plan-confirm-actions,
html[data-language] .notification-actions,
html[data-language] .selection-download-actions,
html[data-language] .selection-next-actions,
html[data-language] .final-delivery-actions,
html[data-language] .delivery-summary-actions,
html[data-language] .delivery-client-actions,
html[data-language] .upload-post-actions,
html[data-language] .drop-zone-actions{
  min-width:0;
}

html[data-language] #confirmDialog .confirm-actions > *,
html[data-language] .plan-confirm-actions > *,
html[data-language] .notification-actions > *,
html[data-language] .selection-download-actions > *,
html[data-language] .selection-next-actions > *,
html[data-language] .final-delivery-actions > *,
html[data-language] .delivery-summary-actions > *,
html[data-language] .delivery-client-actions > *,
html[data-language] .upload-post-actions > *,
html[data-language] .drop-zone-actions > *{
  min-width:0;
  max-width:100%;
}

/* Keep two-choice confirmation dialogs premium on desktop while allowing
   translated labels to use a second line instead of escaping the button. */
html[data-language] #confirmDialog.client-selection-confirm-dialog .confirm-actions,
html[data-language] #confirmDialog.gv3917-email-dialog .confirm-actions,
html[data-language] #confirmDialog.gv3947-delete-project-dialog .confirm-actions{
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
}
html[data-language] #confirmDialog.client-selection-confirm-dialog .confirm-actions button,
html[data-language] #confirmDialog.gv3917-email-dialog .confirm-actions button,
html[data-language] #confirmDialog.gv3947-delete-project-dialog .confirm-actions button{
  min-width:0!important;
  padding-inline:14px!important;
}

/* German and French are commonly longer. Reduce only action-label typography,
   never body copy, when necessary to preserve the approved composition. */
html[data-language="fr"] #confirmDialog .confirm-actions button,
html[data-language="de"] #confirmDialog .confirm-actions button{
  font-size:clamp(.80rem,.72rem + .18vw,.92rem)!important;
  letter-spacing:0!important;
}

html[data-language="es"] #confirmDialog .confirm-actions button{
  letter-spacing:0!important;
}

/* Header / sidebar labels should stay readable rather than clip. */
html[data-language] .gv39-sidebar button,
html[data-language] .workspace-language-switcher,
html[data-language] .profile-menu button,
html[data-language] .mobile-menu button,
html[data-language] .mobile-menu a{
  overflow-wrap:normal;
  word-break:normal;
}

@media(max-width:720px){
  html[data-language] #confirmDialog.client-selection-confirm-dialog .confirm-actions,
  html[data-language] #confirmDialog.gv3917-email-dialog .confirm-actions,
  html[data-language] #confirmDialog.gv3947-delete-project-dialog .confirm-actions{
    grid-template-columns:minmax(0,1fr)!important;
  }
  html[data-language] #confirmDialog .confirm-actions button{
    width:100%!important;
  }
}

/* GaliVue V3.9.52 — deep translation-fit pass.
   Protect long FR / ES / DE labels in Dashboard stage tabs, confirmation
   surfaces and private Final Delivery without changing approved page geometry. */
html[data-language] .gv3928-stage-tabs,
html[data-language] .gv3929-stage-tabs,
html[data-language] .gv3942-primary-action,
html[data-language] .gv3942-project-tools-grid,
html[data-language] #deliveryCategoryDownloads,
html[data-language] .delivery-client-actions,
html[data-language] .delivery-summary-actions,
html[data-language] .delivery-file-meta,
html[data-language] .client-d2-summary-row,
html[data-language] .client-d2-limit-card,
html[data-language] .gv391-quick-grid,
html[data-language] .gv391-account-quick-grid{
  min-width:0;
  max-width:100%;
}

html[data-language] .gv3928-stage-tab,
html[data-language] .gv391-view-all,
html[data-language] .gv391-continue,
html[data-language] .gv391-manage-plan,
html[data-language] .gv3942-primary-action > button,
html[data-language] .gv3942-project-tools-grid > button,
html[data-language] #deliveryCategoryDownloads > button,
html[data-language] .delivery-client-actions > button,
html[data-language] .delivery-file-meta > button{
  min-width:0!important;
  max-width:100%;
  white-space:normal!important;
  overflow-wrap:anywhere;
  word-break:normal;
  line-height:1.18;
}

html[data-language] #confirmDialog h2,
html[data-language] #confirmDialog .confirm-body,
html[data-language] #confirmDialog .confirm-body p,
html[data-language] #confirmDialog .confirm-body label,
html[data-language] .delivery-section-heading h2,
html[data-language] .delivery-expiry-notice,
html[data-language] .delivery-feedback-nudge,
html[data-language] .gv3926-stage-intro,
html[data-language] .gv3927-stage-copy{
  min-width:0;
  overflow-wrap:anywhere;
  word-break:normal;
}

/* Do not let a translated stage name force a workflow tab outside its grid. */
html[data-language] .gv3928-stage-tab > *,
html[data-language] .gv3929-stage-tabs > *{
  min-width:0;
}

@media(max-width:980px){
  html[data-language] .gv3928-stage-tab,
  html[data-language] .gv391-continue,
  html[data-language] .gv3942-primary-action > button{
    text-wrap:pretty;
  }
}

@media(max-width:520px){
  html[data-language="fr"] .gv3928-stage-tab,
  html[data-language="de"] .gv3928-stage-tab,
  html[data-language="es"] .gv3928-stage-tab{
    font-size:clamp(.72rem,3.05vw,.86rem)!important;
    letter-spacing:0!important;
  }
}
