/* =============================================================================
   Page publique d'inscription — Alliance Réseaux

   Les styles reprennent ceux de
   https://www.alliance-reseaux.com/centrevaldeloire/utilisateur.htm
   (en-tête, pied de page, palette, sections, cartes, boutons), afin que le
   visiteur arrivant depuis cette page ne perçoive aucune rupture visuelle.

   Feuille autonome : aucune ressource externe n'est chargée.
   ============================================================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* L'attribut hidden doit masquer, quelle que soit la classe portée.

   Le navigateur applique bien [hidden] { display: none }, mais depuis SA feuille
   de style : la moindre regle display ecrite ici l'emporte. C'est ce qui rendait
   #blocCgv visible malgre son attribut hidden, .feature-row etant en flex — le
   bloc des conditions generales s'affichait donc avant meme qu'un logiciel soit
   choisi. Le !important est ici a sa place : il n'arbitre pas une preference de
   presentation, il retablit une regle du langage. */
[hidden] { display: none !important; }

body {
    font-family: "Segoe UI", Arial, sans-serif;
    color: #111;
    background: #fff;
    line-height: 1.65;
}

:root {
    --orange: #e8650a;
    --orange-dark: #c2530a;
    --orange-light: #fff4ec;
    --navy: #1c2740;
    --navy-mid: #2a3a56;
    --navy-light: #edf0f7;
    --black: #111111;
    --gray-bg: #f5f6f7;
    --border: #e0e2e5;
    --text: #111111;
    --text-mid: #444;
    --text-light: #777;
    --white: #ffffff;
}

h1 { font-size: 2.6rem; font-weight: 800; line-height: 1.2; }
h2 { font-size: 1.9rem; font-weight: 700; line-height: 1.25; }
h3 { font-size: 1.2rem; font-weight: 700; }
h4 { font-size: 1rem; font-weight: 700; }

.container {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 28px;
}

.section {
    padding: 76px 0;
}

/* Le site n'attribue aucun style à .wrapper, ses grilles d'offres occupant
   toute la largeur. Un formulaire de saisie sur 1080 px serait illisible : on
   le contraint donc ici, tout en conservant le conteneur du site. */
.wrapper {
    max-width: 760px;
    margin: 0 auto;
}

.section-eyebrow {
    display: inline-block;
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--orange);
    background: var(--orange-light);
    padding: 4px 14px;
    border-radius: 20px;
    margin-bottom: 12px;
}

.divider {
    width: 44px;
    height: 3px;
    background: var(--orange);
    border-radius: 2px;
    margin: 14px 0 28px;
}

.divider.center {
    margin-left: auto;
    margin-right: auto;
}

.text-center { text-align: center; }

/* --- Boutons ------------------------------------------------------------- */

.btn {
    display: inline-block;
    padding: 13px 26px;
    border-radius: 5px;
    font-size: 0.93rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: opacity 0.18s, transform 0.15s;
    letter-spacing: 0.01em;
}

.btn:hover {
    opacity: 0.88;
    transform: translateY(-1px);
}

.btn-navy { background: var(--navy); color: white; }

.btn-outline-navy {
    background: transparent;
    color: var(--navy);
    border: 2px solid var(--navy);
}

.btn-header {
    padding: 10px 18px;
    font-size: 0.82rem;
    border-radius: 5px;
    white-space: nowrap;
}

.btn-retour {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* Flèche gauche construite avec deux bordures pivotées. */
.btn-retour::before {
    content: "";
    display: inline-block;
    width: 8px;
    height: 8px;
    border-left: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
}

.btn-cta {
    display: block;
    width: 100%;
    text-align: center;
    padding: 15px 24px;
    border-radius: 7px;
    font-size: 0.97rem;
    font-weight: 700;
    font-family: inherit;
    text-decoration: none;
    letter-spacing: 0.01em;
    transition: opacity 0.18s, transform 0.15s;
    cursor: pointer;
    border: none;
    background: var(--navy);
    color: white;
}

.btn-cta:hover {
    opacity: 0.88;
    transform: translateY(-1px);
}

/* --- En-tête ------------------------------------------------------------- */

header {
    background: white;
    border-bottom: 1px solid var(--border);
    padding: 16px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
}

.header-logos {
    display: flex;
    align-items: center;
    gap: 20px;
}

.logo-ar {
    display: flex;
    flex-direction: column;
    gap: 0;
    line-height: 1;
}

.logo-ar img {
    max-width: 230px;
    width: 100%;
}

.header-actions {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

/* --- Carte, sur le modèle des cartes d'offre du site --------------------- */

.offer-card {
    background: white;
    border-radius: 14px;
    border: 2px solid var(--navy);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.card-header {
    padding: 26px 30px 24px;
    background: #f8f9fb;
    border-bottom: 1px solid var(--border);
}

.offer-block {
    display: flex;
    align-items: center;
    gap: 10px;
}

.offer-name {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--navy);
    text-transform: uppercase;
}

.offer-label {
    padding: 5px 12px;
    border-radius: 20px;
    color: var(--orange);
    background: var(--orange-light);
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
}

.card-body {
    padding: 24px 30px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-footer {
    padding: 0 30px 30px;
    margin-top: auto;
}

.feature-row {
    padding: 18px 0;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.feature-row:last-child {
    border-bottom: none;
}

/* Le premier groupe suit immédiatement le rembourrage haut de la carte :
   inutile d'y ajouter l'espacement complet. */
.card-body > .feature-row:first-child {
    padding-top: 2px;
}

/* Mention discrète, telle qu'employée par le site dans ses cartes d'offre.
   Réservée aux textes secondaires — pas aux titres de section du formulaire. */
.feature-label {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-light);
    margin-bottom: 2px;
}

/* Titre de groupe de champs. Doit rester nettement lisible : c'est lui qui
   structure la saisie. Repère orange repris du .divider de la page, libellé en
   bleu marine, puis filet horizontal jusqu'au bord de la carte. */
.groupe-titre {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    font-size: 0.95rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--navy);
    line-height: 1.3;
}

.groupe-titre::before {
    content: "";
    flex-shrink: 0;
    width: 18px;
    height: 3px;
    border-radius: 2px;
    background: var(--orange);
}

.groupe-titre::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--border);
}

/* --- Formulaire ---------------------------------------------------------- */

.ligne { display: flex; gap: 16px; }
.ligne .champ { flex: 1; }
.champ-court { max-width: 190px; }

.champ { margin-bottom: 16px; }
.champ:last-child { margin-bottom: 0; }

.champ label {
    display: block;
    margin-bottom: 5px;
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-mid);
    line-height: 1.3;
}

.champ input,
.champ select {
    width: 100%;
    padding: 11px 13px;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text);
    line-height: 1.3;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: white;
}

.champ input:focus,
.champ select:focus {
    outline: none;
    border-color: var(--navy);
    box-shadow: 0 0 0 3px rgba(28, 39, 64, 0.12);
}

.champ-case {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.champ-case input {
    margin-top: 5px;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    accent-color: var(--navy);
}

.champ-case label {
    font-size: 0.92rem;
    color: var(--text-mid);
    line-height: 1.5;
}

.champ-case a {
    color: var(--orange-dark);
    font-weight: 700;
}

.aide {
    display: block;
    margin-top: 4px;
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.55;
}

/* Champ leurre anti-robot : hors écran plutôt que display:none, que certains
   robots savent détecter. */
.leurre {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* --- Messages ------------------------------------------------------------ */

.erreur-champ {
    display: block;
    margin-top: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #b3261e;
}

.erreur-champ:empty { display: none; }

.message-erreur {
    background: #fdecea;
    border: 1px solid #f5c2bd;
    color: #b3261e;
    padding: 13px 16px;
    border-radius: 7px;
    margin-bottom: 22px;
    font-size: 0.92rem;
}

.message-erreur:empty { display: none; }

.message-erreur ul { list-style: none; }

.message-bloquant {
    font-size: 0.98rem;
    color: var(--text-mid);
}

/* Adresse du Service Client dans un message bloquant : meme traitement que
   dans la carte de fin d'inscription (.carte-message a). */
.message-bloquant a {
    color: var(--navy);
    font-weight: 600;
}

.pastille {
    width: 58px;
    height: 58px;
    line-height: 58px;
    border-radius: 50%;
    margin: 0 auto 18px;
    font-size: 1.7rem;
    color: #fff;
    text-align: center;
}

.pastille-ok { background: var(--navy); }
.pastille-attente { background: var(--orange); }

.message-titre {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--navy);
    margin-bottom: 12px;
}

.carte-message { text-align: center; }
.carte-message p { color: var(--text-mid); margin-bottom: 10px; }
.carte-message p:last-child { margin-bottom: 0; }

/* Adresse de contact du message de fin : la page n'a aucun style de lien par
   ailleurs, et le bleu par defaut du navigateur jurerait avec la palette. Le
   soulignement, lui, reste : c'est ce qui dit que l'adresse est cliquable. */
.carte-message a {
    color: var(--navy);
    font-weight: 600;
}

.reference {
    margin-top: 24px;
    font-size: 0.85rem;
    color: var(--text-light);
}

.reference code {
    background: var(--gray-bg);
    border: 1px solid var(--border);
    padding: 2px 7px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.actions-message {
    margin-top: 24px;
}

.actions-message .btn-cta {
    display: inline-block;
    width: auto;
}

/* --- Points de rupture, repris du site ----------------------------------- */

@media (max-width: 780px) {
    .header-actions { flex-direction: column; gap: 7px; }
    .header-logos { gap: 12px; }
    h2 { font-size: 1.4rem; }
    .section { padding: 48px 0; }
}

@media (max-width: 680px) {
    .section-title { font-size: 1.4rem; }
}

@media screen and (max-width: 560px) {
    .header-inner { gap: 12px; flex-direction: column; }
    .header-actions { flex-direction: row; gap: 7px; }

    .card-header { padding: 20px 20px 18px; }
    .card-body { padding: 18px 20px; }
    .card-footer { padding: 0 20px 22px; }

    .offer-block { flex-direction: column; align-items: flex-start; }
    .ligne { flex-direction: column; gap: 0; }
    .champ-court { max-width: none; }
}

/* --- Pied de page -------------------------------------------------------- */

footer {
    background: var(--navy);
    color: #777;
    padding: 36px 0;
    text-align: center;
    font-size: 0.82rem;
}

.footer-brand {
    color: white;
    font-weight: 700;
    font-size: 1.2rem;
    margin-bottom: 5px;
    line-height: 1.2rem;
}

.footer-address {
    color: white;
    font-weight: 500;
    font-size: 0.9rem;
    margin-bottom: 14px;
    line-height: 1.2rem;
}

.footer-links {
    display: flex;
    gap: 24px;
    justify-content: center;
    flex-wrap: wrap;
}

.footer-links a {
    color: #b2bcd3;
    text-decoration: none;
}

.footer-links a:hover {
    color: white;
}
