/**
 * LOCLIGHT Planning — Tiroir « Mon panier »
 * ==========================================
 * Tout est préfixé .ll-cart- et vit en fin de <body> : aucune interaction
 * avec custom.css, qui reste dédié au header et au tunnel.
 *
 * Le dropdown natif de ps_shoppingcart est neutralisé plus bas avec
 * !important : custom.js lui pose un display:block INLINE au survol, et
 * seul !important passe devant un style inline.
 */

/* ---------- neutralisation du dropdown natif ---------- */
.blockcart-preview,
.blockcart .dropdown-menu.blockcart-preview {
  display: none !important;
}
.blockcart .dropdown-toggle { cursor: pointer; }

/* ---------- voile ---------- */
.ll-cart-overlay {
  position: fixed;
  inset: 0;
  z-index: 10040;
  background: rgba(10, 10, 10, .45);
  opacity: 0;
  transition: opacity .22s ease;
}
.ll-cart-overlay.is-open { opacity: 1; }
/* tant que le voile n'est pas actif il ne doit intercepter aucun survol :
   sinon il vole le pointeur à .blockcart et le tiroir clignote */
.ll-cart-overlay:not(.is-open) { pointer-events: none; }
.ll-cart-overlay[hidden] { display: none; }

/* ---------- tiroir ---------- */
.ll-cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 10050;
  width: 400px;
  max-width: 92vw;
  display: flex;
  flex-direction: column;
  background: #fff;
  color: #111;
  font-family: inherit;
  box-shadow: -20px 0 60px rgba(0, 0, 0, .35);
  transform: translateX(100%);
  transition: transform .28s cubic-bezier(.2, .8, .3, 1);
}
.ll-cart-drawer.is-open { transform: none; }
.ll-cart-drawer[hidden] { display: none; }
.ll-cart-drawer.is-busy { pointer-events: none; }
.ll-cart-drawer.is-loading .ll-cart-corps { opacity: .45; }
.ll-cart-corps { transition: opacity .15s ease; }

/* ---------- en-tête ---------- */
.ll-cart-grip { display: none; }
.ll-cart-tete {
  flex: none;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 15px 18px;
  background: #1a1a1a;
  color: #fff;
}
.ll-cart-tete h3 {
  margin: 0;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #fff;
}
.ll-cart-cnt {
  background: #ffc600;
  color: #111;
  font-size: 10.5px;
  font-weight: 800;
  border-radius: 99px;
  padding: 3px 8px;
  line-height: 1.2;
}
.ll-cart-fermer {
  margin-left: auto;
  background: none;
  border: 0;
  padding: 4px;
  line-height: 0;
  cursor: pointer;
}
.ll-cart-fermer svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: #fff;
  stroke-width: 2.2;
}

/* ---------- corps ---------- */
.ll-cart-corps {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 4px 18px 14px;
}

/* bandeau noir « produits en location » */
/* Le bandeau « periode » est desormais rendu par ll-rail.js, qui porte son
   propre dessin. Cette classe ne lui donne QUE sa place dans le tiroir : lui
   appliquer .ll-cart-bandeau ferait gagner l'ancien padding et l'ancien rayon
   (cart-drawer.css est un <link> dans le body, donc apres le <style> injecte).
   Les regles .ll-cart-bandeau / .ll-cart-dates / .ll-cart-u qui suivent ne
   servent plus qu'au repli, si ll-rail.js n'a pas ete charge. */
.ll-cart-rail { margin: 15px 0 2px; }

.ll-cart-bandeau {
  background: #1a1a1a;
  color: #fff;
  border-radius: 10px;
  padding: 10px 12px;
  margin: 15px 0 2px;
}
.ll-cart-bandeau-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}
.ll-cart-eyebrow {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: #ffc600;
}
.ll-cart-bandeau .ll-cart-st { margin-left: auto; color: #9a9a9a; }
.ll-cart-dates {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -.01em;
}
.ll-cart-u {
  font-size: 10.5px;
  font-weight: 700;
  color: #8e8e8e;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-right: 4px;
}

/* chevrons animés */
.ll-cart-chev {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  vertical-align: middle;
  margin: 0 5px;
}
.ll-cart-chev i {
  width: 6px;
  height: 6px;
  border-right: 2px solid #ffc600;
  border-top: 2px solid #ffc600;
  transform: rotate(45deg);
  opacity: .18;
  animation: ll-cart-chv 1.5s ease-in-out infinite;
}
.ll-cart-chev i:nth-child(2) { animation-delay: .18s; }
.ll-cart-chev i:nth-child(3) { animation-delay: .36s; }
@keyframes ll-cart-chv {
  0%, 60%, 100% { opacity: .18; }
  25% { opacity: 1; }
}

/* titre de section vente */
.ll-cart-sect {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 18px 0 4px;
}
.ll-cart-sect h4 {
  margin: 0;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .15em;
  text-transform: uppercase;
  white-space: nowrap;
  color: #111;
}
.ll-cart-tag {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: #1a1a1a;
  flex: none;
}
.ll-cart-rule { flex: 1; height: 1px; background: #e6e6e6; }
.ll-cart-st {
  font-size: 11px;
  font-weight: 700;
  color: #6b6b6b;
  white-space: nowrap;
}

/* lignes */
.ll-cart-ln {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #e6e6e6;
}
.ll-cart-ln-in { flex: 1; min-width: 0; }
.ll-cart-vign {
  width: 46px;
  height: 46px;
  flex: none;
  border-radius: 9px;
  overflow: hidden;
  background: #f2f2f2;
  display: block;
}
.ll-cart-vign img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ll-cart-vign--vide { background: linear-gradient(150deg, #2b3244, #12151d); }
.ll-cart-nom {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.3;
  text-transform: uppercase;
  color: #111;
  text-decoration: none;
}
.ll-cart-nom:hover { color: #111; text-decoration: underline; }
.ll-cart-bas {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}

/* stepper */
.ll-cart-step {
  display: inline-flex;
  align-items: center;
  border: 1px solid #e6e6e6;
  border-radius: 8px;
  overflow: hidden;
}
.ll-cart-q {
  width: 26px;
  height: 26px;
  border: 0;
  background: #f6f6f6;
  color: #111;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: background .15s ease;
}
.ll-cart-q:hover:not(:disabled) { background: #ffc600; }
.ll-cart-q:disabled { opacity: .35; cursor: not-allowed; }
.ll-cart-q.is-loading { opacity: .4; }
.ll-cart-step em {
  font-style: normal;
  font-size: 12.5px;
  font-weight: 700;
  width: 26px;
  text-align: center;
}
.ll-cart-dispo {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 10.5px;
  font-weight: 700;
  color: #1f9d55;
}
.ll-cart-dispo::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 99px;
  background: #1f9d55;
}
.ll-cart-stock { font-size: 10.5px; font-weight: 700; color: #6b6b6b; }
.ll-cart-px {
  margin-left: auto;
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
}

/* cross-sell */
.ll-cart-xsell {
  margin-top: 12px;
  background: #faf6e8;
  border: 1px dashed #e2c86a;
  border-radius: 11px;
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.ll-cart-xsell b {
  display: block;
  font-size: 9.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #8a7016;
  margin-bottom: 3px;
}
.ll-cart-xsell p {
  margin: 0;
  font-size: 11.5px;
  font-weight: 600;
  color: #5c4b12;
  line-height: 1.35;
}
.ll-cart-xsell-add {
  margin-left: auto;
  flex: none;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 8px;
  background: #1a1a1a;
  color: #fff;
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
}
.ll-cart-xsell-add:hover { background: #000; }
.ll-cart-spin {
  display: inline-block;
  width: 12px;
  height: 12px;
  border: 2px solid rgba(255, 255, 255, .35);
  border-top-color: #fff;
  border-radius: 99px;
  animation: ll-cart-spin .7s linear infinite;
}
@keyframes ll-cart-spin { to { transform: rotate(360deg); } }

/* panier vide */
.ll-cart-vide { padding: 46px 10px; text-align: center; }
.ll-cart-vide-rond {
  width: 56px;
  height: 56px;
  border-radius: 99px;
  background: #f2f2f2;
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
}
.ll-cart-vide-rond svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: #9a9a9a;
  stroke-width: 1.8;
}
.ll-cart-vide p {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: #6b6b6b;
  line-height: 1.5;
}

/* ---------- recommande (panier vide, client connu) ---------- */
.ll-cart-rec {
  margin: 0 0 6px;
  padding: 14px;
  background: #1a1a1a;
  color: #fff;
  border-radius: 12px;
}
.ll-cart-rec-eyebrow {
  display: block;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: #ffc600;
  margin-bottom: 5px;
}
.ll-cart-rec-titre {
  margin: 0 0 10px;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -.01em;
  color: #fff;
}
.ll-cart-rec-liste {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
  border-top: 1px solid #2f2f2f;
}
.ll-cart-rec-liste li {
  display: flex;
  gap: 8px;
  padding: 7px 0;
  border-bottom: 1px solid #2f2f2f;
  font-size: 12px;
  font-weight: 600;
  color: #d4d4d4;
  line-height: 1.3;
}
.ll-cart-rec-liste span {
  flex: none;
  font-weight: 800;
  color: #ffc600;
}
.ll-cart-rec-sel {
  display: block;
  width: 100%;
  margin-bottom: 10px;
  padding: 10px 12px;
  background: #2c2c2c;
  border: 1px solid #3d3d3d;
  border-radius: 10px;
  color: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.ll-cart-rec-sel:focus { outline: 2px solid #ffc600; outline-offset: 1px; }

/* déclencheur unique : ouvre le calendrier début/fin */
.ll-cart-rec-cal {
  display: block;
  width: 100%;
  margin-bottom: 10px;
  padding: 11px 12px;
  background: #2c2c2c;
  border: 1px solid #3d3d3d;
  border-radius: 10px;
  color: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: border-color .15s ease;
}
.ll-cart-rec-cal:hover { border-color: #ffc600; }
.ll-cart-rec-cal::after { content: "▾"; float: right; color: #ffc600; }

/* calendrier : mêmes règles que action=monthglobal */
.ll-cart-cal {
  margin-bottom: 12px;
  padding: 10px;
  background: #111;
  border: 1px solid #2f2f2f;
  border-radius: 10px;
}
.ll-cart-cal[hidden] { display: none; }
.ll-cart-cal-attente,
.ll-cart-cal-aide {
  margin: 0;
  font-size: 11.5px;
  font-weight: 600;
  color: #9a9a9a;
  text-align: center;
}
.ll-cart-cal-aide { margin-top: 8px; color: #ffc600; }
.ll-cart-cal-tete {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.ll-cart-cal-tete span {
  font-size: 12px;
  font-weight: 800;
  text-transform: capitalize;
  color: #fff;
}
.ll-cart-cal-nav {
  width: 28px;
  height: 28px;
  border: 1px solid #3d3d3d;
  border-radius: 8px;
  background: #2c2c2c;
  color: #fff;
  font-size: 15px;
  line-height: 1;
  cursor: pointer;
}
.ll-cart-cal-nav:hover { border-color: #ffc600; color: #ffc600; }
.ll-cart-cal-grille {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}
.ll-cart-cal-dow {
  text-align: center;
  font-size: 9.5px;
  font-weight: 800;
  color: #6b6b6b;
  padding-bottom: 4px;
}
.ll-cart-cal-j {
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  aspect-ratio: 1 / 1;
  min-height: 34px;
  border: 0;
  border-radius: 7px;
  background: #262626;
  color: #e4e4e4;
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background .12s ease;
}
/* Le survol n'existe que sur les appareils qui en ont un : sur iOS l'état
   :hover reste collé au dernier élément touché, et comme
   :hover:not(:disabled) (0,3,0) pèse plus lourd que .est-debut (0,2,0),
   le gris écrasait le jaune de la sélection au premier tap. */
@media (hover: hover) and (pointer: fine) {
  .ll-cart-cal-j:hover:not(:disabled) { background: #3d3d3d; }
}
.ll-cart-cal-j.est-bloque {
  background: repeating-linear-gradient(-45deg, #1c1c1c 0 4px, #232323 4px 8px);
  color: #4a4a4a;
  cursor: not-allowed;
}
/* états de sélection : spécificité relevée (0,3,0) et déclarés en dernier,
   pour passer devant toute règle de survol résiduelle */
.ll-cart-cal-grille .ll-cart-cal-j.est-entre {
  background: #3a3218;
  color: #ffc600;
  border-radius: 0;
}
.ll-cart-cal-grille .ll-cart-cal-j.est-debut,
.ll-cart-cal-grille .ll-cart-cal-j.est-fin {
  background: #ffc600;
  color: #111;
}

.ll-cart-rec-go {
  display: block;
  width: 100%;
  padding: 12px;
  border: 0;
  border-radius: 10px;
  background: #ffc600;
  color: #111;
  font-family: inherit;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background .18s ease;
}
.ll-cart-rec-go:hover:not(:disabled) { background: #ffd23f; }
.ll-cart-rec-go:disabled { opacity: .55; cursor: wait; }
.ll-cart-rec-msg {
  margin: 9px 0 0;
  font-size: 11.5px;
  font-weight: 600;
  line-height: 1.4;
  color: #1f9d55;
}
.ll-cart-rec-msg.is-erreur { color: #ff9b9b; }

/* ---------- calendrier plein écran (mobile) ---------- */
.ll-cart-calfull {
  position: fixed;
  inset: 0;
  z-index: 10060;
  display: flex;
  flex-direction: column;
  background: #141414;
  color: #fff;
}
.ll-cart-calfull[hidden] { display: none; }
.ll-cart-calfull-tete {
  flex: none;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 18px;
  padding-top: calc(16px + env(safe-area-inset-top));
  background: #1a1a1a;
  border-bottom: 1px solid #2f2f2f;
}
.ll-cart-calfull-tete h3 {
  margin: 0;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.ll-cart-calfull-fermer {
  margin-left: auto;
  background: none;
  border: 0;
  padding: 4px;
  line-height: 0;
  cursor: pointer;
}
.ll-cart-calfull-fermer svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: #fff;
  stroke-width: 2.2;
}
.ll-cart-calfull-corps {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 18px;
}
/* en plein écran, les cases respirent : cible tactile confortable */
.ll-cart-calfull-corps .ll-cart-cal-grille { gap: 4px; }
.ll-cart-calfull-corps .ll-cart-cal-j {
  min-height: 46px;
  font-size: 15px;
  border-radius: 9px;
}
.ll-cart-calfull-corps .ll-cart-cal-dow { font-size: 11px; padding-bottom: 8px; }
.ll-cart-calfull-corps .ll-cart-cal-tete { margin-bottom: 14px; }
.ll-cart-calfull-corps .ll-cart-cal-tete span { font-size: 15px; }
.ll-cart-calfull-corps .ll-cart-cal-nav { width: 38px; height: 38px; font-size: 18px; }
.ll-cart-calfull-corps .ll-cart-cal-aide { margin-top: 14px; font-size: 13px; }
.ll-cart-calfull-pied {
  flex: none;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  padding-bottom: calc(14px + env(safe-area-inset-bottom));
  background: #1a1a1a;
  border-top: 1px solid #2f2f2f;
}
.ll-cart-calfull-lbl {
  flex: 1;
  min-width: 0;
  font-size: 13px;
  font-weight: 700;
  color: #d4d4d4;
}
.ll-cart-calfull-ok {
  flex: none;
  padding: 13px 22px;
  border: 0;
  border-radius: 10px;
  background: #ffc600;
  color: #111;
  font-family: inherit;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
  cursor: pointer;
}
.ll-cart-calfull-ok:disabled { opacity: .4; }

@media (min-width: 768px) {
  .ll-cart-calfull { display: none !important; }
}

/* ---------- pied ---------- */
.ll-cart-pied {
  flex: none;
  border-top: 1px solid #e6e6e6;
  padding: 14px 18px 18px;
  background: #fff;
}
.ll-cart-detail {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  font-weight: 600;
  color: #6b6b6b;
  margin-bottom: 5px;
}
.ll-cart-tot {
  display: flex;
  align-items: baseline;
  margin: 9px 0 12px;
}
.ll-cart-tot span {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .13em;
  text-transform: uppercase;
}
.ll-cart-tot b {
  margin-left: auto;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -.02em;
}
.ll-cart-tot em {
  font-style: normal;
  font-size: 10px;
  font-weight: 700;
  color: #6b6b6b;
  margin-left: 5px;
}
.ll-cart-cta {
  display: block;
  width: 100%;
  padding: 15px;
  border: 0;
  border-radius: 11px;
  background: #ffc600;
  color: #111;
  font-family: inherit;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background .18s ease;
}
.ll-cart-cta:hover { background: #ffd23f; color: #111; text-decoration: none; }
.ll-cart-cta:focus-visible { outline: 3px solid #1a1a1a; outline-offset: 2px; }
.ll-cart-lien {
  display: block;
  width: 100%;
  margin-top: 9px;
  padding: 4px;
  background: none;
  border: 0;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: #6b6b6b;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

/* ---------- mobile : feuille basse ---------- */
@media (max-width: 767px) {
  .ll-cart-drawer {
    top: auto;
    left: 0;
    right: 0;
    width: auto;
    max-width: none;
    max-height: 88%;
    border-radius: 20px 20px 0 0;
    box-shadow: 0 -14px 50px rgba(0, 0, 0, .4);
    transform: translateY(100%);
  }
  .ll-cart-drawer.is-open { transform: none; }
  .ll-cart-tete { border-radius: 20px 20px 0 0; padding-top: 20px; }
  .ll-cart-grip {
    display: block;
    position: absolute;
    top: 7px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 4px;
    border-radius: 99px;
    background: #5a5a5a;
    z-index: 2;
  }
  body.ll-cart-lock { overflow: hidden; }
}

@media (prefers-reduced-motion: reduce) {
  .ll-cart-drawer,
  .ll-cart-overlay { transition: none; }
  .ll-cart-chev i { animation: none; opacity: .6; }
}
