/* ============================== */
/*     BOUTON ACTIONS + AJOUTER   */
/* ============================== */

.x-theme-legalsuite .grid-arrow-icon {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  height: 100%;
}

.x-theme-legalsuite .x-panel.ls-fieldset-panel .ls-fieldset-panel-header.x-panel-header .x-panel-toolbar {
	float: right !important;
}

/* Flèche pour fieldset et sections */
.x-theme-legalsuite .x-panel.ls-fieldset-panel .ls-fieldset-panel-header.x-panel-header .x-panel-toolbar .x-tool,
.x-theme-legalsuite .ls-section-panel .x-panel-header .x-panel-toolbar .x-tool-toggle {
	background-image: url("../gxt/themes/legalsuite/images/legalsuite/grid/arrow-up-orange.svg");
	background-position: center;	
	background-repeat: no-repeat;
	margin-right: 20px; /* Pour ne pas être caché par le scroll*/
}
/* Rotation pour collapsed */
.x-theme-legalsuite .x-panel.ls-fieldset-panel.x-panel-collapsed .ls-fieldset-panel-header.x-panel-header .x-panel-toolbar .x-tool-toggle,
.x-theme-legalsuite .ls-section-panel.x-panel-collapsed .x-panel-header.x-panel-header .x-panel-toolbar .x-tool-toggle {
	transform: rotate(180deg); 
}

/* Réinitialisation des styles hérités de LsButton*/
.btn-reset {
  all: unset;
  box-shadow: none;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  background: none !important;
  border: none;
}
/* suppression des margin-bottom + margin-left sur les boutons Action, Ajouter etc */
.ls-board-center .ls-button.small-bottom-gap {
    margin-bottom: 0px;
}

.ls-board-center .ls-button.small-left-gap {
    margin-left: 0px;
}

.x-theme-legalsuite .ls-board-center .ls-grid-panel div.x-panel-header {
	/*border: 1px solid red !important;*/
	padding: 0px !important;
	height: 32px;
}

/* Style du bouton "Actions" */
/* Style principal du bouton "Actions" */
.btn-actions-text {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  padding: 4px 16px !important;
  height: 32px !important;
  background-color: white !important;
  border: none !important;
  border-radius: 8px !important;
  font: inherit !important;
  line-height: 20px !important;
  box-sizing: border-box !important;
  cursor: pointer;
  gap: 8px !important;
}

.btn-actions-text .lib {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 !important;
  margin: 0 !important;
  height: 100% !important;
  line-height: normal;
  box-sizing: border-box;
}

.btn-actions-text .btn-label {
  font-size: 14px;
  font-weight: 700;
  color: #304287;
  font-family: 'Inter', sans-serif;
  line-height: 20px;
  text-transform: none !important;
  height: 20px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  display: inline-block;
  max-width: 120px;
}

.btn-actions-text .btn-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  background-image: url('../gxt/themes/legalsuite/images/legalsuite/grid/arrow-down-blue.svg');
  background-repeat: no-repeat;
  background-position: center;
  background-size: 24px 24px;
}

/* Hover sur le bouton action en mode texte*/

.btn-actions-text:hover {
  background-color: #e6f0ff !important;
  border-radius: 8px !important;
}


/* Le bouton ajouter dans les tableaux*/
.btn-add-line {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;

  background-color: #3D64ED !important;
  border: none !important;
  border-radius: 8px !important;

  padding: 4px 16px !important;
  height: 32px !important;
   box-sizing: border-box !important;
  width: fit-content !important;
  min-width: 70px !important;
  max-width: 170px !important;

  cursor: pointer !important;
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: ellipsis !important;
  vertical-align: middle !important;
  line-height: 20px !important;
}

/* wrapper contenu icône + texte */
.btn-add-line .btn-content {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  /*height: 100%;*/
}

/* Icône glyphicon */
.btn-add-line .btn-icon {
  display: inline-block;
  width: 24px;
  height: 24px;
  background-image: url('../gxt/themes/legalsuite/images/legalsuite/grid/plus-white-icon.svg'); 
  background-repeat: no-repeat;
  background-position: center;
  background-size: 20px 20px; /* ou 24px selon rendu */
  flex-shrink: 0;
}

.btn-add-line .lib {
  all: unset; /* reset complet */
  display: contents; /* empêche de prendre de la place dans le flow */
}


/* Texte */
.btn-add-line .btn-label {
  font-size: 14px;
  font-weight: 700;
  font-family: 'Inter', sans-serif;
  color: white;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 20px;
  text-transform: none !important;
}


/* ============================== */
/*     Style des popins widget   */
/* ============================== */

.ls-header-popin {
	/*width: 100% !important;*/ /* ca fait déborder le composant à droite*/
	display: flex;
	flex-wrap: nowrap; /* empêche les éléments de passer à la ligne */
	align-items: center;
	padding: 8px 16px;
	background-color: var(--semantique-neutral-neutral-00);
	border-radius: 8px 8px 0 0;
	border-bottom: 1px solid var(--blue-septeo-200);
	height: 48px !important;
	overflow: hidden; /* évite que le contenu déborde visuellement */
	white-space: nowrap; /* interdit les sauts de ligne */
}

.ls-header-popin .ls-popin-name {
	position: relative;
	width: fit-content;
	font-family: 'Inter', sans-serif;
	font-weight: 700;
	font-style: normal;
	font-size: 14px;
	letter-spacing: 0px;
	color: var(--septeo-full-color-grey-grey-90);
	line-height: 20px; 
	white-space: nowrap; /* empêche le texte de wrap */
	overflow: hidden;
	text-overflow: ellipsis; /* optionnel : coupe joliment si trop long */
}

.ls-header-popin .ls-popin-close-btn {
	background: url('../gxt/themes/legalsuite/images/legalsuite/grid/grid-close-btn.svg') no-repeat center center;
	background-size: 19px 19px;
	width: 19px;
	height: 19px;
	cursor: pointer;
	flex-shrink: 0; /* ne pas rétrécir la croix */
	margin-left: auto; /* pousse le bouton à droite */
	top: 50px; /* TODO test */
}

.ls-header-popin .ls-popin-close-btn:hover {
	filter: brightness(0.7); /* effet visuel au hover */
}

/* Debug*/
.ls-header-popin {
  outline: 1px dashed red;
  border-top: 1px dashed black;
}
.test-style-content {
  /*outline: 1px dashed blue;*/
}
/* Debug*/


/* TODO test */
.ls-inline-board {
	display: flex;
	flex-direction: column;
	width: calc(100% - 15px) !important;
	box-sizing: border-box;
	/*height: 100% !important;*/
	height: auto !important;
	min-height: 700px;
	overflow: hidden;
	background-color: var(--semantique-neutral-neutral-00) !important;
	margin: 24px 16px;
}

.ls-board-header {
	display: flex;
	align-items: center;
	padding: 8px 8px;
	background-color: var(--secondary-blue-septeo);
	width: 100% !important;
	box-sizing: border-box;
	
	/*border: 2px solid gray;*/ /* TODO test */
}

.ls-board-back {
  width: 20px;
  height: 20px;
  background: url('../gxt/themes/legalsuite/images/legalsuite/grid/arrow-left.png') no-repeat center center;
  background-size: contain;
  cursor: pointer;
  margin-right: 8px;
}

.ls-board-title {
	font-size: 14px;
	font-weight: 700;
	color: var(--input-focus-border-color);
	flex-grow: 1;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	line-height: 20px;
	cursor: pointer;
}

.ls-board-header td.x-toolbar-cell:first-child {
    padding-right: 8px !important;
}

.ls-board-header td.x-toolbar-cell:nth-child(2) {
    padding-right: 12px;
}

.ls-board-close {
	width: 24px;
	height: 24px;
	background: url('../gxt/themes/legalsuite/images/legalsuite/grid/grid-close-btn.svg') no-repeat center center;
	/*background-size: 19px 19px;*/
	cursor: pointer;
}

.ls-board-close:hover {
	filter: brightness(0.7);
}
.ls-board-header td {
  vertical-align: middle;
}

.ls-board-header .filter-input {
	width: 250px;
	line-height: 20px;
}

.ls-board-header .filter-input input{
	border: 1px solid rgba(238, 244, 255, 1) !important;
	height: 24px !important;
}

.ls-board-header .filter-input input:focus {
  border-color: rgba(0, 88, 202, 1) !important; 
}

.ls-board-header td.x-toolbar-cell:first-child {
  padding-right: 12px;
}

.ls-board-center {
	flex: 1;
	overflow: auto;
	width: 100% !important;
	display: flex;
	flex-direction: column;
	padding: 16px;
	box-sizing: border-box;
}

.ls-inline-board .ls-board-center .ls-form-wrapper {
	flex: 1;
	/*padding: 16px;*/
	overflow: auto;
	width: 100% !important;
	box-sizing: border-box;
}

.ls-board-footer {
	height: 48px;
	background-color: var(--semantique-neutral-neutral-10);
	border-top: 1px solid var(--blue-septeo-200);
	display: flex;
	align-items: center;
	padding: 0 16px;
}

.ls-inline-board .ls-board-center .ls-fieldset-panel .x-panel-body {
	/*border: 2px solid gray;*/ /* TODO test */
	padding: 0px;
}

.ls-inline-board .ls-board-center .flexible-form {
	/*border: 2px solid gray;*/ /* TODO test */
	padding: 0px;
}


.ls-inline-board .ls-board-center .ls-grid-listAlerts {
	
}

/* Widget des notifs les bouton activé, désactivé exporter */
div.ls-inline-board div.ls-board-center div.ls-grid-listAlerts div.x-panel-header {
	/*border: 1px solid gray;*/ /* TODO test */
	height: 32px;
	padding: 0px;
}

.x-theme-legalsuite .ls-inline-board .ls-board-center .ls-grid-listAlerts .x-panel .x-panel-header .x-panel-toolbar {
  margin-top: 0px;
}


.ls-alerts-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  /* float supprimé en JS */
}

.ls-alerts-left-buttons {
  display: flex;
  gap: 0;
  flex-grow: 1;             /* <-- important */
  justify-content: flex-start;
  height: 32px;
}

.ls-alerts-right-buttons {
  display: flex;
  gap: 4px;
  margin-left: auto;
  justify-content: flex-end;
  height: 32px;
  /*padding-right: 16px;*/
}

/* Styles boutons ( Activées, Désactivées etc) */
.ls-alerts-left-buttons .x-btn {
  border: 1px solid rgba(174, 185, 207, 1);
  background-color: white;
  margin-left: 0px;
  /*padding: 8px;*/
  cursor: pointer;
}

/* le texte des boutons Activées, Désactivées etc */
.x-theme-legalsuite .ls-alerts-left-buttons .ls-button span.lib {
	color: #6a7896;
	font-family: 'Inter', sans-serif;
	font-weight: 700;
	font-size: 14px;
	letter-spacing: 0px;
	line-height: 20px;
	font-style: normal;
	white-space: nowrap;
	padding: 8px;
}

.x-theme-legalsuite .ls-board-center .ls-grid-listAlerts .x-panel-bwrap{
	padding-top: 16px;
}

.x-theme-legalsuite .ls-board-center .x-panel-bwrap{
	padding-top: 16px;
}

/* style au clic va falloir cibler le clic*/
.ls-alerts-left-buttons .x-btn.ls-selected-notif {
  border: 2px solid rgba(61, 100, 237, 1);
  background: none;
  margin-left: 0px;
  padding: 0 6px;
  color: inherit;
  cursor: pointer;
} 

.x-theme-legalsuite .ls-alerts-left-buttons .ls-button.ls-selected-notif span.lib {
	color: rgba(52, 86, 208, 1);
	font-family: 'Inter', sans-serif;
	font-weight: 700;
	font-size: 14px;
	letter-spacing: 0px;
	line-height: 20px;
	font-style: normal;
	white-space: nowrap;
	padding: 5px;
}

.ls-alerts-left-buttons .x-btn {
  display: flex;
  align-items: center;    /* centrage vertical */
  justify-content: center; /* centrage horizontal */
  padding: 0; /* si besoin */
  width: fit-content;
  color: red;
}


/*bouton exporter les notification*/
.x-theme-legalsuite .ls-export-notifs {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	margin-left: 0px;
	
	border: 1px solid rgba(48, 66, 135, 1);
	border-radius: 8px;
	background-color: white;
	padding: 4px 16px;
	cursor: pointer;
}

.x-theme-legalsuite .ls-alerts-right-buttons .ls-export-notifs .x-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	
	height: 32px;
	width: fit-content;
	cursor: pointer;
}

.x-theme-legalsuite .ls-export-notifs .btn-icon {
	display: inline-flex;
	
	background-image:
		url("../gxt/themes/legalsuite/images/legalsuite/icons/export-icon.svg");
	background-repeat: no-repeat;
	background-size: contain;
	background-position: center;
	vertical-align: middle;
	
	width: 24px;	
	height: 24px;
}
/* label du bouton export notifs*/
.x-theme-legalsuite .ls-export-notifs .btn-label {
	color: rgba(48, 66, 135, 1);
	font-family: 'Inter', sans-serif;
	font-weight: 700;
	font-size: 14px;
	letter-spacing: 0px;
	line-height: 20px;
	white-space: nowrap;
	font-style: normal;
	text-transform: capitalize;
	cursor: pointer;
	max-width: 200px; 
	white-space: nowrap; 
	overflow: hidden;
	text-overflow: ellipsis;
}


.x-theme-legalsuite .ls-board-center .ls-xmlform {
	width: 100% !important;
	box-sizing: border-box;
	/*outline: 1px solid green;*/
	height: 100% !important;
}

.x-theme-legalsuite .ls-grid-listWorkflows .ls-grid-container {
	/*border: 1px solid red;*/
	height: 600px !important;
}

.x-theme-legalsuite .ls-inline-board .ls-board-center .ls-grid-listAlerts {
	/*width: 100% !important;*/
    width: auto !important;
    /*padding: 16px*/;
}

/***************************** Pagination responsive ************************/
.ls-paging-toolbar {
	/*border: 1px solid red !important;*/
}

.ls-board-center .x-panel-bbar {
	width: 100% !important;
}

.ls-board-center .x-panel-bbar .ls-paging-toolbar {
	width: auto !important;
}

.x-theme-legalsuite .ls-inline-board .ls-board-center .ls-grid-panel{
	width: 100% !important;
}

/*
.ls-board-center .x-panel-bbar table,
.ls-board-center .x-panel-bbar .x-toolbar,
.ls-board-center .x-panel-bbar .x-toolbar-ct {
    width: 100% !important;
    table-layout: auto !important;
}
*/
/***************************** Pagination responsive ************************/

.ls-board-center .ls-grid-listWorkflows {
	width: 100% !important;
}

.ls-board-center .x-panel-body {
	width: 100% !important;
	box-sizing: border-box;
	/*border: 1px solid black;*/ /* TODO test */
} 

.ls-board-center .x-panel-body .x-grid3,
.ls-board-center .x-panel-body .ls-grid-container {
	height: auto !important;
}

.ls-board-center .x-panel-body .ls-grid-container {
	height: auto !important;
	/*max-height : 600px;*/
}

.ls-board-center .x-panel-body .ls-grid-container .x-grid3-scroller {
	height: auto !important;
}

.ls-board-center .x-panel-bwrap .x-panel-body .x-grid3,
.ls-board-center .x-panel-bwrap .x-panel-body .x-grid3 .x-grid3-header-inner,
.ls-board-center .x-panel-bwrap .x-panel-body .x-grid3 .x-grid3-scroller {
	width: 100% !important;
}


/************************ Style de la bare de pagination LsGridPagingToolBar ******************/

.ls-grid-paging-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  
}

.ls-grid-paging-bar .paging-content {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 40px;
  
  width: 100%;
  justify-content: center;
  padding: 8px 0px;
}


.ls-grid-paging-bar .paging-size {
	    width: 68px !important;
	height: 40px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  border: 1px solid rgba(174, 185, 207, 1);
  border-radius: 4px;
  padding: 8px;
  box-sizing: border-box;
}

.ls-grid-paging-bar .paging-size input.x-form-field {
  /*flex: 1;*/
  /*width: auto !important;*/
}

.x-theme-legalsuite .ls-grid-paging-bar .paging-size .x-form-text {
	color: #7e8fb3 !important;
	font-weight: 500;
	font-family: 'Inter', sans-serif;
	font-size: 14px;	
	border: none !important;
	height: 20px;
	width: auto !important;
  	min-width: 24px; 
  	padding: 0px;
  	/*padding-right: 18px; /* pour laisser de la place à la flèche */
  	box-sizing: border-box; 
  align-self: center !important;
}

.ls-grid-paging-bar .paging-size .x-form-trigger {
  flex-shrink: 0;
}

/* Container pour les boutons + texte */
.ls-grid-paging-bar .paging-center {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px; /* espace entre flèches et label */
}

/* Boutons (optionnel) */
.ls-grid-paging-bar .nav-button {
  cursor: pointer;
}

.ls-grid-paging-bar .nav-button-disabled {
  opacity: 0.5;
  pointer-events: none;
}


/* Boutons de navigation */
.ls-grid-paging-bar .nav-button {
	width: 24px;
	height: 24px;
  cursor: pointer;
  padding: 8px;
  border: none;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.2s;
}

.ls-grid-paging-bar .nav-button:hover {
  opacity: 0.7;
}

.ls-grid-paging-bar .nav-button-disabled {
  opacity: 0.3;
  pointer-events: none;
  cursor: default;
}

/* style du texte */
.ls-grid-paging-bar .xtb-text {
	color: #303441;
	font-size: 14px; 
	font-family: 'Inter', sans-serif;
	font-weight: 700; 
	letter-spacing: 0px;
	line-height: 20px; 
	white-space: nowrap;
}

/* Style de la dropDown pageSize */
.x-theme-legalsuite .ls-file-viewmode .ls-grid-paging-bar .paging-size .x-form-trigger {
    visibility: visible !important;
    border: none;
}

.ls-grid-paging-bar .paging-size .x-form-trigger-arrow {
    background-image: url("../gxt/themes/legalsuite/images/legalsuite/grid/arrow-down-blue.svg");
    background-repeat: no-repeat;
    background-position: center center;
    /*background-size: 10px 10px;*/

    /* Supprimer l'image transparente si besoin */
    content: '';
    src: none !important;
    
    width: 24px;
    height: 24px;
    display: inline-block;
    vertical-align: middle;
    border: none;
}
/* Style de la dropDown pageSize */

/************************ Style de la bare de pagination LsGridPagingToolBar ******************/


.custom-flex-container {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
}

.custom-filter-bar {
  height: 48px;
  flex-shrink: 0;
}

.custom-grid-zone {
  flex: 1 1 auto;
  overflow: auto;
  position: relative;
}

.custom-pagination {
  height: 48px;
  flex-shrink: 0;
}


.ls-file-archive .ls-board-header {
  height: 60px !important;
}


.ls-board-center .x-grid3-header {
	/*border: 1px solid red;*/
	height: auto !important;
}

.ls-board-center .x-grid3-header .x-grid3-hd-inner {
	/*border: 1px solid blue;*/
	width: 100% !important;
	height : 100% !important;
	line-height: normal !important;
}

.ls-board-center .x-grid3-header .x-form-field-wrap {
	/*border: 1px solid green;*/
	border-bottom: 1px solid rgba(174, 185, 207, 1);
	width: calc(100% - 16px) !important; /* laisser de la place pour le sort */
}

.ls-board-center .x-grid3-header .x-form-field-wrap.x-trigger-wrap-focus {
	/*border: 1px solid rgba(61, 100, 237, 1) !important;*/
	border-bottom: 1px solid rgba(61, 100, 237, 1) !important;
	box-shadow: none !important;
}

/* Cas général : input sans trigger → prend toute la largeur */
.ls-board-center .x-grid3-header .x-form-field-wrap input {
	/*border: 1px dashed black;*/ /* todo remettre border none*/
	border: none !important;
	vertical-align: unset !important;
	width: 100% !important;
	padding: 0px !important;
	text-align: left;
}

/* Cas particulier : s’il y a un trigger après le input, on réduit la largeur */
.ls-board-center .x-grid3-header .x-form-field-wrap input:has(+ .x-form-trigger) {
 /*border: 1px dashed red;*/
  width: calc(100% - 24px) !important; /* Réserve 24px pour le trigger */ 
}


.ls-board-center .x-grid3-header .x-form-field-wrap input + .x-form-trigger {
	/*border: 1px solid gray;*/
	position: absolute !important;
	top: 6px !important;
  width: 18px !important;
  height: 24px !important;
}

/* icon de sort */
.x-theme-legalsuite .ls-board-center .x-grid3-header .x-grid3-sort-icon
	{
	/*border: 1px solid blue;*/
	align-self: center;
	margin-top: 4px; /* espace au-dessus */
	width: 12px;
	height: 12px;
}


.ls-board-header .filter-input {
    display: block !important;
    margin-top: 10px !important;
    margin-left: 0px !important;
}

.ls-board-header .x-toolbar-left-row {
    display: block !important;
}

.ls-board-header .x-toolbar-cell {
    display: inline-block;
}

.ls-board-header .x-toolbar-cell:has(.filter-input) {
    display: block;
    width: 100%;
}