/* ===========================================================
   BJL · Devis (wizard)
   =========================================================== */
.bjl-d{ --bjl-accent:#ff6301; --bjl-primary:#1f1e8f; }
.bjl-d-card{
    background:#fff;
    border-radius:22px;
    padding:40px;
    max-width:780px;
    margin:0 auto;
}
.bjl-d-title{ color:var(--bjl-primary); font-size:clamp(1.5rem,2.6vw,2rem); font-weight:800; margin:0 0 8px; text-align:center; }
.bjl-d-sub{ color:#5a6472; font-size:1.02rem; line-height:1.6; margin:0 0 28px; text-align:center; }

/* ---- Barre d'étapes ---- */
.bjl-d-bar{ position:relative; margin:0 0 34px; }
.bjl-d-bar-line{
    position:absolute;
    top:19px; left:8%; right:8%;
    height:3px;
    background:#e7eaf2;
    border-radius:3px;
    z-index:0;
}
.bjl-d-bar-fill{
    display:block; height:100%; width:0%;
    background:linear-gradient(90deg, var(--bjl-accent), #ff8a3d);
    border-radius:3px;
    transition:width .4s cubic-bezier(.2,.8,.2,1);
}
.bjl-d-bar-steps{ position:relative; z-index:1; display:flex; justify-content:space-between; }
.bjl-d-bar-step{ display:flex; flex-direction:column; align-items:center; gap:8px; flex:1; }
.bjl-d-bar-step span{
    width:40px; height:40px;
    display:flex; align-items:center; justify-content:center;
    border-radius:50%;
    background:#fff;
    border:3px solid #e7eaf2;
    color:#9aa3b2;
    font-weight:800;
    font-size:15px;
    transition:all .3s ease;
}
.bjl-d-bar-step em{ font-style:normal; font-size:.8rem; font-weight:600; color:#9aa3b2; transition:color .3s ease; }
.bjl-d-bar-step.is-active span,
.bjl-d-bar-step.is-done span{
    background:var(--bjl-accent);
    border-color:var(--bjl-accent);
    color:#fff;
    box-shadow:0 6px 16px rgba(255,99,1,0.3);
}
.bjl-d-bar-step.is-active em,
.bjl-d-bar-step.is-done em{ color:var(--bjl-primary); }

/* ---- Étapes ---- */
.bjl-d-step{ display:none; animation:bjlDFade .45s ease; }
.bjl-d-step.is-active{ display:block; }
@keyframes bjlDFade{ from{ opacity:0; transform:translateX(20px); } to{ opacity:1; transform:none; } }

.bjl-d-step-title{ color:var(--bjl-primary); font-size:1.3rem; font-weight:800; margin:0 0 6px; }
.bjl-d-hint{ color:#7a8494; font-size:.92rem; margin:0 0 20px; }

/* ---- Cartes prestations (multi-sélection) ---- */
.bjl-d-prest-grid{
    display:grid;
    grid-template-columns:repeat(2, 1fr);
    gap:14px;
    margin-bottom:28px;
}
.bjl-d-prest{
    position:relative;
    display:flex;
    align-items:center;
    gap:13px;
    padding:18px 18px;
    background:#f5f6fa;
    border:2px solid #e7eaf2;
    border-radius:14px;
    cursor:pointer;
    transition:all .22s ease;
    user-select:none;
}
.bjl-d-prest:hover{ transform:translateY(-2px); border-color:var(--bjl-accent); }
.bjl-d-prest input{ position:absolute; opacity:0; pointer-events:none; }
.bjl-d-prest-ic{
    flex:0 0 auto;
    width:44px; height:44px;
    display:flex; align-items:center; justify-content:center;
    border-radius:11px;
    background:#fff;
    color:var(--bjl-accent);
    font-size:18px;
    transition:all .22s ease;
}
.bjl-d-prest-ic svg{ width:1em; height:1em; fill:currentColor; }
.bjl-d-prest > span:nth-child(3){ font-weight:600; color:#2a3140; font-size:.98rem; line-height:1.3; flex:1; }
.bjl-d-prest-check{
    flex:0 0 auto;
    width:24px; height:24px;
    display:flex; align-items:center; justify-content:center;
    border-radius:50%;
    background:var(--bjl-accent);
    color:#fff;
    opacity:0;
    transform:scale(.5);
    transition:all .22s ease;
}
.bjl-d-prest.is-selected{
    background:rgba(255,99,1,0.10);
    border-color:var(--bjl-accent);
}
.bjl-d-prest.is-selected .bjl-d-prest-ic{ background:var(--bjl-accent); color:#fff !important; }
.bjl-d-prest.is-selected .bjl-d-prest-ic svg{ stroke:#fff; fill:#fff; }
.bjl-d-prest.is-selected .bjl-d-prest-check{ opacity:1; transform:scale(1); }

/* ---- Champs (labels au-dessus) ---- */
.bjl-d-row{ display:grid; grid-template-columns:1fr 1fr; gap:16px; }
.bjl-d-fld{ position:relative; margin-bottom:16px; display:flex; flex-direction:column; gap:7px; }
.bjl-d-lbl{
    font-size:12px; font-weight:700; letter-spacing:.04em;
    text-transform:uppercase; color:var(--bjl-primary);
}
.bjl-d-field{
    width:100%;
    height:54px;
    padding:0 16px;
    background:#f5f6fa;
    border:1.5px solid #e3e6ee;
    border-radius:12px;
    font-size:15px;
    line-height:54px;
    color:#2a3140;
    font-family:inherit;
    box-sizing:border-box;
    transition:border-color .25s ease, box-shadow .25s ease, background .25s ease;
    appearance:none; -webkit-appearance:none;
}
.bjl-d-field::placeholder{ color:#9aa3b2; }
.bjl-d-field:focus{ outline:none; border-color:var(--bjl-accent); background:#fff; box-shadow:0 0 0 4px rgba(255,99,1,0.10); }
textarea.bjl-d-field{ height:auto; resize:vertical; min-height:120px; padding:14px 16px; line-height:1.5; }
.bjl-d-fld-select{ position:relative; }
.bjl-d-fld-select::after{
    content:""; position:absolute; right:18px; bottom:21px;
    width:9px; height:9px;
    border-right:2px solid #9aa3b2; border-bottom:2px solid #9aa3b2;
    transform:rotate(45deg); pointer-events:none;
}
select.bjl-d-field{ height:54px; line-height:54px; cursor:pointer; padding-right:40px; }
select.bjl-d-field:invalid{ color:#9aa3b2; }

.bjl-d-hp{ position:absolute !important; left:-9999px !important; width:1px; height:1px; opacity:0; }

.bjl-d-rgpd{
    display:flex; align-items:flex-start; gap:9px;
    font-size:.82rem; color:#6b7484; line-height:1.45;
    margin:6px 0 4px;
}
.bjl-d-rgpd input{ margin-top:3px; flex:0 0 auto; accent-color:var(--bjl-accent); }
.bjl-d-rgpd a{ color:var(--bjl-accent); font-weight:600; text-decoration:underline; }

/* ---- Navigation ---- */
.bjl-d-nav{ display:flex; align-items:center; justify-content:space-between; gap:14px; margin-top:24px; }
.bjl-d-next, .bjl-d-submit{
    padding:15px 32px; border:none; border-radius:10px;
    background:linear-gradient(135deg, #ff6301, #ff8a3d);
    color:#fff; font-size:15px; font-weight:700; cursor:pointer;
    transition:transform .25s ease, box-shadow .3s ease, opacity .2s ease;
    box-shadow:0 10px 26px rgba(255,99,1,0.28);
}
.bjl-d-next:hover, .bjl-d-submit:hover{ transform:translateY(-2px); box-shadow:0 14px 32px rgba(255,99,1,0.4); }
.bjl-d-submit:disabled{ opacity:.6; cursor:wait; transform:none; }
.bjl-d-prev{
    padding:15px 28px; border:2px solid var(--bjl-primary) !important; border-radius:10px;
    background:transparent !important; color:var(--bjl-primary) !important; font-size:15px; font-weight:600; cursor:pointer;
    transition:all .25s ease;
}
.bjl-d-prev:hover{ background:var(--bjl-primary) !important; color:#fff !important; }

.bjl-d-feedback{
    font-size:.92rem; font-weight:600;
    max-height:0; overflow:hidden; padding:0;
    transition:max-height .3s ease, padding .3s ease; margin-top:14px;
}
.bjl-d-feedback.show{ max-height:120px; padding:13px 16px; border-radius:10px; }
.bjl-d-feedback.ok{ background:rgba(34,160,90,0.12); color:#1d8a4e; }
.bjl-d-feedback.err{ background:rgba(217,20,21,0.1); color:#c8181a; }

/* ---- Popup de confirmation ---- */
.bjl-d-modal{
    position:fixed;
    inset:0;
    z-index:99999;
    display:none;
    align-items:center;
    justify-content:center;
    padding:20px;
}
.bjl-d-modal.is-open{ display:flex; }
.bjl-d-modal-overlay{
    position:absolute; inset:0;
    background:rgba(15,15,40,0.55);
    backdrop-filter:blur(4px);
    animation:bjlOverlay .3s ease;
}
@keyframes bjlOverlay{ from{ opacity:0; } to{ opacity:1; } }
.bjl-d-modal-box{
    position:relative;
    background:#fff;
    border-radius:22px;
    padding:44px 38px 36px;
    max-width:440px;
    width:100%;
    text-align:center;
    box-shadow:0 30px 80px rgba(15,15,40,0.35);
    animation:bjlPop .45s cubic-bezier(.34,1.56,.64,1);
}
@keyframes bjlPop{ from{ opacity:0; transform:translateY(30px) scale(.92); } to{ opacity:1; transform:none; } }
.bjl-d-modal-ic{
    width:84px; height:84px; margin:0 auto 22px;
    display:flex; align-items:center; justify-content:center;
    border-radius:50%;
    background:linear-gradient(135deg, #22a05a, #34c971);
    color:#fff;
    box-shadow:0 14px 32px rgba(34,160,90,0.35);
    animation:bjlIcPop .6s cubic-bezier(.34,1.56,.64,1) .15s both;
}
@keyframes bjlIcPop{ from{ transform:scale(0) rotate(-20deg); } to{ transform:scale(1) rotate(0); } }
.bjl-d-modal-title{ color:var(--bjl-primary); font-size:1.6rem; font-weight:800; margin:0 0 10px; }
.bjl-d-modal-msg{ color:#5a6472; font-size:1.02rem; line-height:1.6; margin:0 0 26px; }
.bjl-d-modal-btn{
    padding:15px 40px !important; border:none !important; border-radius:50px !important;
    background:linear-gradient(135deg, #ff6301, #ff8a3d) !important;
    color:#fff !important; font-size:15px; font-weight:700; cursor:pointer;
    transition:transform .25s ease, box-shadow .3s ease;
    box-shadow:0 10px 26px rgba(255,99,1,0.3);
}
.bjl-d-modal-btn:hover{ transform:translateY(-2px); box-shadow:0 14px 32px rgba(255,99,1,0.42); }

/* ---- Responsive ---- */
@media (max-width:640px){
    .bjl-d-card{ padding:28px 20px; border-radius:18px; }
    .bjl-d-prest-grid{ grid-template-columns:1fr; }
    .bjl-d-row{ grid-template-columns:1fr; gap:0; }
    .bjl-d-bar-step em{ font-size:.7rem; }
    .bjl-d-nav{ flex-direction:row; }
    .bjl-d-next, .bjl-d-submit, .bjl-d-prev{ padding:14px 20px; font-size:14px; }
}
