:root {
  --primary: #2e479d;
  --secondary: #03ab8a;
  --secondary-hover: #4aeecd;
  --bg: #ffffff;
  --text: #222;
}

.quote-wrapper {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  max-width: 1200px;
}
.quote-products {
  flex: 2;
  overflow-x: auto;
  background: var(--bg);
  padding: 20px;
  border-radius: 5px;
  border: 1px solid #ddd;
}
.products-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 20px;
}
.products-table th td {
  padding: 12px 10px;
  border-bottom: 1px solid #eee;
  vertical-align: middle;
  font-size: 14px;
  text-align: left;
}
.products-table th {
background: #fff;
  color: black;
  font-weight: 600;
  border-bottom: 2px solid #ccc;
  border-top: none;
  border-right: none;
  border-left: none;
  font-size: inherit;
  font-weight: inherit;
}

.products-table tbody tr td {
  border: none;
}


tfoot tr td {
  border-top: 2px solid #ccc;
  font-weight: 600;
  font-size: 16px;
  color: var(--primary);
  border-bottom:none ;
  border-right:none ;
  border-left:none ;
  
}

.product-block {
  display: flex;
  align-items: center;
  gap: 15px;
}
.product-info {
  display: flex;
  flex-direction: column;
}
.product-block img {
  width: 80px;
  height: 80px;
  border-radius: 10px;
  object-fit: cover;
}
.product-info strong {
  font-size: 15px;
  color: var(--primary);
}
.product-info small {
  font-size: 13px;
  color: #666;
}

.quote-form-qty-input {
  background: white !important;
  border: 1px #9fb2bf solid !important;
  width: 100px !important;
  margin: 0px !important;
}


.quote-products select {
    width: auto;          
    min-width: 100px;     
    max-width: 100%;      
    display: inline-block;
      border: 1px #9fb2bf solid !important;
      margin: 0px !important;

}

.quote-products select {
    width: auto;
    min-width: 100px;
    max-width: 100%;
    display: inline-block;
    white-space: nowrap;
}



.actions i {
cursor: pointer;
  font-size: 18px;
  color: black;
  background: white;
  border-radius: 6px;
  padding: 6px;
  margin-right: 6px;
  transition: 0.2s;
  border: 1px solid #ccc;
  width: 30px;
  height: 30px;
  display: flex;
  justify-items: center;
  align-items: center;
}
.actions i:hover {
  transform: scale(1.1);
  background: #f0f0f0;
}
#actions-icon{
  display: flex;
  flex-direction: row;
}

.summary-product {
  text-align: right;
  font-weight: 600;
  margin: 10px 0 20px 0;
  font-size: 16px;
  color: var(--primary);
}
#choose-mode {
  width: auto;
  padding: 12px;
  font-size: 15px;
  border: none;
  border-radius: 8px;
  background: var(--secondary);
  color: white;
  cursor: pointer;
  transition: 0.3s;
  margin-top: 10px;
}

#choose-mode:hover { background: var(--secondary-hover); }


#devis-botton {
  width: 100%;
  display: flex;
  justify-content: flex-end;
  padding-top: 20px;
}

/* POPUP MODAL */
.modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.5);
}
.modal-content {
  background-color: var(--bg);
  margin: 15% auto;
  padding: 20px;
  border-radius: 10px;
  max-width: 400px;
  text-align: center;
  position: relative;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.modal-content h3 {
  color: var(--primary);
  margin-top: 0;
}
.modal-content p {
  font-size: 14px;
  color: #555;
  margin-bottom: 20px;
}
.modal-content button {
  width: 80%;
  padding: 12px;
  margin: 10px 0;
  font-size: 15px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: 0.3s;
}
#guest-btn { background: var(--secondary); color: white; }
#guest-btn:hover { background: #029777; }
#login-btn { background: var(--primary); color: white; }
#login-btn:hover { background: #243b7a; }
.close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 20px;
  cursor: pointer;
  color: #999;
}
.close:hover { color: #000; }

/* Formulaire invité pro */
.quote-client {
  flex: 1;
  background: var(--bg);
  padding: 25px;
  border-radius: 10px;
  border: 1px solid #ddd;
  box-shadow: 0 4px 8px rgba(0,0,0,0.05);
  margin-top: 20px;
  display: none;
}
.quote-client h3 {
  margin-top: 0;
  color: var(--primary);
  font-size: 20px;
  margin-bottom: 20px;
  text-align: center;
}
.quote-client form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.quote-client label {
  font-weight: 600;
  margin-bottom: 4px;
  color: #333;
}
.quote-client input, .quote-client select {
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 14px;
  width: 100%;
  box-sizing: border-box;
}
.quote-client input:focus, .quote-client select:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 5px rgba(46,71,157,0.3);
}
.quote-client button {
  padding: 12px;
  font-size: 15px;
  border: none;
  border-radius: 8px;
  background: var(--secondary);
  color: white;
  cursor: pointer;
  transition: 0.3s;
  margin-top: 10px;
}
.quote-client button:hover { background: #029777; }

.qty-input {
  width: 50px;
  padding: 8px 10px;
  height: 30px;
  text-align: center;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 500;
  color: #222;
  background: #fafafa;
  transition: 0.3s;
}

/* Focus effect */
.qty-input:focus {
  border-color: #2e479d; /* couleur primaire */
  box-shadow: 0 0 5px rgba(46,71,157,0.3);
  outline: none;
}

/* Remove default arrows (optional) */
.qty-input::-webkit-inner-spin-button,
.qty-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.qty-input[type=number] {
  -moz-appearance: textfield; /* Firefox */
}

/* Responsive */
@media (max-width: 900px) {
  .quote-wrapper { flex-direction: column; }
  .quote-products { order: 1; }
  .quote-client { order: 2; }
  table, thead, tbody, th, td, tr { display: block; width: 100%; }
  thead { display: none; }
  tr { margin-bottom: 20px; border: 1px solid #ddd; border-radius: 10px; padding: 10px; background: #fafafa; }
  td { display: flex; flex-direction: column; padding: 8px; border: none; }
  td[data-label="Description"] .product-block { flex-direction: column; align-items: flex-start; }
  td[data-label="Description"] .product-block img { width: 100%; height: auto; margin-bottom: 10px; }
  /*td::before { content: attr(data-label); font-weight: 600; color: var(--primary); margin-bottom: 4px; }*/
  .actions { justify-content: flex-start; margin-top: 5px; }
  .summary-product { text-align: center; }
}


#mini-quote-cart {
    border: 1px solid #ddd;
    padding: 15px;
    border-radius: 10px;
    background: #fff;
    max-width: 300px;
    margin-bottom: 20px;
}
#mini-quote-cart ul.mini-quote-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
#mini-quote-cart ul.mini-quote-list li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #eee;
    font-size: 14px;
}
#mini-quote-cart ul.mini-quote-list li .remove-product {
    cursor: pointer;
    color: #ff4d4f;
    font-weight: bold;
}



/* Overlay général du modal d'édition */
.quote-modal {
    display: none; /* masqué par défaut */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6); /* fond semi-transparent */
    justify-content: center;  /* centrer horizontalement */
    align-items: center;      /* centrer verticalement */
    z-index: 9999;
}

/* Conteneur du modal */
.quote-modal-content {
    background: #fff;
    padding: 25px 30px;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    max-width: 450px;
    width: 90%;
    position: relative;
    text-align: left;
    animation: fadeInScale 0.3s ease-in-out;
}

/* Animation */
@keyframes fadeInScale {
    0% { transform: scale(0.7); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* Bouton fermer */
.quote-close {
    position: absolute;
    top: 10px;
    right: 12px;
    background: transparent;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #333;
}

/* Titres */
.quote-modal-content h3 {
    margin-top: 0;
    font-size: 20px;
    color: #333;
}

/* Formulaire */
#quote-edit-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

#quote-edit-form label {
    font-weight: 600;
    font-size: 14px;
    color: #555;
}

#quote-edit-form input[type="number"],
#quote-edit-form select {
    padding: 8px 10px;
    border-radius: 6px;
    border: 1px solid #ccc;
    font-size: 14px;
    width: 100%;
}

#quote-edit-form button {
    padding: 10px 15px;
    border-radius: 6px;
    border: none;
    background-color: #0aaa8c;
    color: #fff;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.2s ease;
}

#quote-edit-form button:hover {
    background-color: #088b74;
}


/*----- quotes-detail page -----*/


.pqr-quote-details {
  border: 1px solid #d0d3d5;
  border-radius: 10px;
  padding: 20px;
}


.pqr-quote-actions .button.alt {
  padding: 10px;
  background: #02b08e;
  color: white;
  fill: white;
  border-radius: 10px;
}
.pqr-quote-actions {
  display: flex;
  justify-content: space-between;
  padding: 0px 30px;
}
.pqr-quote-actions .button {
  padding: 10px;
  background: #2c469b;
  color: white;
  border-radius: 10px;
  width: 20%;
  justify-content: center;
  text-align: center;
}


.button.pqr-generate-pdf {
  background-color: #49dd05;
  border-color: #49dd05;
  color: #fff;
  text-decoration: none;
  display: inline-block;
  padding: 6px 12px;
  border-radius: 3px;
  font-size: 13px;
  line-height: 1.4;
  text-align: center;
  cursor: pointer;
}
.button.ajax-subview {
  background-color: #12add0;
  border-color: #12add0;
  color: #fff;
  text-decoration: none;
  display: inline-block;
  padding: 6px 12px;
  border-radius: 3px;
  font-size: 13px;
  line-height: 1.4;
  text-align: center;
  cursor: pointer;
}

/*-- Modal Popup Buttons --*/

.btn-spinner {
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255,255,255,0.4);
    border-top-color: #fff;
    border-radius: 50%;
    display: inline-block;
    margin-right: 8px;
    animation: spin 0.8s linear infinite;
    vertical-align: middle;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}