/* ============================================================
   DEVIS PAGE — Multi-step form conversion optimized
   LeaseCare — Design system: santé premium (theme-15)
   ============================================================ */

/* Hero section */
.devis-hero {
    background: linear-gradient(135deg, var(--brand-dark, #043833) 0%, var(--brand-secondary, #103a36) 100%);
    padding: clamp(2.5rem, 5vw, 4rem) 0;
    color: #fff;
}

.devis-hero-title {
    font-family: 'Hanken Grotesk', system-ui, sans-serif;
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: #fff;
}

.devis-hero-title .highlight {
    color: var(--brand-primary, #aad440);
}

.devis-hero-subtitle {
    font-size: clamp(1rem, 1.5vw, 1.125rem);
    color: rgba(255, 255, 255, 0.85);
    max-width: 540px;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.devis-hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.badge-trust {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(170, 212, 64, 0.12);
    border: 1px solid rgba(170, 212, 64, 0.3);
    border-radius: 100px;
    padding: 0.4rem 0.85rem;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--brand-primary, #aad440);
    white-space: nowrap;
}

.badge-trust i {
    font-size: 0.75rem;
}

/* Hero stats */
.devis-hero-stats {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
}

.stat-item {
    text-align: center;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 1.25rem 1rem;
    min-width: 90px;
}

.stat-number {
    display: block;
    font-family: 'Hanken Grotesk', system-ui, sans-serif;
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--brand-primary, #aad440);
    line-height: 1;
    margin-bottom: 0.3rem;
}

.stat-label {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

/* Form section */
.devis-form-section {
    padding: clamp(2rem, 4vw, 3.5rem) 0 clamp(3rem, 5vw, 5rem);
    background: var(--color-bg-alt, #f4f6f8);
}

/* Form card */
.devis-form-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 32px rgba(4, 56, 51, 0.08), 0 1px 3px rgba(0, 0, 0, 0.04);
    padding: clamp(1.5rem, 3vw, 2.5rem);
    position: relative;
}

/* Progress bar */
.devis-progress {
    margin-bottom: 2rem;
}

.devis-progress-bar {
    height: 4px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.devis-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--brand-secondary, #103a36), var(--brand-primary, #aad440));
    border-radius: 4px;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.devis-progress-steps {
    display: flex;
    justify-content: space-between;
}

.progress-step {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    opacity: 0.4;
    transition: opacity 0.3s;
}

.progress-step.active,
.progress-step.completed {
    opacity: 1;
}

.step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 600;
    background: #e9ecef;
    color: var(--color-text-muted, #64748b);
    transition: all 0.3s;
}

.progress-step.active .step-num {
    background: var(--brand-secondary, #103a36);
    color: #fff;
}

.progress-step.completed .step-num {
    background: var(--brand-primary, #aad440);
    color: var(--brand-dark, #043833);
}

.step-label {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--color-text-muted, #64748b);
}

.progress-step.active .step-label {
    color: var(--brand-secondary, #103a36);
    font-weight: 600;
}

/* Steps */
.devis-step {
    display: none;
    border: none;
    padding: 0;
    margin: 0;
    animation: fadeInStep 0.35s ease;
}

.devis-step.active {
    display: block;
}

@keyframes fadeInStep {
    from {
        opacity: 0;
        transform: translateX(12px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.devis-step-title {
    font-family: 'Hanken Grotesk', system-ui, sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--brand-secondary, #103a36);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.devis-step-title i {
    color: var(--brand-primary, #aad440);
    font-size: 1.1rem;
}

.devis-step-desc {
    color: var(--color-text-muted, #64748b);
    font-size: 0.92rem;
    margin-bottom: 1.75rem;
    line-height: 1.5;
}

/* Form groups */
.form-group {
    margin-bottom: 1.25rem;
}

.form-label {
    display: block;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--color-text, #0f172a);
    margin-bottom: 0.4rem;
}

.required {
    color: #ef4444;
}

.recommended {
    font-weight: 400;
    color: var(--color-text-muted, #64748b);
    font-size: 0.82rem;
}

.form-control {
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1.5px solid var(--color-border, #e2e8f0);
    border-radius: 10px;
    font-size: 0.95rem;
    transition: border-color 0.2s, box-shadow 0.2s;
    background: #fff;
    color: var(--color-text, #0f172a);
}

.form-control:focus {
    outline: none;
    border-color: var(--brand-primary, #aad440);
    box-shadow: 0 0 0 3px rgba(170, 212, 64, 0.15);
}

.form-control.is-invalid {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-control.is-valid {
    border-color: var(--brand-primary, #aad440);
}

.select-wrapper {
    position: relative;
}

.form-select {
    appearance: none;
    padding-right: 2.5rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M8 11.5l-5-5h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
}

.field-error {
    display: block;
    font-size: 0.8rem;
    color: #ef4444;
    margin-top: 0.3rem;
    min-height: 1.1em;
}

.devis-equipement-field.is-visible {
    animation: fadeInStep 0.35s ease;
}

.devis-equipement-hint {
    font-size: 0.85rem;
    color: var(--color-text-muted, #64748b);
    margin: -0.25rem 0 0.75rem;
}

.devis-equipement-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    max-height: 280px;
    overflow-y: auto;
    padding: 0.25rem;
    margin-bottom: 0.75rem;
    border: 1.5px solid var(--color-border, #e2e8f0);
    border-radius: 12px;
    background: var(--color-bg-alt, #f8fafc);
}

.devis-equipement-list.is-invalid {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.12);
}

.devis-equipement-option {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    margin: 0;
}

.devis-equipement-option input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.devis-equipement-option span {
    display: inline-block;
    padding: 0.45rem 0.85rem;
    border: 1.5px solid var(--color-border, #e2e8f0);
    border-radius: 100px;
    font-size: 0.82rem;
    font-weight: 500;
    line-height: 1.3;
    transition: all 0.2s;
    background: #fff;
    color: var(--color-text, #0f172a);
}

.devis-equipement-option input:checked + span {
    border-color: var(--brand-primary, #aad440);
    background: rgba(170, 212, 64, 0.12);
    color: var(--brand-secondary, #103a36);
    font-weight: 600;
    box-shadow: 0 0 0 3px rgba(170, 212, 64, 0.12);
}

.devis-equipement-option span:hover {
    border-color: var(--brand-primary, #aad440);
}

.devis-equipement-autre-toggle {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    margin: 0;
}

.devis-equipement-autre-toggle input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.devis-equipement-autre-toggle span {
    display: inline-block;
    padding: 0.45rem 0.85rem;
    border: 1.5px dashed var(--color-border, #cbd5e1);
    border-radius: 100px;
    font-size: 0.82rem;
    font-weight: 500;
    transition: all 0.2s;
    background: #fff;
    color: var(--color-text-muted, #64748b);
}

.devis-equipement-autre-toggle input:checked + span {
    border-style: solid;
    border-color: var(--brand-primary, #aad440);
    background: rgba(170, 212, 64, 0.1);
    color: var(--brand-secondary, #103a36);
    font-weight: 600;
}

.devis-equipement-autre-toggle span:hover {
    border-color: var(--brand-primary, #aad440);
    color: var(--brand-secondary, #103a36);
}

/* Radio cards */
.radio-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.radio-cards-2col {
    grid-template-columns: repeat(2, 1fr);
}

.radio-card {
    cursor: pointer;
}

.radio-card input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.radio-card-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 0.75rem;
    border: 1.5px solid var(--color-border, #e2e8f0);
    border-radius: 12px;
    text-align: center;
    transition: all 0.2s;
    background: #fff;
}

.radio-card-inner i {
    font-size: 1.25rem;
    color: var(--color-text-muted, #64748b);
    transition: color 0.2s;
}

.radio-card-label {
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--color-text, #0f172a);
    line-height: 1.3;
}

.radio-card input:checked + .radio-card-inner {
    border-color: var(--brand-primary, #aad440);
    background: rgba(170, 212, 64, 0.06);
    box-shadow: 0 0 0 3px rgba(170, 212, 64, 0.12);
}

.radio-card input:checked + .radio-card-inner i {
    color: var(--brand-secondary, #103a36);
}

.radio-card-inner:hover {
    border-color: var(--brand-primary, #aad440);
    transform: translateY(-1px);
}

/* Radio inline group */
.radio-inline-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.radio-inline {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
}

.radio-inline input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.radio-inline span {
    display: inline-block;
    padding: 0.5rem 1rem;
    border: 1.5px solid var(--color-border, #e2e8f0);
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s;
    background: #fff;
}

.radio-inline input:checked + span {
    border-color: var(--brand-primary, #aad440);
    background: rgba(170, 212, 64, 0.1);
    color: var(--brand-secondary, #103a36);
    font-weight: 600;
}

.radio-inline span:hover {
    border-color: var(--brand-primary, #aad440);
}

/* Step actions — layout uniquement ; styles bouton via .contact-form-actions (catalog-pages.css) */
.devis-step-actions.contact-form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border, #e2e8f0);
    gap: 1rem;
}

.devis-step-actions.contact-form-actions .btn-primary {
    margin-left: auto;
}

.devis-step-actions.contact-form-actions .btn-primary:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.devis-step-actions.contact-form-actions .btn-loading {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* Alerts */
.devis-alerts {
    margin-bottom: 1rem;
}

.devis-alerts:empty {
    display: none;
}

.devis-alert {
    padding: 0.85rem 1rem;
    border-radius: 10px;
    font-size: 0.88rem;
    line-height: 1.5;
}

.devis-alert-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

.devis-alert-error ul {
    margin: 0.4rem 0 0;
    padding-left: 1.2rem;
}

/* Success */
.devis-success {
    text-align: center;
    padding: 2rem 1rem;
}

.devis-success-inner {
    max-width: 480px;
    margin: 0 auto;
}

.devis-success-icon {
    font-size: 3.5rem;
    color: var(--brand-primary, #aad440);
    margin-bottom: 1rem;
}

.devis-success-title {
    font-family: 'Hanken Grotesk', system-ui, sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--brand-secondary, #103a36);
    margin-bottom: 0.75rem;
}

.devis-success-text {
    color: var(--color-text-muted, #64748b);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.devis-success-subtitle {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-text, #0f172a);
    margin-bottom: 0.75rem;
}

.devis-success-links {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.success-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    background: var(--color-bg-alt, #f4f6f8);
    border-radius: 8px;
    color: var(--brand-secondary, #103a36);
    font-size: 0.88rem;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.2s;
}

.success-link:hover {
    background: rgba(170, 212, 64, 0.12);
}

/* Honeypot — réutilise .contact-honeypot (catalog-pages.css) */

/* Consent */
.form-check {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.form-check-input {
    margin-top: 0.2rem;
    flex-shrink: 0;
}

.form-legal {
    font-size: 0.8rem;
    color: var(--color-text-muted, #64748b);
    line-height: 1.5;
}

.form-legal a {
    color: var(--brand-secondary, #103a36);
    text-decoration: underline;
}

/* Sidebar */
.devis-sidebar {
    position: sticky;
    top: 100px;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.trust-card {
    background: #fff;
    border-radius: 14px;
    padding: 1.5rem;
    box-shadow: 0 2px 12px rgba(4, 56, 51, 0.06);
}

.trust-card-title {
    font-family: 'Hanken Grotesk', system-ui, sans-serif;
    font-size: 1rem;
    font-weight: 700;
    color: var(--brand-secondary, #103a36);
    margin-bottom: 1rem;
}

.trust-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.trust-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 0.5rem 0;
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--color-text, #0f172a);
}

.trust-list li i {
    color: var(--brand-primary, #aad440);
    font-size: 0.9rem;
    margin-top: 0.15rem;
    flex-shrink: 0;
}

/* Process list */
.process-list {
    list-style: none;
    padding: 0;
    margin: 0;
    counter-reset: process;
}

.process-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.6rem 0;
}

.process-list li + li {
    border-top: 1px solid var(--color-border, #e2e8f0);
}

.process-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(170, 212, 64, 0.15);
    color: var(--brand-secondary, #103a36);
    font-size: 0.8rem;
    font-weight: 700;
    flex-shrink: 0;
}

.process-list strong {
    display: block;
    font-size: 0.85rem;
    margin-bottom: 0.15rem;
}

.process-list p {
    font-size: 0.78rem;
    color: var(--color-text-muted, #64748b);
    margin: 0;
    line-height: 1.4;
}

/* Testimonial */
.trust-card-testimonial {
    background: var(--brand-dark, #043833);
    color: #fff;
}

.testimonial-quote p {
    font-size: 0.88rem;
    font-style: italic;
    line-height: 1.6;
    margin-bottom: 0.75rem;
    color: rgba(255, 255, 255, 0.9);
}

.testimonial-quote footer {
    display: flex;
    flex-direction: column;
}

.testimonial-quote footer strong {
    font-size: 0.85rem;
    color: var(--brand-primary, #aad440);
}

.testimonial-quote footer span {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.6);
}

/* ============================================================
   Responsive
   ============================================================ */

@media (max-width: 991px) {
    .devis-sidebar {
        position: static;
        margin-top: 2rem;
    }

    .devis-form-section .row {
        flex-direction: column-reverse;
    }
}

@media (max-width: 767px) {
    .radio-cards {
        grid-template-columns: 1fr;
    }

    .radio-cards-2col {
        grid-template-columns: 1fr;
    }

    .devis-hero-badges {
        flex-direction: column;
        align-items: flex-start;
    }

    .devis-step-actions.contact-form-actions {
        flex-direction: column-reverse;
        gap: 0.75rem;
    }

    .devis-step-actions.contact-form-actions .btn-primary,
    .devis-step-actions.contact-form-actions .btn-outline-secondary {
        width: 100%;
        justify-content: center;
        margin-left: 0;
    }

    .step-label {
        display: none;
    }

    .devis-form-card {
        padding: 1.25rem;
        border-radius: 12px;
    }

    .radio-inline-group {
        flex-direction: column;
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    .radio-cards {
        grid-template-columns: repeat(3, 1fr);
    }

    .radio-cards-2col {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .devis-step {
        animation: none;
    }

    .devis-progress-fill {
        transition: none;
    }

    .radio-card-inner:hover {
        transform: none;
    }
}
