body {
  font-family: sans-serif;
  margin: 0;
  padding: 0;
  height: 100%;
  overflow: hidden;
  background-color: #f4f4f4;
  display: flex;
  justify-content: center;
  align-items: center;
}

.container2 {
  width: 100%;
  height: 100vh;
  margin: 0;
}

.card {
  box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.2);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  font-size: 1em;
}

.card-header .header-text {
  display: flex;
  align-items: center;
}

.card-header .header-text .fa {
  margin-right: 5px;
}

.card-body {
  padding: 10px;
  padding-bottom: 0;
}

.card-bottom {
  border-top: 1px solid #ddd;
  display:flex;
  justify-content:space-between;
  align-items:center;
  font-size: 0.8em;
}
#interface{
  width: 100%;
  height: 100%;
}
.nav-tabs {
  margin-bottom: 5px;
}

.nav-tabs .nav-item .nav-link {
  color: black;
  border-color: #ddd;
  border-radius: 0;
  transition: background-color 0.3s, border-bottom 0.3s;
  font-size: 0.8em;
  padding: 6px 10px;
}

.nav-tabs .nav-item .nav-link.active {
  background-color: #ffffff;
  border-bottom: 2px solid #66bb6a;
  border-color: #ddd;
  border-radius: 0;
}

#phoneNumber {
  width: 97%;
  padding: 8px;
  border: none;
  font-size: 0.9em;
}
#deleteButton,
#phoneNumber:focus{
  outline: none;
  border: none;
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}
.dialpad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
  margin-top: 5px;
  margin-bottom: 5px;
  padding: 10px;
}

.keypad-button {
  padding: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
  border: 1px solid #ddd;
  border-radius: 4px;
  background-color: #f9f9f9;
  cursor: pointer;
  position: relative;
  font-size: 0.9em;
}

.keypad-button .small-text {
  position: absolute;
  bottom: 2px;
  font-size: 0.5em;
  color: #888;
}

.volume-control {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 35px;

}

.volume-control label {
  margin-right: 5px;
  font-size: 0.8em;
}

.volume-control input[type="range"] {
  flex: 1;
  width: 100%;
}

.dnd-buttons button {
  margin-right: 3px;
  padding: 5px;
  font-size: 0.7em;
}

.volume-range {
  margin: 0 5px;
  height: 25px;
}

/* Ajustement pour la taille de la range input */
input[type="range"] {
    background: #ddd;
    height: 5px;
    border-radius: 2px;
    outline: none;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  background: #4285f4;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  cursor: pointer;
}

input[type="range"]::-moz-range-thumb {
  -moz-appearance: none;
  appearance: none;
  background: #4285f4;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  cursor: pointer;
}

/* Modification pour le statut et les icones de l'appel */
#status {
  display: flex;
  align-items: center;
  margin: 0;
  width: auto;
  font-size: 0.9em;
  padding: 0;
  border: none;
}

#status.alert {
  padding: 5px;
  background-color: transparent;
  border: none;
}

#status .fa {
  margin-right: 5px;
}

#status.alert-success {
  color: green;
}

#status.alert-danger {
  color: red;
}
.content-bottom {
  display: flex;
  justify-content: center;
  flex-direction: column;
  width: 100%;
  margin: 0 auto;

}

.controls {
  display: flex;
  justify-content: center;
  border-top: 1px solid #ddd;
  align-items: center;
  height: 35px;
  gap: 25px;
}
.controls button {
  padding: 8px;
  height: 100%;
  border: 1px solid #ddd;
  cursor: pointer;
  border-radius: 5px;
  height: fit-content;
}
#callButton,
#videoBtnCall{
  display: flex;
  justify-content: center;
  align-items: center;
  height: 35px;
  gap: 15px;
  width: 50%;
  font-size: 16px;
  background-color: rgb(29, 78, 1);
  color: white;
  border: none;
  cursor: pointer;
  border-radius: 5px; 
  padding: 10px;
}
.volume-controls {
  padding: 5px;
  border-top: 1px solid #ddd;

}
.volume-control button{
  background-color: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  font-size: 1em;
  margin-right: 0px;
  width: 10%;
}
#remoteAudio{
  visibility: hidden; 
  opacity: 0;
}
.showbutton{
  visibility: visible;
  opacity: 1;
  transition: .6s ease-in-out;
}
.callactions{
  position: absolute;
  top: 80%;
  left: 50%;
  transform: translate(-50% -80%);
  z-index: 9999;
}
#fullscreenButton {
  position: absolute;
  top: 85%;
  right: 2%;
  background: none;
  border: none;
  padding: 5px;
  cursor: pointer;
}
#fullscreenButton i {
  background: none;
  color: white;
  font-size: 20px;
}
.number-input-container{
  display: flex;
  border-radius: 5px;
  font-size: 0.9em;
  border: 2px solid black;
  background-color: white;
}
#deleteButton{
  border: none;
  background: none;
  font-size: 2em;
}
body,
html {
    margin: 0;
    padding: 0; /* Empêche le défilement si le contenu est trop grand */
}

/* Container principal */
.container2 {
    padding: 0; /* Enlève le padding par défaut du container */
    height: 100vh; /* Prend 100% de la hauteur de la fenêtre */
    display: flex;
    flex-direction: column; /* Organise le contenu verticalement */
}

.rows {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Interface principale */
#interface {
    flex: 1; /* Permet à l'interface de grandir et de remplir l'espace disponible */
    display: flex;
    flex-direction: column;
}


.card1 {
    flex: 1; 
    margin: 0; 
    border: none; 
    border-radius: 0;     
    box-shadow: none; 
    display: flex;
    flex-direction: column; 
}

.card-header {
    background-color: #f8f9fa;
    padding: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.125); 
}

.header-text {
  font-size: 1.2rem;
  font-weight: bold;
}

.header-icon {
  cursor: pointer;
}

.card-body {
    flex: 1; /* Le corps prend tout l'espace disponible */
    padding: 1rem;
    display: flex;
    flex-direction: column;
}

.keypad-button {
    padding: .4rem;
    font-size: 1.2rem;
    border: 2px solid white;
    border-radius: 0.25rem;
    background-color: #fff;
    cursor: pointer;
}

/* Zone en bas de l'interface */
.content-bottom {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: auto; /* Pousse vers le bas */
}

.controls {
    display: flex;
    justify-content: center
}

.volume-controls {
    width: 100%;
    display: table-column;
}
.volume-slider{
    width: 80%;
}
/* Styles de base pour l'élément range */
input[type="range"] {
    width: 100%;               /* Prend toute la largeur disponible */
    height: 8px;              /* Hauteur du track (rail) */
    border-radius: 5px;        /* Coins arrondis */
    background: #d3d3d3;       /* Couleur du track */
    outline: none;              /* Supprime la bordure de focus */
    opacity: 0.7;              /* Transparence légère */
    -webkit-transition: .2s;  /* Transition douce sur Webkit */
    transition: opacity .2s;   /* Transition douce */
}

/* Au survol, on augmente l'opacité */
input[type="range"]:hover {
    opacity: 1;
}

/* Style du thumb (curseur) sur Webkit (Chrome, Safari) */
input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    width: 100%; 
    height: 16px;
    border-radius: 50%;       
    background: #007bff;      
    cursor: pointer;
    border: none;    
}


input[type="range"]::-webkit-slider-thumb,
input[type="range"]::-moz-range-thumb {
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}
.nav-tabs {
    justify-content: center;
    font-size: 1.2em;
}
.nav-link{
    bottom: 0;
}
.tab-content {
    margin-top: 0.5rem;
}

/* Bas de la carte */
.card-bottom {
    background-color: #f8f9fa;
    padding: 0.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.125);
}

.dnd-buttons {
    display: flex;
    justify-content: space-around;
}

/* Formulaire (caché par défaut) */
#forms {
    display: none;
}
.window-frame {
  margin: 0;
  visibility: hidden;
  width: 100%;
  height: 100vh;
  position: absolute;
  justify-content: space-between;
  background-color: #333;
  box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.2);
  z-index: 100;
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
  }
.window-frame.show {
  opacity: 1;
  visibility: visible;
  background: #000;
}
.popup-header {
  display: flex;
  justify-content: space-between;
  width: 100%;
  font-weight: bold;
}
.popup-body {
  width: 100%;
  height: 70%;
  background-color: #444444;
  color: #d3d3d3;
}
.popup-footer {
  position: absolute;
  bottom: 20px;
  margin-top: 20px;
  display: flex;
  justify-content: space-around;
  width: 100%;
}
.popup button {
  padding: 10px;
  border: none;
  cursor: pointer;
  border-radius: 5px;
}
#callbutton {
  margin-top: 20px;
  font-size: 16px;
  background-color: blue;
  color: white;
  border: none;
  cursor: pointer;
  border-radius: 5px;
}
.popup-header {
  width: 100%;
  background-color: #262626;
  padding: 10px 20px;
  box-sizing: border-box;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}

.header-left {
  display: flex;
  align-items: center;
}

.whatsapp-icon {
  width: 20px;
  height: 20px;
  margin-right: 5px;
  border-radius: 2px;
  background-color: #128C7E;
}

.content-area {
  width: 100%;
  height: 80%;
  background-color: #262626;
  flex-grow: 1;
  display: flex;
  border-radius: 20px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
  background-image: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="none" viewBox="0 0 16 16">%3Cpath fill="rgba(255,255,255,0.05)" d="M0 0h16v16H0z"%3E%3C/path%3E%3Cpath fill="rgba(255,255,255,0.03)" d="M8 8l8-8m-8 8L0 0m8 8l8 8m-8-8L0 16"/%3E%3C/svg%3E');

}

.profile-picture {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  margin-bottom: 20px;
  background-color: #ddd;
  object-fit: cover;
}

.name {
  font-size: 20px;
  font-weight: bold;
  margin-bottom: 5px;
}

.calling-text {
  justify-content: center;
  font-size: 16px;
  color: #ece3e3;
}

.popup-footer {
  width: 100%;
  padding: 15px 20px;
  box-sizing: border-box;
  display: flex;
  justify-content: center;
  align-items: center;
}

.controls {
  display: flex;
  justify-content: center;
}

.control-button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: #444444;
  color: #FFFFFF;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 18px;
  cursor: pointer;
  border: none;
  outline: none;
}

.hangup-button {
  background-color: #D83A56;
}

.window-buttons {
  display: flex;
  gap: 5px;
}

.window-button {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  cursor: pointer;
}

.close {
  background-color: #DC3545;
}
.fas{
background: none;
}
.call-container {
  background: #000;
  position: absolute;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.main-video {
  width: 100%;
  height: 100%;
  background-color: black;
}

#remoteVideo {
  width: 100%;
  height: 100%;
  object-fit: cover;  /* Cela permet de s'assurer que la vidéo couvre entièrement l'écran */
  transform: scaleX(1)
}

.controls-video {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 15px;
  padding: 10px;
  background-color: rgba(0, 0, 0, 0.5);  /* Fond transparent en rgba */
  border-radius: 10px;
  z-index: 10;
}

/* Styles pour les boutons */
.controls-video button {
  padding: 10px 20px;
  background-color: #f44336;
  color: white;
  border: none;
  cursor: pointer;
  border-radius: 5px;
}

.controls-video button:hover {
  background-color: #d32f2f;
}
@media (max-width: 450px) {
  .dialpad {
      grid-template-columns: repeat(3, 1fr); 
  }
  .keypad-button {
      padding: 1.2em;
      font-size: 1rem;
  }
  .keypad-button .small-text {
    position: absolute;
    bottom: 2px;
    font-size: 0.7em;
    color: #888;
  }
  .container2 {
      padding: 0;
      margin: 0;
  }
  .content-bottom{
      padding: 15px;
      height: 20%;
      font-size: 1.2em;
  }
  .controls{
      margin-top: 10px;
      padding-bottom: 30px;
  }
  .card-bottom{
      font-size: 1em;
      height: 35px;
  }
  input[range]{
      width: 100%;
  }
  .rows {
      padding: 0;
      margin: 0;
  }
  .nav-tabs{
      height: 4%;
      display: flex;
  }
  #interface {
      padding: 0;
      margin: 0;
  }
  #deleteButton{
      height: 15%;
  }
  #interface .card1 {
      padding: 0;
      margin: 0;
      border-radius: 0;
  }
}
@media(max-height:567px){
  .body-respons{
    display: flex;
    gap: 20px;
  }
  .dialpad{
    padding: 1.7em;
    width:  50%;
  }
  .keypad-button {
    color: #333;
    background-color: #d3d3d3;
    padding: 1.5em;
    font-size: .7rem;
    border-top: none;
    border-left: none;
    border-right: none;
  }
  .content-bottom{
    width: 50%; 
  }
}
