/**
 * Css pour le template tables periodiques

 * Création: 17/01/2026
 */
 :root {
    --primary: #0069d9;
    --border: lightgrey;
    --transition: all 0.3s ease;
}
#main {
    padding-top: 0px !important;
} 
.page-header {
    align-items: center;
    gap: 10px;
}
.titre_page {
    color:  #ffb200;
    text-align: center;
}
.help-button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    vertical-align: middle;
    padding-left: 20px;
}
.container {
    display: flex; /* Active Flexbox */
    gap: 20px; /* Espace entre les zones */
    width: 100% !important;
}
.zone {
    flex: 1; /* Les deux zones prennent la même largeur */
    padding: 15px;
    /* border: 1px solid #ccc;
    border-radius: 5px;
    background-color: #f9f9f9; */
}
.fieldset-group:hover {
    border-color: #3498db;
}
.fieldset-group {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 5px;
    margin-bottom: 12px;
    background-color: #ffffff;
    transition: border-color 0.3s ease;
    box-shadow: 5px 5px 10px rgba(0,0,0,0.5);
}
.fieldset-group legend {
    font-weight: bold;
    font-size: .8rem;
    color: #3498db;
    padding: 0 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-left: 10px;
}
.clear-button {
    background: none;
    border: none;
    /* padding: .3rem; */
    cursor: pointer;
}

.clear-button img {
    width: 32px;
    height: 32px;
}

.search-label {
    display: block;
    margin-bottom: .4rem;
    font-weight: 600;
}

.search-line {
    display: flex;
    align-items: center;
    gap: .5rem;
}

.search-input {
    flex: 1;
    padding: .3rem .5rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}
.dates-line {
    display: flex;
    align-items: center;
    gap: .5rem;
}
.annee-input, .offset-input, .select-search-type {
    width: 80px;
    /* padding: .5rem .7rem; */
    border: 1px solid #ccc;
    border-radius: 4px;
}
.invalid {
    border-color: #e74c3c !important;
    background-color: #fdecea;
}
.btn-createListe, .close-btn, .modal-btn, .primary-btn {
    background: linear-gradient(135deg, #d7dde3, #5a7aa0);
    height: 40px;
    color: #000;
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
    box-shadow: 6px 6px #3f536a;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s ease;
    margin-right: 15px;
    text-align: center;
}
.btn-createListe:hover, .close-btn:hover, .modal-btn:hover, .primary-btn:hover {
    background: linear-gradient(135deg, #5a7aa0, #d7dde3);
    box-shadow: 3px 3px #2a3d52;
    color: #fff;
}
.double {
    height: 60px;
    
}

/* Conteneurs */
.wrapper, .wrapper-tm {
    display: inline-flex;
    background: #fff;
    height: 50px;
    align-items: center;
    justify-content: space-evenly;
    border-radius: 5px;
    padding: 5px;
    box-shadow: 5px 5px 30px rgba(0,0,0,0.2);
    width: 500px; /* Largeur par défaut */
}

.wrapper-tm { width: 250px; }

/* Styles de base de l'option */
.option {
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-evenly;
    margin: 0 5px;
    border-radius: 5px;
    cursor: pointer;
    padding: 0 10px;
    border: 2px solid var(--border);
    transition: var(--transition);
}

.option:hover { background-color: #ddd; }

/* Le point (dot) */
.dot {
    height: 18px;
    width: 18px;
    background: #d9d9d9;
    border-radius: 50%;
    position: relative;
}

.dot::before {
    position: absolute;
    content: "";
    top: 4px; left: 4px;
    width: 10px; height: 10px;
    background: var(--primary);
    border-radius: 50%;
    opacity: 0;
    transform: scale(1.5);
    transition: var(--transition);
}

/* Cache l'input radio */
input[type="radio"] { display: none; }

/* ÉTAT COCHÉ (Logique universelle) */
input:checked + .option {
    border-color: var(--primary);
    background: var(--primary);
}

input:checked + .option .dot { background: #fff; }

input:checked + .option .dot::before {
    opacity: 1;
    transform: scale(1);
}

input:checked + .option span { color: #fff; }

.option span {
    font-size: 14px;
    color: #000;
    margin-left: 5px;
}
.tabs-nav {
  display: flex;
  margin-top: 0.8rem;
  gap: .5rem;
}
.tabs-nav button {
  padding: .4rem .8rem;
  border: 1px solid #ccc;
  background: #f5f5f5;
  cursor: pointer;
}
.tabs-nav button.active {
  background: var(--primary);
  border-bottom-color: var(--primary);
  font-weight: 600;
  color: #fff;
}
.tabs-panels > div {
  display: none;
  border: 1px solid #ccc;
  border-top: none;
  padding: .8rem;
}
.tabs-panels > div.active {
  display: block;
}
.pagination {
    margin-top: 20px;
    text-align: center;
}

.pagination button {
    margin: 0 3px;
    padding: 5px 10px;
    cursor: pointer;
}

.pagination button.active {
    background-color: #007bff;
    color: white;
    border: none;
}
.data-table {
    width: 100%;
    margin-top: 15px;
    border: 2px solid #120d0d;
    box-shadow: inset;
}
.data-table td {
    border-right: 2px solid #120d0d;
    padding: 2px 8px 2px 8px;
}
.data-table td:hover {
    background-color: #f0f0f0; /* Couleur de fond au survol */
    cursor: pointer; /* Changement du curseur pour indiquer que c'est cliquable */
    border: 1px solid #202a70;
}
.data-table td:last-child {
    border-right: none;
}
.data-table tr:nth-child(even) {
    background-color: #e3d9d9;
}
.data-table tr:nth-child(odd) {
    background-color: beige;
}
.date-container {
    float: right;
    padding-right: 10px;
}
.nom-homme {
    color: rgb(0, 0, 255);
    font-weight: bold;
}
.nom-femme {
    color: rgb(238, 20, 84);
    font-weight: bold;
}
.caption {
    font-weight: bold;
    font-size: larger;
    margin-bottom: 5px;
    text-align: center;
    background-color: var(--primary);
    color: white;
    padding: 3px;
    border-radius: 5px;
    border: 2px solid #2a3d52;

}
/* Conteneur de la liste */
.ui-autocomplete {
  max-height: 260px;
  overflow-y: auto;
  background: #ffffff;
  border-radius: 12px;
  border: 2px solid var(--primary) !important;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
  padding: 6px 0;
  margin-top: 10px;
  font-size: 14px;
  /* width: auto !important; */
  min-width: 200px !important;
  max-width: 300px !important;
  z-index: 9999; /* important si overlay */
}

/* Chaque item */
.ui-menu-item-wrapper {
  padding: 3px 14px;
  cursor: pointer;
  color: #111827;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Hover / sélection clavier */
.ui-state-active {
  background: #eff4ff !important;
  color: #1d4ed8 !important;
}

/* Optionnel : petite “pill” de surbrillance sur le texte trouvé */
.ui-menu-item-wrapper b {
  font-weight: 600;
  color: #1d4ed8;
}
.custom-dialog {
    width: 800px;
    position: relative;
    top: 28%;
    left: 15%;
    background-color: #ccc;
    padding: 20px;
    /* max-width: calc(100vw - 20px); */
    max-height: calc(100vh - 20px);
    /* overflow: scroll; */
    border-radius: 20px;
    border: 8px solid #a1a693;
}
/* 
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
}


.modal-overlay.active {
    opacity: 1;
}

.modal-overlay.active .modal-container {
    transform: translateY(0);
}


.modal-close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    width: 36px; 
    height: 36px;
    background: #fff; 
    border: 1px solid #ccc; 
    border-radius: 50%; 
    display: flex;
    justify-content: center;
    align-items: center; 
    font-size: 20px; 
    cursor: pointer;
    color: #333;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); 
    transition: all 0.2s ease; 
    z-index: 10;
    line-height: 1; 
}

.modal-close-btn:hover {
    background: #f0f0f0; 
    border-color: #999;
    transform: scale(1.05); 
}

.modal-close-btn:before {
    content: "×"; 
    display: block;
    font-weight: bold;
    color: red;
}


.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
}


.modal-overlay.active {
    opacity: 1;
}

.modal-container {
    background: white;
    padding: 20px;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    transform: translateY(-20px);
    transition: transform 0.3s ease;
}
.modal-container1 {
    background: white;
    padding: 8px;
    border-radius: 8px;
    max-width: 800px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    transform: translateY(-20px);
    transition: transform 0.3s ease;
    background-color: #e0e0e0;
}
.modal-overlay.active .modal-container {
    transform: translateY(0);
}
.modal-content{
    padding: 10px;
}
.modal-titre { 
    margin-bottom: 0;
    text-align: center;
} */

/* 1. L'arrière-plan (Overlay) */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0); /* On part de transparent */
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none; /* Empêche de cliquer à travers tant qu'elle est invisible */
    transition: opacity 0.4s ease, background-color 0.4s ease;
}

/* État actif : l'overlay devient visible et sombre */
.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
    background-color: rgba(0, 0, 0, 0.7);
}

/* 2. Les containers (La boîte blanche) */
.modal-container, .modal-container1 {
    background: white;
    padding: 20px;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    
    /* Animation de départ : Légèrement plus bas et réduit */
    transform: translateY(30px) scale(0.95);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Spécificités pour modal-container1 */
.modal-container1 {
    max-width: 800px;
    padding: 8px;
    background-color: #e0e0e0;
}

/* État actif : On remet à la position et taille normale */
.modal-overlay.active .modal-container,
.modal-overlay.active .modal-container1 {
    transform: translateY(0) scale(1);
}

/* 3. Bouton fermer */
.modal-close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    width: 36px;
    height: 36px;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    z-index: 10;
}

.modal-close-btn:hover {
    background: #f0f0f0;
    transform: scale(1.1) rotate(90deg); /* Ajout d'une petite rotation pour le style */
}

.modal-close-btn:before {
    content: "×";
    font-size: 24px;
    font-weight: bold;
    color: red;
    line-height: 1;
}

/* Contenu */
.modal-content {
    padding: 10px;
}

.modal-titre { 
    margin-bottom: 0;
    text-align: center;
}

.button-group {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    width: 100%;
    padding-left: 18px;
    margin-bottom: 20px;;
}

.type-acte {
    font-size: 18px;
    font-weight: bold;
}
.avec-tab {
    padding-left: 50px;
}
.gras {
    font-weight: bold;
}
.textNotif{
    text-align: center;
    font-size: larger;
}
.displayRight {
    float: right;
}
.ui-autocomplete li.even {
    background-color: #f5f5f5; /* Gris clair */
    border-bottom: 1px solid #666; /* Bordure inférieure légère */
}

.ui-autocomplete li.odd {
    background-color: #ffffff; /* Blanc */
    border-bottom: 1px solid #666; /* Bordure inférieure légère */
}

.ui-autocomplete li.ui-state-focus {
    background-color: #e6e6e6; /* Couleur de fond pour l'élément sélectionné */
    border-bottom: 1px solid #666; /* Bordure inférieure */
}
.ui-autocomplete li:last-child {
    border-bottom: none; /* Pas de bordure pour le dernier élément */
}
