/* RESET & BASE */
* {
  box-sizing: border-box;
}
html, body {
  margin: 0;
  padding: 0;
  font-family: Arial, sans-serif;
  background: #f4f4f4;
  font-size: 14px;
  line-height: 1.2;
}
small {
  font-size: 11px;  
}
button {
  background: #0073aa;
  color: #fff;
  border: none;
  border-radius: 3px;
  padding: 10px 16px;
  margin: 5px;
  cursor: pointer;
  font-size: 1em;
}
button:hover {
  background: #005177;
}

.title-gray {
  padding: 10px;
  background-color: #dedede;
}

.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.text-justify {
  text-align: justify;
}

input, select {
  padding: 0.3rem 0.8rem;
}

.message {
  background-color: #fafafa;
  padding: 10px 20px;
  margin: 10px 0;
}

a, a:visited {
  color: black;
  text-decoration: underline;
}

a:hover {
  text-decoration: none;
}

.hidden {
  display: none !important;
}

@media screen and (max-width: 768px) {
  .md-hidden {
    display: none;
  }
}

/* LOADER */
.loader {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  position: relative;
  animation: rotate 1s linear infinite;
}

.loader.loader-lg {
  width: 4rem;
  height: 4rem;
}

.loader::before {
  content: "";
  box-sizing: border-box;
  position: absolute;
  inset: 0px;
  border-radius: 50%;
  border-width: 2px;
  border-style: solid;
  border-color: black;
  animation: prixClipFix 2s linear infinite ;
}

.loader.loader-white::before {
  border-color: white;
}

.btn-loader > .loader {
  margin: 0 auto;
  display: none;
  width: 24px;
  height: 24px;
}
.btn-loader.btn-loader-active > .loader {
  display: block;
}
.btn-loader.btn-loader-active > .label {
  display: none;
}

@keyframes rotate {
  100%   {transform: rotate(360deg)}
}

@keyframes prixClipFix {
  0%   {clip-path:polygon(50% 50%,0 0,0 0,0 0,0 0,0 0)}
  25%  {clip-path:polygon(50% 50%,0 0,100% 0,100% 0,100% 0,100% 0)}
  50%  {clip-path:polygon(50% 50%,0 0,100% 0,100% 100%,100% 100%,100% 100%)}
  75%  {clip-path:polygon(50% 50%,0 0,100% 0,100% 100%,0 100%,0 100%)}
  100% {clip-path:polygon(50% 50%,0 0,100% 0,100% 100%,0 100%,0 0)}
}

/* LOADING */
#fullscreen-loading {
  display: none;
  position: fixed;
  z-index: 999;
  height: 48px;
  width: 48px;
  overflow: show;
  margin: auto;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
}

#fullscreen-loading.active {
  display: block;
}

#fullscreen-loading:before {
  content: '';
  display: block;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #ffffffbb;
}

.btn-loader {
  
}

/* FOOTER FIXE */
#siteFooter {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: #f1f1f1;
  border-top: 1px solid #ccc;
  color: #333;
  padding: 10px;
  font-size: 0.8em;
  z-index: 999;
}

/* Mise en page flex pour le footer */
.footerFlex {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footerFlex a {
  padding: 0 5px;
  color: #333;
  text-decoration: underline;
}

.footerCenter {
  text-align: center;
  flex: 1;
}
.footerRight {
  margin-left: 20px;
}

.footerBold {
  font-weight: bold;
}

/* SPLASH SCREEN */
#splashScreen {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: #ffffff;
  z-index: 9999;
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  opacity: 1;
  transition: opacity 1s ease;
  flex-direction: column;
}
#splashContent {
  text-align: center;
  transition: transform 1s ease;
  flex-grow: 0;
  flex-shrink: 0;
}
#splashScreen.fadeOut {
  opacity: 0;
}
#splashScreen.slideUp #splashContent {
  transform: translateY(-100%);
}

#bottomSplashContent {
  flex-grow: 0;
  flex-shrink: 0;
  height: 20vh;
  width: 100%;
}

/* splashscreen reviews */
#reviews {
  position: relative;
  display: flex;
  flex-direction: row;
}

#reviews .container-reviews {
  display: flex;
  flex-direction: row;
  align-items: start;
  justify-content: flex-start;
  animation: slideReviews 30s linear infinite;
  width: 200%;
}

#reviews .container-reviews:hover {
  animation-play-state: paused;
}

#reviews .review {
  padding: 10px;
  width: 33vw; 
  flex-shrink: 0;
  flex-grow: 0;
}

#reviews .review-container {
  /*background-color: #f1f1f1;
  border: 1px solid #f5f5f5;*/
  border-radius: 15px;
  padding: 20px;
}

#reviews .review .profile{
  display: flex;
  flex-direction: row;
  align-items: center;
}

#reviews .review .author-photo{
  width: 25px;
  flex-grow: 0;
  flex-shrink: 0;
}

#reviews .review .author-photo > img{
  width: 100%;
  height: auto;
}

#reviews .review .author-name {
  font-weight: bold;
  font-size: 10pt;
  flex-grow: 1;
  flex-shrink: 1;
  padding-left: 10px;
}

#reviews .review .author-name a{
  color: black;
  text-decoration: none;
}

#reviews .review .relative-time {
  color: #333;
}

#reviews .review .stars {
  position: relative;
  font-size: 16pt;
  line-height: 16pt;
  margin: 10px 0;
}

#reviews .review .stars::before {
  display: inline-block;
  content: '★★★★★';
  color: #ddd;
}

#reviews .review .stars::after {
  display: inline-block;
  position: absolute;
  left: 0;
  top: 3px;
  content: '★★★★★';
  color: #ebba42;
  text-wrap: nowrap;
  overflow: hidden;
  width: 0;
}

#reviews .review .stars[data-note="0"]::after {
  width: 0%;
}
#reviews .review .stars[data-note="0.5"]::after {
  width: 10%;
}
#reviews .review .stars[data-note="1"]::after {
  width: 20%;
}
#reviews .review .stars[data-note="1.5"]::after {
  width: 30%;
}
#reviews .review .stars[data-note="2"]::after {
  width: 40%;
}
#reviews .review .stars[data-note="2.5"]::after {
  width: 50%;
}
#reviews .review .stars[data-note="3"]::after {
  width: 60%;
}
#reviews .review .stars[data-note="3.5"]::after {
  width: 70%;
}
#reviews .review .stars[data-note="4"]::after {
  width: 80%;
}
#reviews .review .stars[data-note="4.5"]::after {
  width: 90%;
}
#reviews .review .stars[data-note="5"]::after {
  width: 100%;
}

#reviews .review .content {
  font-size: 8pt;
  line-height: 12pt;
}

@keyframes slideReviews {
  to {
    transform: translateX(-100vw);
  }
}

/* Medium */
@media screen and (max-width: 768px) {
    #reviews .review {
        width: 100vw;
    }
}


/* HEADER */
header {
  display: flex;
  align-items: center;
  background: #0099cc;
  color: #fff;
  padding: 10px;
  justify-content: space-between;
}
#logoAndTitle {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}
#logoImage {
  height: 40px;
  width: auto;
}
#homeLink {
  margin: 0;
}
#sloganTxt {
  font-size: 0.8em;
  margin-top: -4px;
}

.header-icons {
  display: flex;
  gap: 20px;
}
.header-icons .icon {
  cursor: pointer;
  font-size: 1.5em;
}
#logoAndTitle a, .header-icons a {
  text-decoration: none;
}

/* SECTION */
section {
  background: #fff;
  margin: 20px auto 70px auto; 
  padding: 20px;
  max-width: 1100px;
  border-radius: 5px;
}
section h2 {
  margin-top: 0;
}

/* Formulaire ergonomique */
.form-group-row {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
  justify-content: center;
}

.form-group-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-shrink: 0;
  flex-grow: 1;
}
.form-group-col label {
  font-weight: bold;
}

.form .form-group-row {
  flex-direction: row;
}

.form .form-group-row-center {
  justify-content: center;
}

.form .form-group, .form .form-group {
  margin-bottom: 10px;
}

.form input, .form select{
  padding: 6px 10px;
  display: block;
  width: 100%;
}

.form label{
  font-weight: bold;
  display: block;
  padding-bottom: 10px;
}

.form .form-group-inline {
  width: 100%;
}

.form .form-group-inline > label{
  display: inline-block;
  min-width: 120px;
}

.form .form-group-row > .form-group{
  flex-grow: 1;
}

.form .form-group-row > .form-group-2{
  width: 16.666%;
}

.form .form-group-title {
  padding: 10px;
  background-color: #dedede;
  font-weight: bold;
  font-size: 1rem;
  margin-top: 20px;
  margin-bottom: 20px;
}

.form div.errors[role='alert'] {
  background-color: #f2dede;
  border: 2px solid #ebccd1;
  border-radius: 4px;
  padding: 15px;
  color: #a94442;
}

@media screen and (max-width: 768px) {
    .form-group-col {
        width: 100vw;
        padding: 0 20px;
    }

}

/* BOUTON GROUP */
.button-group {
  margin: 10px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* WIZARD STEPS */
#wizardContainer .stepCard {
  background: #eee;
  margin-bottom: 15px;
  padding: 15px;
  border-radius: 4px;
}
#wizardContainer .stepTitle {
  font-weight: bold;
  margin-bottom: 8px;
}
#wizardContainer img {
  max-width: 100%;
  margin: 10px 0;
}
#wizardContainer .button-group button {
  margin: 5px 8px 5px 0;
}

/* Calendrier client */
.calendar-client-table-responsive {
    overflow: auto;
}
.calendar-client-table {
  border-collapse: collapse;
  width: 100%;
  margin-bottom: 20px;
  table-layout: fixed;
}
.calendar-client-table th,
.calendar-client-table td {
  border: 1px solid #ccc;
  width: 60px;
  height: 60px;
  text-align: center;
  cursor: pointer;
}
.calendar-slot.occupied {
  background: #ccc;
  color: #999;
  cursor: not-allowed;
}
.calendar-slot.past,
.calendar-slot.disabledWeekend {
  background: #ddd !important;
  color: #888 !important;
  cursor: not-allowed;
}
.calendar-slot.available {
  background: #d4f5d4;
  color: #080;
}
.calendar-slot.available:hover {
  background: #bdeebd;
}
.calendar-slot.available.selected {
  background: #abe3ab !important;
  font-weight: bold;
}
@media screen and (max-width: 768px) {
   .calendar-client-table th, .calendar-client-table td {
     width: 25vw;
     height: 95px;
   }
}

/* PRODUIT (PUBLIC) */
#productListPublic .productLine {
  background: #eee;
  padding: 10px;
  margin: 5px 0;
  border-radius: 3px;
  cursor: pointer;
}
#productListPublic .productLine:hover {
  background: #ccc;
}

/* MODAL => centrer */
.modal {
  position: fixed;
  z-index: 999999;
  left: 0; top: 0; width: 100%; height: 100%;
  background-color: rgba(0,0,0,0.4);
  display: flex; 
  justify-content: center; 
  align-items: center;
}
.modal.hidden {
  display: none;
}
.modal-content {
  background: #fff;
  padding: 20px;
  border-radius: 6px;
  width: 400px;
  max-width: 90%;
  position: relative;
}
.modal-close {
  position: absolute;
  top: 10px; right: 10px;
  cursor: pointer;
  font-weight: bold;
  font-size: 1.2em;
}

/* PAGE FINALE DE REMERCIEMENTS */
#thankYouSection {
  background: #eefceb;
  padding: 20px;
  border-radius: 6px;
  text-align: center;
}
#thankYouSection h3 {
  color: #288628;
  margin-top: 0;
}
#errorSection {
  background: #dedede;
  padding: 20px;
  border-radius: 6px;
  text-align: center;
}

/* Impression */
@media print {
  @page {
    size: A4 landscape;
    margin: 10mm;
  }
  body {
    font-size: 0.9em;
  }
  #siteFooter,
  .header-icons,
  .orderDeleteBtn {
    display: none !important;
  }
}

/* zone détail impression (Espace Technicien) */
#techPrintDetails {
  display: none;
}
@media print {
  #techPrintDetails {
    display: block !important;
  }
}

/* autocompleter */
.autocompleter-container {
    position: relative;
}

.autocompleter-results {
    position: absolute;
    width: 100%;
    background-color: white;
    box-shadow: 1px 1px 5px #333;
    z-index: 20;
}

.autocompleter-results ul {
    margin: 0px;
    padding: 0px;
    list-style-type: none;
}

.autocompleter-results li {
    text-align: left;
    font-size: 0.8rem;
    cursor: pointer;
    line-height: 1rem;
    color: #333;
    padding: 5px 10px;
    font-weight: 500;
}

.autocompleter-results li:hover,
.autocompleter-results li.active {
    background-color: #f1f1f1;
}

@media screen and (max-width: 768px) 
{
    .autocompleter-results li {
        line-height: 2rem;
        font-size: 1.3rem;
    }
}

/* installations modules */
.installations-module {
  background-color: white;
  border-radius: 1rem;
  box-shadow: rgba(0, 0, 0, 0.08) 0px 6px 12px 0px;
  width: 50%;
  margin: 0 auto;
  padding: 1.5rem 1.75rem 2rem;
}
@media screen and (max-width: 768px) 
{
    .installations-module {
        width: 100%;
    }
}

.installations-module h2{
  margin: 0 0 1rem;
  font-size: 1.5rem;
  font-weight: 700;
  text-align: center;
  color: #2563eb;
}

.installations-module .tarif{
  display: flex;
  align-items: center;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 1rem;
}

.installations-module .tarif > input{
  width: 5rem;
  padding: 0.35rem 0.5rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  text-align: right;
  font-weight: 600;
}

.installations-module .month-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.installations-module .month-nav span {
  font-weight: 600;
  font-size: 1rem;
}

.installations-module .month-nav button {
  border: none;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  cursor: pointer;
  padding: 0;
  margin: 0;
  background: #f8fafc !important;
  transition: background 0.2s, transform 0.15s;
  font-size: 1.1rem;
  color: black;
}

.installations-module .month-nav button:hover {
  background-color: #e5e7eb !important;
  transform: translateY(-1px);
}

.installations-module .container-table {
  position: relative;
}

.installations-module .container-loader {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  bottom: 0;
  background-color: rgba(255,255,255,0.5);
  display: none; 
  justify-content: center;
  align-items: center;
}

.installations-module .container-loader.active {
  display: flex;
}

.installations-module .loader {
  height: 48px;
  width: 48px;
}

.installations-module table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 0.85rem;
}

.installations-module td {
  border: 1px solid #e5e7eb;
  width: 33.33%;
  height: 80px;
  position: relative;
  background: #f8fafc;
}

.installations-module td.active {
  background: rgba(59, 130, 246, 0.08);
}

.installations-module .month-label {
  position: absolute;
  top: 6px;
  left: 8px;
  font-size: 0.7rem;
  font-weight: 500;
  color: #6b7280;
}

.installations-module .count {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  width: 100%;
  font-size: 1.4rem;
  font-weight: 700;
  color: #111827;
}

.installations-module .total {
  font-weight: 700;
  font-size: 1.05rem;
  text-align: center;
  border-top: 2px solid #e5e7eb;
  padding-top: 0.65rem;
  color: #2563eb;
}

/* liste formules paiements */
.payments {
  display: flex;
  flex-direction: row;
  justify-content: center;
  flex-wrap: wrap;
  position: relative;
  margin: 40px;
}

.payments > .payment {
  border-radius: 10px;
  font-size: 0.8rem;
  width: 25%;
  flex-shrink: 0;
  flex-grow: 0;
  padding: 0 10px;
}

.payments .payment-container {
  box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2);
  padding: 10px;
  background-color: #f1f1f1;
  height: 100%;
  border: 5px solid white;
  outline: 2px solid white;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  max-width: 200px;
}
.payments .payment-container:hover{
  /*background-color: #d4f5d4;*/
}

.payments .payment.payment-selected .payment-container {
  background-color: #d4f5d4;
  border: 5px solid #d4f5d4;
  outline: 2px solid #d4f5d4;
}

.payments .check {
  display: none;
  position: absolute;
  top: -45px;
  color: green;
  font-size: 2rem;
  right: 0;
}

.payments .payment.payment-selected .payment-container .check{
  display: block;
}

.payments .title {
  font-weight: bold;
  text-transform: uppercase;
  background-color: white;
  display: block;
  padding: 5px 0;
  border-radius: 10px;
  text-align: center;
}

.payments .count {
  font-size: 2em;
  background-color: green;
  border-radius: 50%;
  padding: 10px;
  color: white;
  border: 2px solid white;
  outline: 2px solid white;
}

.payments ul {
  list-style-type: none;
  margin: 20px 0;
  padding: 0;
  font-size: 0.7rem;
}

.payments ul > li {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  margin: 10px 0;
  align-items: baseline;
}

.payments .purchase .date {
  font-weight: bold;
  text-transform: capitalize;
}

.payments .purchase .amount {
  color: black;
  background-color: white;
  padding: 5px;
  border-radius: 10px;
  font-weight: bold;
}

.payments .total {
  margin: 0 0 10px 0;
  background-color: white;
  padding: 10px;
  color: black;
  border-radius: 10px;
}

.payments .total > div {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: baseline;
}

.payments .total .amount {
  font-weight: bold;
}

@media screen and (max-width: 768px) 
{
    .payments > .payment {
      width: 250px;
      margin-bottom: 50px;
    }
}
