/* ════════════════════════════════════════════════════════════
   Hotline 2CLOUD — formulaire public de declaration d'incidents
   Style cale sur le portail (couleurs orange/blanc).
   ════════════════════════════════════════════════════════════ */

:root {
    --primary:        #df8611;
    --primary-dark:   #c4740c;
    --primary-light:  #ec9a2e;
    --gray-50:        #F9FAFB;
    --gray-100:       #F3F4F6;
    --gray-200:       #E5E7EB;
    --gray-300:       #D1D5DB;
    --gray-400:       #9CA3AF;
    --gray-500:       #6B7280;
    --gray-600:       #4B5563;
    --gray-700:       #374151;
    --gray-800:       #1F2937;
    --gray-900:       #111827;
    --red-500:        #EF4444;
    --red-50:         #FEF2F2;
    --green-50:       #F0FDF4;
    --green-600:      #16A34A;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: #F3F4F6;
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, Helvetica, Arial, sans-serif;
    color: var(--gray-800);
    font-size: 14px;
    line-height: 1.5;
    min-height: 100vh;
}

/* ─── Bandeau orange du haut ─── */
.hl-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: #fff;
    text-align: center;
    padding: 30px 20px 40px;
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    position: relative;
}
.hl-header-logo {
    background: #fff;
    width: 96px;
    height: 96px;
    border-radius: 50%;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(0,0,0,.2);
    padding: 8px;
    box-sizing: border-box;
}
.hl-header-logo img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}
.hl-header h1 {
    margin: 0 0 6px;
    font-size: 26px;
    font-weight: 800;
    letter-spacing: .3px;
}
.hl-header .hl-subtitle {
    font-size: 13px;
    opacity: .9;
    font-weight: 400;
}

/* ─── Carte principale (contenu sous le bandeau) ─── */
.hl-container {
    max-width: 800px;
    margin: -20px auto 40px;
    padding: 0 16px;
}
.hl-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(0,0,0,.06);
    padding: 30px 36px 36px;
}
@media (max-width: 600px) {
    .hl-card { padding: 22px 18px; }
}

.hl-intro h2 {
    margin: 0 0 4px;
    font-size: 18px;
    color: var(--gray-800);
    font-weight: 700;
    border-bottom: 3px solid var(--primary);
    display: inline-block;
    padding-bottom: 2px;
}
.hl-intro p {
    margin: 12px 0 6px;
    color: var(--gray-700);
    font-size: 14px;
}
.hl-intro .hl-link-suivi {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px solid var(--primary);
}
.hl-intro .hl-link-suivi:hover {
    background: #FFF7ED;
}

/* ─── Champs du formulaire ─── */
.hl-form {
    margin-top: 24px;
}
.hl-form-row {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    margin-bottom: 14px;
}
.hl-form-row .hl-label {
    flex: 0 0 160px;
    text-align: right;
    padding-top: 8px;
    font-size: 13px;
    color: var(--gray-700);
    font-weight: 600;
}
.hl-form-row .hl-required {
    color: var(--red-500);
    margin-left: 2px;
}
.hl-form-row .hl-field {
    flex: 1;
    min-width: 0;
}
.hl-form-row .hl-field-group {
    display: flex;
    gap: 8px;
}

@media (max-width: 600px) {
    .hl-form-row { flex-direction: column; gap: 4px; }
    .hl-form-row .hl-label { text-align: left; flex: none; padding-top: 0; }
}

.hl-form input[type=text],
.hl-form input[type=email],
.hl-form input[type=tel],
.hl-form textarea,
.hl-form select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--gray-300);
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    color: var(--gray-800);
    background: #fff;
    transition: border-color .15s, box-shadow .15s;
}
.hl-form input::placeholder,
.hl-form textarea::placeholder {
    color: var(--gray-400);
    font-style: italic;
}
.hl-form input:focus,
.hl-form textarea:focus,
.hl-form select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(223,134,17,.15);
}
.hl-form textarea {
    resize: vertical;
    min-height: 100px;
    font-family: inherit;
}
.hl-form select {
    cursor: pointer;
}

/* Civilite (court) + prenom + nom */
.hl-civility { flex: 0 0 70px; }
.hl-firstname { flex: 1; }
.hl-lastname { flex: 1; }

/* Checkbox contrat */
.hl-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-top: 8px;
    font-size: 14px;
    color: var(--gray-700);
    cursor: pointer;
}
.hl-checkbox input[type=checkbox] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary);
    cursor: pointer;
}

/* Message d'auto-detection societe/contrat */
.hl-lookup-hint {
    font-size: 12.5px;
    margin-top: 6px;
    min-height: 18px;
    line-height: 1.4;
    transition: color .15s;
}
.hl-lookup-hint-loading { color: var(--gray-500); font-style: italic; }
.hl-lookup-hint-success { color: var(--green-600); font-weight: 600; }
.hl-lookup-hint-info    { color: var(--gray-600); font-weight: 500; }

/* Champ societe verrouille apres detection automatique */
.hl-form input.hl-locked {
    background: #F3F4F6;
    color: var(--gray-700);
    font-weight: 600;
    cursor: not-allowed;
    border-color: var(--gray-300);
    padding-right: 34px;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%236B7280'><path d='M12 2a5 5 0 0 0-5 5v3H6a2 2 0 0 0-2 2v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8a2 2 0 0 0-2-2h-1V7a5 5 0 0 0-5-5zm-3 8V7a3 3 0 1 1 6 0v3H9z'/></svg>");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 14px 14px;
}
.hl-form input.hl-locked:focus {
    border-color: var(--gray-300);
    box-shadow: none;
}

/* Upload fichiers */
.hl-file-input {
    display: flex;
    gap: 8px;
    align-items: center;
}
.hl-file-input input[type=file] {
    display: none;
}
.hl-file-btn {
    background: var(--gray-100);
    color: var(--gray-700);
    border: 1px solid var(--gray-300);
    padding: 7px 14px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: background .15s;
}
.hl-file-btn:hover { background: var(--gray-200); }
.hl-file-list {
    color: var(--gray-500);
    font-size: 12px;
    font-style: italic;
}

/* ─── Bouton submit ─── */
.hl-submit-wrap {
    text-align: center;
    margin-top: 28px;
}
.hl-btn-submit {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    border: none;
    padding: 12px 36px;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: .3px;
    cursor: pointer;
    box-shadow: 0 3px 12px rgba(223,134,17,.3);
    transition: transform .12s, box-shadow .12s;
}
.hl-btn-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 5px 16px rgba(223,134,17,.4);
}
.hl-btn-submit:active {
    transform: translateY(0);
}

/* ─── Messages d'erreur / succes ─── */
.hl-alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 18px;
    font-size: 14px;
}
.hl-alert-error {
    background: var(--red-50);
    color: #B91C1C;
    border-left: 4px solid var(--red-500);
}
.hl-alert-success {
    background: var(--green-50);
    color: #15803D;
    border-left: 4px solid var(--green-600);
}
.hl-alert ul {
    margin: 6px 0 0 18px;
    padding: 0;
}

/* ─── Page de confirmation ─── */
.hl-confirm-icon {
    text-align: center;
    margin-bottom: 16px;
}
.hl-confirm-icon-circle {
    display: inline-block;
    background: var(--green-50);
    width: 80px;
    height: 80px;
    border-radius: 50%;
    line-height: 80px;
    font-size: 38px;
    color: var(--green-600);
}
.hl-confirm-number {
    text-align: center;
    background: var(--gray-50);
    border: 1px dashed var(--gray-300);
    border-radius: 10px;
    padding: 20px;
    margin: 18px 0 24px;
}
.hl-confirm-number-label {
    font-size: 11px;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}
.hl-confirm-number-value {
    font-size: 28px;
    font-weight: 800;
    color: var(--primary);
    letter-spacing: 2px;
    font-family: 'Consolas', 'Courier New', monospace;
}
.hl-confirm-info {
    font-size: 13px;
    color: var(--gray-600);
    line-height: 1.7;
    text-align: center;
    margin-bottom: 18px;
}
.hl-confirm-actions {
    text-align: center;
    margin-top: 24px;
}
.hl-btn-secondary {
    background: #fff;
    color: var(--primary);
    border: 1px solid var(--primary);
    padding: 9px 22px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    transition: background .12s;
}
.hl-btn-secondary:hover {
    background: #FFF7ED;
}

/* ─── Footer leger ─── */
.hl-footer {
    text-align: center;
    color: var(--gray-500);
    font-size: 12px;
    padding: 12px 0 30px;
}

/* ─── Encart "Preparez votre ID TeamViewer" sur la page de confirmation ─── */
.hl-tv-notice {
    background: linear-gradient(135deg, #EFF6FF 0%, #DBEAFE 100%);
    border: 1px solid #93C5FD;
    border-radius: 10px;
    padding: 16px 18px;
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 22px 0 6px;
}
.hl-tv-notice-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.hl-tv-notice-text {
    font-size: 13.5px;
    color: #1E40AF;
    line-height: 1.55;
}
.hl-tv-notice-text b {
    color: #1E3A8A;
    font-weight: 700;
}
.hl-tv-notice-link {
    display: inline-block;
    margin-top: 4px;
    color: #0E8EE9;
    font-weight: 700;
    text-decoration: none;
    padding: 3px 10px;
    background: #fff;
    border-radius: 6px;
    border: 1px solid #93C5FD;
    transition: all .12s;
}
.hl-tv-notice-link:hover {
    background: #0E8EE9;
    color: #fff;
    border-color: #0E8EE9;
}
