/* =====================================================
   BCVS — FORMULAIRE DE CRÉDIT
   Style bancaire premium, simple et responsive
   ===================================================== */

/* =========================
   BASE & TYPOGRAPHIE
   ========================= */

* {  
    box-sizing: border-box;
}

body {
    font-family: "Inter", "Segoe UI", Roboto, Arial, sans-serif;
    background-color: #f5f6f8;
    color: #111;
    margin: 0;
    padding: 0;
}

/* =========================
   CONTAINER FORMULAIRE
   ========================= */

form.container {
    width: 100%;
    max-width: 1200px;        /* lecture confortable desktop */
    margin: 0 auto;
    padding: 36px 32px;
    background-color: #ffffff;
}

/* Mobile */
@media (max-width: 768px) {
    form.container {
        max-width: 100%;
        padding: 22px 16px;
    }
}

/* =========================
   TITRE PRINCIPAL
   ========================= */

.form-title-banner {
    margin-bottom: 32px;
}

.form-title {
    font-size: 26px;
    font-weight: 700;
    text-align: center;
    margin: 0;
    color: #000;
}

/* =========================
   SECTIONS
   ========================= */

form h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 36px 0 18px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e6e8eb; /* séparation élégante */
    color: #000;
}

/* =========================
   GRILLE
   ========================= */

.row {
    display: flex;
    flex-wrap: wrap;
    margin-left: -10px;
    margin-right: -10px;
}

.col-md-6,
.col-md-12 {
    padding-left: 10px;
    padding-right: 10px;
    width: 100%;
}

@media (min-width: 768px) {
    .col-md-6 {
        width: 50%;
    }
}

/* =========================
   LABELS
   ========================= */

form label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #222;
}

/* =========================
   INPUTS & SELECTS
   ========================= */

form .form-control {
    width: 100%;
    height: 46px;
    padding: 10px 14px;
    font-size: 14px;
    color: #111;
    background-color: #fff;
    border: 1px solid #cfd3d8;
    border-radius: 6px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

/* Placeholder */
form .form-control::placeholder {
    color: #b6bcc3;     /* plus clair */
    font-size: 12px;    /* plus petit */
    opacity: 0.7;       /* plus discret */
}
form .form-control:focus::placeholder {
    opacity: 0.3;
}


/* Hover */
form .form-control:hover {
    border-color: #aeb3b9;
}

/* Focus (mobile & desktop) */
form .form-control:focus {
    border-color: #000;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0,0,0,0.12);
}

/* Readonly */
form .form-control[readonly] {
    background-color: #f2f3f5;
    color: #666;
}

/* =========================
   SELECT
   ========================= */

select.form-control {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image:
        linear-gradient(45deg, transparent 50%, #555 50%),
        linear-gradient(135deg, #555 50%, transparent 50%);
    background-position:
        calc(100% - 18px) 19px,
        calc(100% - 13px) 19px;
    background-size: 5px 5px, 5px 5px;
    background-repeat: no-repeat;
}

/* =========================
   ESPACEMENTS
   ========================= */

.mb-3 {
    margin-bottom: 20px;
}

/* =========================
   CHAMPS DYNAMIQUES
   ========================= */

#autreMontantContainer,
#autreDureeContainer,
#tauxContainer {
    display: none;
}

/* =========================
   BOUTON
   ========================= */

form .btn-primary {
    display: inline-block;
    padding: 14px 32px;
    margin-top: 28px;
    font-size: 15px;
    font-weight: 600;
    color: #ffffff;
    background-color: #000;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.15s ease;
}

form .btn-primary:hover {
    background-color: #333;
}

form .btn-primary:active {
    transform: translateY(1px);
}

/* Mobile button full width */
@media (max-width: 768px) {
    form .btn-primary {
        width: 100%;
    }
}

/* =========================
   TEXTE LÉGAL / INFO
   ========================= */

.form-info {
    margin-top: 40px;
    padding: 16px;
    font-size: 13px;
    line-height: 1.6;
    color: #444;
    background-color: #f7f8fa;
    border: 1px solid #e1e4e8;
    border-radius: 6px;
}
/* =========================
   BOUTON — FULL WIDTH PC
   ========================= */

form .btn-primary {
    display: block;      /* occupe la ligne */
    width: 100%;         /* pleine largeur */
    max-width: 100%;     /* sécurité */
    margin: 32px auto 0; /* centré */
    text-align: center;
}

/* Option : léger renfort visuel desktop */
@media (min-width: 768px) {
    form .btn-primary {
        height: 52px;
        font-size: 16px;
    }
}

.form-note {
  text-align: center;
  font-size: 13px;
  color: #555;
  margin-top: 8px;
}
.section-note {
  font-size: 13px;
  color: #666;
  margin: 6px 0 18px;
}
.form-reassurance {
  text-align: center;
  font-size: 12px;
  color: #777;
  margin-top: 10px;
}
.field-hint {
  display: block;
  font-size: 12px;
  color: #777;
  margin-top: 4px;
}
.form-security {
    text-align: center;
    font-size: 12px;
    color: #666;
    margin-top: 6px;
}

/* Option par défaut (placeholder-like) */
select.form-control option[value=""] {
    color: #b6bcc3;
}


/* Select – lisibilité & cohérence avec inputs */
select.form-control {
    height: 46px;              /* même hauteur que inputs */
    padding: 10px 14px;
    line-height: 1.4;
    color: #111;
}

/* Option sélectionnée (meilleur contraste) */
select.form-control option:checked {
    background-color: #f2f3f5;
    color: #000;
}

/* Select non encore choisi : texte discret */
select.form-control:has(option[value=""]:checked) {
    color: #9aa0a6;
}
/* Fallback si :has() non supporté */
select.form-control {
    color: #9aa0a6;
}
select.form-control:not([value=""]) {
    color: #111;
}

@media (max-width: 768px) {
    html, body {
        overflow-x: hidden;
    }

    .row {
        margin-left: 0;
        margin-right: 0;
    }
}
@media (max-width: 768px) {
    .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
}


@media (max-width: 768px) {
    form .form-control,
    form select {
        font-size: 16px !important;
    }
}

/* ============================================================
   Finantsieli — Credit form refresh (teal)  [added]
   ============================================================ */
:root{ --fin-teal:#128982; --fin-dark:#0C1E1B; --fin-accent:#FFA84B; }

/* Honeypot field — visually hidden but present for bots */
.fin-hp{ position:absolute!important; left:-9999px!important; width:1px; height:1px; overflow:hidden; }

/* Error alert */
.fin-form-alert{
  background:#fff4f3; border:1px solid #f3c5c0; color:#9b2c22;
  padding:12px 16px; border-radius:10px; margin:0 0 18px; font-size:14px;
}

/* Inputs / selects focus in brand teal */
form#finCreditForm .form-control:focus{
  border-color:var(--fin-teal);
  box-shadow:0 0 0 3px rgba(18,137,130,.15);
  outline:none;
}
form#finCreditForm label{ font-weight:600; color:var(--fin-dark); margin-bottom:6px; }
form#finCreditForm .field-hint{ display:block; margin-top:5px; font-size:12px; color:#6a7a77; }

/* Submit button teal */
form#finCreditForm .btn-primary{
  background:var(--fin-teal); border:none; color:#fff;
  padding:13px 26px; border-radius:10px; font-weight:700; letter-spacing:.2px;
  box-shadow:0 6px 18px rgba(18,137,130,.25); transition:transform .15s ease, box-shadow .2s ease, background .2s ease;
}
form#finCreditForm .btn-primary:hover{ background:#0f736d; transform:translateY(-1px); box-shadow:0 8px 22px rgba(18,137,130,.32); }
form#finCreditForm .btn-primary:disabled{ opacity:.7; transform:none; }

/* File upload dropzone */
.fin-file-input{ position:absolute; width:1px; height:1px; opacity:0; overflow:hidden; }
.fin-file-label{
  display:flex; align-items:center; gap:12px; cursor:pointer;
  padding:18px 20px; border:2px dashed rgba(18,137,130,.45); border-radius:12px;
  background:rgba(18,137,130,.04); color:var(--fin-dark); font-weight:600;
  transition:border-color .2s ease, background .2s ease;
}
.fin-file-label:hover{ border-color:var(--fin-teal); background:rgba(18,137,130,.08); }
.fin-file-label.has-file{ border-style:solid; border-color:var(--fin-teal); background:rgba(18,137,130,.10); }
.fin-file-name{ margin-top:8px; font-size:13px; font-weight:600; color:var(--fin-teal); }

/* Section headings accent */
form#finCreditForm h3{ position:relative; padding-left:14px; color:var(--fin-dark); }
form#finCreditForm h3::before{
  content:""; position:absolute; left:0; top:3px; bottom:3px; width:4px;
  background:var(--fin-teal); border-radius:3px;
}
.form-title-banner .form-title{ color:var(--fin-dark); }
