/* =========================================================
   JPWeb — QUESTIONNAIRES
   CSS commun — Charte noir, jaune, rouge
   ========================================================= */

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

body {
    background: #eeeeee;
    color: #222222;
    font-family: Arial, Helvetica, sans-serif;
    line-height: 1.6;
}


/* =========================================================
   CONTENEUR PRINCIPAL
   ========================================================= */

.conteneur {
    width: 100%;
    max-width: 1000px;
    margin: 35px auto;
    padding: 0 20px;
}


/* =========================================================
   FORMULAIRE
   ========================================================= */

.formulaire {
    position: relative;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #dddddd;
    border-top: 7px solid #222222;
    border-radius: 12px;
    padding: 38px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.10);
}

.formulaire::before {
    content: "";
    display: block;
    width: 85px;
    height: 6px;
    margin-bottom: 20px;
    background: #ffcc00;
    border-radius: 3px;
}


/* =========================================================
   TITRES
   ========================================================= */

.formulaire h1 {
    margin: 0 0 15px;
    color: #222222;
    font-size: 36px;
    font-weight: 800;
    line-height: 1.2;
}

.formulaire h2 {
    margin: 38px 0 22px;
    padding-bottom: 12px;
    border-bottom: 3px solid #ffcc00;
    color: #222222;
    font-size: 25px;
    font-weight: 700;
    line-height: 1.35;
}


/* =========================================================
   INTRODUCTION
   ========================================================= */

.intro {
    margin: 0 0 22px;
    color: #c90024;
    font-size: 19px;
    font-weight: 700;
}

.formulaire p {
    margin-top: 15px;
    margin-bottom: 15px;
}


/* =========================================================
   ERREUR
   ========================================================= */

.erreur {
    margin: 0 0 20px;
    padding: 14px 17px;
    background: #fff0f0;
    border: 1px solid #e3a0a0;
    border-left: 5px solid #d00025;
    border-radius: 6px;
    color: #8c0018;
}


/* =========================================================
   LABELS
   ========================================================= */

.formulaire label {
    display: block;
    margin: 18px 0 7px;
    color: #222222;
    font-weight: 700;
}

.obligatoire {
    color: #d00025;
}


/* =========================================================
   CHAMPS
   ========================================================= */

.formulaire input[type="text"],
.formulaire input[type="email"],
.formulaire input[type="tel"],
.formulaire textarea {
    display: block;
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #bbbbbb;
    border-radius: 6px;
    background: #ffffff;
    color: #222222;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 16px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.formulaire textarea {
    min-height: 120px;
    resize: vertical;
}

.formulaire input:focus,
.formulaire textarea:focus {
    outline: none;
    border-color: #d00025;
    box-shadow: 0 0 0 3px rgba(208, 0, 37, 0.12);
}


/* =========================================================
   BOUTONS
   ========================================================= */

.boutons {
    display: flex;
    align-items: stretch;
    justify-content: center;
    gap: 22px;
    margin-top: 30px;
}

.boutons button,
.boutons a {
    display: flex;
    flex: 1;
    align-items: center;
    justify-content: center;
    min-height: 76px;
    padding: 18px 24px;
    border: 2px solid transparent;
    border-radius: 10px;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 18px;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s,
                box-shadow 0.2s, transform 0.2s;
}

/* Site personnel : jaune et texte noir */

.boutons a:first-child {
    background: #ffcc00;
    color: #222222;
    border-color: #e6b800;
    box-shadow: 0 5px 0 #c9a000;
}

.boutons a:first-child:hover {
    background: #ffdb4d;
    border-color: #d9ad00;
    box-shadow: 0 3px 0 #b38b00;
    transform: translateY(2px);
}

/* Site professionnel : rouge et texte blanc */

.boutons a:nth-child(2) {
    background: #d00025;
    color: #ffffff;
    border-color: #b80020;
    box-shadow: 0 5px 0 #92001a;
}

.boutons a:nth-child(2):hover {
    background: #ad001f;
    border-color: #92001a;
    box-shadow: 0 3px 0 #780017;
    transform: translateY(2px);
}

/* Boutons d'action des autres questionnaires */

.boutons button {
    background: #222222;
    color: #ffffff;
    border-color: #222222;
    box-shadow: 0 4px 0 #000000;
}

.boutons button:hover {
    background: #444444;
}


/* =========================================================
   LIEN RETOUR
   ========================================================= */

.retour {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 17px;
    border: 1px solid #cccccc;
    border-radius: 6px;
    background: #f5f5f5;
    color: #222222;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
}

.retour:hover {
    background: #222222;
    border-color: #222222;
    color: #ffffff;
}


/* =========================================================
   PAGE DE CONFIRMATION
   ========================================================= */

.confirmation {
    width: calc(100% - 40px);
    max-width: 700px;
    margin: 60px auto;
    padding: 40px;
    background: #ffffff;
    border: 1px solid #dddddd;
    border-top: 7px solid #222222;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.10);
    text-align: center;
}

.confirmation h1 {
    margin-top: 0;
    color: #222222;
    font-size: 32px;
}

.confirmation p {
    margin: 12px 0;
}


/* =========================================================
   QUESTIONNAIRE PERSONNEL
   ========================================================= */

.questionnaire {
    width: 100%;
    max-width: 700px;
    margin: 35px auto;
    padding: 35px;
    background: #ffffff;
    border: 1px solid #dddddd;
    border-top: 6px solid #222222;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.questionnaire h1 {
    margin-top: 0;
    color: #222222;
}

.questionnaire .question {
    margin-bottom: 24px;
}

.questionnaire label.titre {
    display: block;
    margin-bottom: 8px;
    color: #222222;
    font-weight: 700;
}

.questionnaire .aide {
    margin: 0 0 10px;
    color: #666666;
    font-size: 14px;
}

.questionnaire .champ {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #bbbbbb;
    border-radius: 6px;
    background: #ffffff;
    color: #222222;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 16px;
}

.questionnaire .champ:focus {
    outline: none;
    border-color: #d00025;
    box-shadow: 0 0 0 3px rgba(208, 0, 37, 0.12);
}

.questionnaire textarea.champ {
    min-height: 120px;
    resize: vertical;
}

.questionnaire .choix {
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.questionnaire .choix label {
    display: block;
    margin: 0;
    padding: 11px 13px;
    border: 1px solid #dddddd;
    border-radius: 6px;
    background: #ffffff;
    font-weight: normal;
    transition: background 0.2s, border-color 0.2s;
}

.questionnaire .choix label:hover {
    background: #fff9df;
    border-color: #e6b800;
}


/* =========================================================
   ACCESSIBILITÉ
   ========================================================= */

.boutons a:focus-visible,
.boutons button:focus-visible,
.retour:focus-visible {
    outline: 3px solid #222222;
    outline-offset: 4px;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 700px) {

    .conteneur {
        margin: 18px auto;
        padding: 0 12px;
    }

    .formulaire {
        padding: 27px 20px;
        border-radius: 9px;
    }

    .formulaire h1 {
        font-size: 29px;
    }

    .formulaire h2 {
        margin-top: 30px;
        font-size: 21px;
    }

    .intro {
        font-size: 17px;
    }

    .boutons {
        flex-direction: column;
        gap: 17px;
        margin-top: 25px;
    }

    .boutons button,
    .boutons a {
        width: 100%;
        min-height: 65px;
        padding: 16px;
        font-size: 17px;
    }

    .confirmation {
        margin: 25px auto;
        padding: 28px 20px;
    }

    .confirmation h1 {
        font-size: 27px;
    }

    .questionnaire {
        margin: 18px auto;
        padding: 25px 18px;
    }
}


/* =========================================================
   PETITS ÉCRANS
   ========================================================= */

@media (max-width: 380px) {

    .formulaire {
        padding: 23px 15px;
    }

    .formulaire h1 {
        font-size: 26px;
    }

    .formulaire h2 {
        font-size: 19px;
    }
}