/* ===========================================================================
   ISFB Parcours — Feuille de styles
   Copyright (c) Mathias Baitan, 12 mai 2026. Version 1.00
   Palette ISFB : navy #1C355E, teal #44ACBC, gold #A28B69
   =========================================================================== */

:root {
    --isfb-primary: #1C355E;         /* DAS1 — Formation (navy)        */
    --isfb-primary-dark: #142948;
    --isfb-primary-light: #2a4976;
    --isfb-teal: #44ACBC;             /* DAS2 — Certification (teal)   */
    --isfb-gold: #A28B69;             /* DAS3 — Carrière (or/beige)    */
    --isfb-purple: #5A1F45;           /* DAS4 — Réseau (aubergine)     */

    --bg: #faf9f8;
    --bg-alt: #f5f4f2;
    --white: #ffffff;

    --text: #1C355E;
    --text-body: #3b4455;
    --text-muted: #6b7280;

    --border: #e5e2de;
    --danger: #c0392b;
    --danger-light: #fef2f2;
    --success: #16a34a;
    --success-light: #f0fdf4;
    --warn: #d97706;
    --warn-light: #fffbeb;
    --info: #2563eb;
    --info-light: #eff6ff;

    --shadow-sm: 0 1px 3px rgba(28, 53, 94, 0.07);
    --shadow-md: 0 4px 12px rgba(28, 53, 94, 0.08);

    --ff: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --radius: 8px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { height: 100%; }
body {
    font-family: var(--ff);
    font-size: 15px;
    color: var(--text-body);
    background: var(--bg);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--isfb-primary); text-decoration: none; transition: color .15s; }
a:hover { color: var(--isfb-gold); }

h1, h2, h3, h4 {
    color: var(--isfb-primary);
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.01em;
}
h1 { font-size: 1.65rem; margin-bottom: 0.7em; }
h2 { font-size: 1.25rem; margin: 0 0 0.5em; }
h3 { font-size: 1.05rem; margin: 0 0 0.4em; }

p { margin-bottom: 0.7em; }
img { max-width: 100%; height: auto; display: block; }

.muted { color: var(--text-muted); }
.text-center { text-align: center; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }

/* ===========================================================================
   HEADER (commun public + admin)
   =========================================================================== */
.isfb-header {
    background: var(--isfb-primary);
    color: var(--white);
}
.isfb-header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    gap: 24px;
}
.isfb-brand {
    color: var(--white);
    flex: 1;
    font-size: 1.1rem;
    font-weight: 700;
}
.isfb-brand:hover { color: var(--white); }
.isfb-brand-label small {
    display: block;
    font-weight: 400;
    font-size: 0.78rem;
    opacity: 0.8;
}
.isfb-public-nav { display: flex; gap: 18px; align-items: center; }
.isfb-public-nav a {
    color: var(--white);
    font-size: 0.9rem;
}
.isfb-public-nav a:hover { color: var(--isfb-gold); }

/* Bouton CTA dans le header (sur fond navy) */
.btn-cta-header {
    display: inline-block;
    padding: 9px 18px;
    background: var(--isfb-teal);
    color: var(--white) !important;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: background .15s, transform .15s;
}
.btn-cta-header:hover {
    background: #379ba9;
    color: var(--white) !important;
    transform: translateY(-1px);
}
.isfb-logo img { display: block; }

/* ===========================================================================
   NAV ADMIN
   =========================================================================== */
.admin-nav {
    background: var(--isfb-primary-dark);
    color: var(--white);
}
.admin-nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    gap: 4px;
}
.admin-nav-inner a {
    color: rgba(255,255,255,.85);
    padding: 12px 14px;
    font-size: 0.9rem;
    font-weight: 600;
}
.admin-nav-inner a:hover,
.admin-nav-inner a.active {
    color: var(--white);
    background: rgba(255,255,255,.08);
}
.admin-nav-spacer { flex: 1; }
.admin-nav-user {
    color: rgba(255,255,255,.85);
    padding: 0 12px;
    font-size: 0.85rem;
    text-align: right;
}
.admin-nav-user small {
    display: block;
    font-size: 0.72rem;
    opacity: 0.7;
}
.admin-nav-logout {
    background: rgba(255,255,255,.1);
    border-radius: 4px;
    padding: 6px 10px !important;
}

/* ===========================================================================
   MAIN
   =========================================================================== */
.isfb-main, .admin-main {
    flex: 1;
    padding: 24px 0;
}
.isfb-main-inner, .admin-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===========================================================================
   CARDS
   =========================================================================== */
.card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 24px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-sm);
}
.card h2 { margin-top: 0; }

/* ===========================================================================
   FORMULAIRES
   =========================================================================== */
label {
    display: block;
    margin-bottom: 16px;
    font-weight: 600;
    color: var(--isfb-primary);
    font-size: 0.92rem;
}
label.inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-right: 16px;
    font-weight: 500;
}
input[type=text], input[type=email], input[type=password], input[type=date],
input[type=datetime-local], input[type=number], input[type=search], input[type=url],
input[type=file], select, textarea {
    display: block;
    width: 100%;
    margin-top: 4px;
    padding: 9px 11px;
    font: inherit;
    color: var(--text-body);
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-weight: 400;
    transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--isfb-teal);
    box-shadow: 0 0 0 3px rgba(68, 172, 188, 0.15);
}
textarea { resize: vertical; min-height: 70px; }
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
@media (max-width: 600px) {
    .form-row { grid-template-columns: 1fr; }
}
.form-actions {
    margin-top: 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}
fieldset {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 12px 16px;
    margin-bottom: 16px;
}
fieldset legend {
    font-weight: 600;
    color: var(--isfb-primary);
    padding: 0 6px;
}

/* ===========================================================================
   BOUTONS
   =========================================================================== */
.btn {
    display: inline-block;
    padding: 9px 18px;
    background: var(--bg-alt);
    color: var(--isfb-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font: inherit;
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    text-decoration: none;
    transition: background .15s, border-color .15s;
}
.btn:hover { background: var(--border); color: var(--isfb-primary); }
.btn-primary {
    background: var(--isfb-primary);
    color: var(--white);
    border-color: var(--isfb-primary);
}
.btn-primary:hover { background: var(--isfb-primary-dark); color: var(--white); }
.btn-success { background: var(--success); color: var(--white); border-color: var(--success); }
.btn-success:hover { background: #14803c; color: var(--white); }
.btn-danger { background: var(--danger); color: var(--white); border-color: var(--danger); }
.btn-danger:hover { background: #952a20; color: var(--white); }
.btn-link {
    background: transparent;
    border-color: transparent;
    color: var(--text-muted);
    font-weight: 500;
}
.btn-link:hover { color: var(--isfb-primary); background: transparent; }
.btn-lg { padding: 12px 28px; font-size: 1rem; }
.btn-sm { padding: 5px 11px; font-size: 0.82rem; }

/* ===========================================================================
   FLASH MESSAGES
   =========================================================================== */
.flash {
    padding: 12px 16px;
    margin-bottom: 18px;
    border-radius: var(--radius);
    border-left: 4px solid;
    font-size: 0.93rem;
}
.flash-success { background: var(--success-light); border-color: var(--success); color: #166534; }
.flash-error   { background: var(--danger-light);  border-color: var(--danger);  color: #7f1d1d; }
.flash-info    { background: var(--info-light);    border-color: var(--info);    color: #1e3a8a; }
.flash-warn    { background: var(--warn-light);    border-color: var(--warn);    color: #78350f; }

/* ===========================================================================
   BADGES (statuts)
   =========================================================================== */
.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
}
.badge-green  { background: var(--success-light); color: #166534; }
.badge-orange { background: var(--warn-light);    color: #78350f; }
.badge-blue   { background: var(--info-light);    color: #1e3a8a; }
.badge-gray   { background: var(--bg-alt);        color: var(--text-muted); }
.badge-red    { background: var(--danger-light);  color: #7f1d1d; }

/* ===========================================================================
   TABLES (back-office)
   =========================================================================== */
.data-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}
.data-table th, .data-table td {
    padding: 11px 14px;
    text-align: left;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}
.data-table th {
    background: var(--bg-alt);
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--isfb-primary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: rgba(28, 53, 94, 0.02); }

.thumb {
    width: 48px; height: 48px;
    object-fit: cover;
    border-radius: 50%;
}
.thumb-lg {
    width: 200px; height: 200px;
    object-fit: cover;
    border-radius: var(--radius);
    margin-bottom: 12px;
}

/* ===========================================================================
   FILTER BAR
   =========================================================================== */
.filter-bar {
    display: flex;
    gap: 12px;
    align-items: end;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.filter-bar label { margin-bottom: 0; }

/* ===========================================================================
   KPI (dashboard)
   =========================================================================== */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 20px;
}
.kpi-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-left: 5px solid var(--text-muted);
    border-radius: var(--radius);
    padding: 18px 22px;
    box-shadow: var(--shadow-sm);
    color: var(--text-body);
    display: block;
    text-decoration: none;
}
.kpi-card:hover { box-shadow: var(--shadow-md); }
.kpi-value { font-size: 2rem; font-weight: 700; color: var(--isfb-primary); }
.kpi-label { font-size: 0.85rem; color: var(--text-muted); margin-top: 4px; }
.kpi-orange { border-left-color: var(--warn); }
.kpi-blue   { border-left-color: var(--info); }
.kpi-green  { border-left-color: var(--success); }
.kpi-gray   { border-left-color: var(--text-muted); }

.admin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    gap: 16px;
}
.admin-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ===========================================================================
   PAGE PUBLIQUE — LISTE DES PARCOURS
   =========================================================================== */
/* Pills de filtre par type (page liste publique) */
.filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 18px 0 6px;
}
.filter-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 14px;
    background: var(--white);
    color: var(--text-body);
    border: 1px solid var(--border);
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: background .15s, border-color .15s, color .15s;
}
.filter-pill:hover {
    border-color: var(--isfb-teal);
    color: var(--isfb-primary);
}
.filter-pill.active {
    background: var(--isfb-primary);
    border-color: var(--isfb-primary);
    color: var(--white);
}
/* Pill active colorée selon le DAS lorsqu'un type est sélectionné. */
.filter-pill.filter-pill-nomination.active      { background: var(--isfb-gold);    border-color: var(--isfb-gold); }
.filter-pill.filter-pill-employer_change.active { background: var(--isfb-purple);  border-color: var(--isfb-purple); }
.filter-pill.filter-pill-cert_isfb.active       { background: var(--isfb-primary); border-color: var(--isfb-primary); }
.filter-pill.filter-pill-cert_saq.active        { background: var(--isfb-teal);    border-color: var(--isfb-teal); }
.filter-count {
    display: inline-block;
    padding: 0 7px;
    border-radius: 999px;
    background: var(--bg-alt);
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 700;
    min-width: 22px;
    text-align: center;
}
.filter-pill.active .filter-count {
    background: rgba(255,255,255,.18);
    color: var(--white);
}

/* Mention de bas de page sur la liste des trajectoires */
.parcours-disclaimer {
    margin-top: 28px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    font-size: 0.82rem;
    color: var(--text-muted);
    font-style: italic;
    text-align: center;
}

/* Badge de type sur les cartes de la liste */
.parcours-type-badge {
    display: inline-block;
    padding: 2px 9px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 6px;
}
/* Couleurs alignées sur les DAS ISFB :
   - DAS1 Formation (cert ISFB)  : navy
   - DAS2 Certification (SAQ)    : teal
   - DAS3 Carrière (nomination)  : or / beige
   - DAS4 Réseau (chgt employeur): aubergine / violet
   - Changement de poste (générique) : bleu neutre */
.parcours-type-badge.type-job                { background: #eff6ff; color: #1e3a8a; }
.parcours-type-badge.type-nomination         { background: #f5efe6; color: #8a7558; }
.parcours-type-badge.type-employer-change    { background: #eae2e7; color: #5A1F45; }
.parcours-type-badge.type-cert-isfb          { background: #e7eaf0; color: #1C355E; }
.parcours-type-badge.type-cert-saq           { background: #edf5f6; color: #0e7a87; }

.parcours-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
}
.parcours-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: box-shadow .15s, transform .15s;
}
.parcours-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.parcours-card a {
    display: block;
    padding: 18px;
    color: var(--text-body);
}
.parcours-photo-wrap {
    position: relative;
    margin-bottom: 12px;
}
.parcours-photo {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: var(--radius);
    margin-bottom: 0;
    display: block;
}
/* Badge médaillon "Diplômé ISFB / SAQ" — overlay sur la photo, bas-gauche */
.parcours-photo-badge {
    position: absolute;
    left: -6px;
    bottom: -6px;
    width: 56px;
    height: 56px;
    background: #fff;
    border-radius: 50%;
    padding: 4px;
    box-shadow:
        0 2px 8px rgba(28, 53, 94, 0.25),
        0 0 0 2px #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    transition: transform .2s;
}
.parcours-photo-badge svg {
    width: 100%;
    height: 100%;
    display: block;
}
.parcours-card:hover .parcours-photo-badge {
    transform: scale(1.06) rotate(-3deg);
}
.parcours-card h2 {
    font-size: 1.05rem;
    margin-bottom: 6px;
}
.parcours-photo-lg {
    width: 160px;
    height: 160px;
    object-fit: cover;
    border-radius: var(--radius);
}

.parcours-detail {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow-sm);
}
.parcours-trajectory {
    display: flex;
    align-items: center;
    gap: 32px;
    margin: 24px 0;
    padding: 18px 24px;
    background: var(--bg-alt);
    border-radius: var(--radius);
    flex-wrap: wrap;
}
.parcours-trajectory .arrow {
    font-size: 1.5rem;
    color: var(--isfb-teal);
}
.parcours-head {
    display: flex;
    gap: 24px;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.parcours-head-meta { flex: 1; min-width: 280px; }

/* Badge "vérifié par ISFB" — sobre, vert léger */
.parcours-verified {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    background: #ecfdf5;
    color: #166534;
    border: 1px solid #a7f3d0;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    margin: 6px 0;
}
.parcours-verified-tick {
    display: inline-flex;
    width: 16px; height: 16px;
    align-items: center;
    justify-content: center;
    background: #16a34a;
    color: #fff;
    border-radius: 50%;
    font-size: 0.7rem;
    font-weight: 700;
}
.parcours-verified-note {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin: 4px 0 8px;
    font-style: italic;
}

/* Badge certificat — SVG + libellé */
.parcours-badge-cert {
    display: flex;
    gap: 18px;
    align-items: center;
    padding: 18px 22px;
    margin: 20px 0;
    background: var(--bg-alt);
    border-left: 4px solid var(--isfb-gold);
    border-radius: var(--radius);
    flex-wrap: wrap;
}
.parcours-badge-cert-visual { flex-shrink: 0; }
.parcours-badge-cert-visual svg {
    width: 90px;
    height: 90px;
    filter: drop-shadow(0 2px 6px rgba(28,53,94,0.15));
}

/* Métadonnées sous forme de paire dt/dd */
.parcours-meta {
    display: grid;
    grid-template-columns: minmax(160px, max-content) 1fr;
    gap: 6px 18px;
    margin: 18px 0;
    padding: 14px 16px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}
.parcours-meta dt {
    font-weight: 600;
    color: var(--isfb-primary);
    font-size: 0.88rem;
}
.parcours-meta dd { margin: 0; color: var(--text-body); }

.parcours-share {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

.parcours-presentation {
    font-size: 1.05rem;
    line-height: 1.7;
    border-left: 3px solid var(--isfb-teal);
    padding-left: 16px;
    margin-top: 16px;
    color: var(--text-body);
}
.parcours-article {
    margin-top: 18px;
    padding: 12px 16px;
    background: var(--bg-alt);
    border-radius: var(--radius);
    font-weight: 600;
}
.parcours-article-badge {
    display: inline-block;
    margin-left: 8px;
    padding: 2px 8px;
    border-radius: 999px;
    background: var(--isfb-teal);
    color: var(--white);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* ===========================================================================
   PAGE DE CONNEXION (login, forgot, reset, 2FA)
   =========================================================================== */
.login-page {
    background: linear-gradient(135deg, var(--bg) 0%, var(--bg-alt) 100%);
    align-items: center;
    justify-content: center;
}
.login-box {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 36px 32px;
    box-shadow: var(--shadow-md);
    width: 100%;
    max-width: 420px;
    margin: 60px auto;
}
.login-logo { text-align: center; margin-bottom: 16px; }
.login-subtitle {
    text-align: center;
    color: var(--text-muted);
    margin-bottom: 24px;
}
.login-box h1 { text-align: center; margin-bottom: 8px; }
.login-box .btn { width: 100%; }
.login-links {
    text-align: center;
    margin-top: 18px;
    font-size: 0.9rem;
}

/* ===========================================================================
   PAGINATION
   =========================================================================== */
.pagination {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 20px;
}
.pagination a {
    padding: 6px 11px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-body);
    font-size: 0.88rem;
}
.pagination a.active {
    background: var(--isfb-primary);
    border-color: var(--isfb-primary);
    color: var(--white);
}

/* ===========================================================================
   FOOTER
   =========================================================================== */
.isfb-footer, .admin-footer {
    background: var(--white);
    border-top: 1px solid var(--border);
    padding: 16px;
    text-align: center;
    font-size: 0.82rem;
    color: var(--text-muted);
}

/* ===========================================================================
   STATS / OBSERVATOIRE
   =========================================================================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 16px;
    margin-top: 18px;
}
.stats-bars { display: flex; flex-direction: column; gap: 6px; }
.stats-row {
    display: grid;
    grid-template-columns: minmax(120px, 200px) 1fr 50px;
    gap: 10px;
    align-items: center;
    font-size: 0.88rem;
}
.stats-label { color: var(--text-body); }
.stats-count { text-align: right; font-weight: 600; color: var(--isfb-primary); }
.stats-bar-wrap {
    background: var(--bg-alt);
    border-radius: 999px;
    height: 14px;
    overflow: hidden;
}
.stats-bar {
    background: linear-gradient(90deg, var(--isfb-teal), var(--isfb-primary));
    height: 100%;
    border-radius: 999px;
    transition: width .25s;
    min-width: 2px;
}

/* ===========================================================================
   RADIO EN BLOC (formulaire de soumission Trajectoires)
   =========================================================================== */
.block-radio {
    display: block;
    padding: 12px 14px;
    margin-bottom: 8px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--white);
    cursor: pointer;
    transition: border-color .15s, background .15s;
    font-weight: 400;
}
.block-radio:hover { border-color: var(--isfb-teal); }
.block-radio:has(input:checked) {
    border-color: var(--isfb-teal);
    background: var(--bg-alt);
}
.block-radio input[type="radio"] { margin-right: 8px; vertical-align: middle; }

/* ===========================================================================
   CONFIGURATEUR D'EMBED (admin/settings.php)
   =========================================================================== */
.isfb-cfg-step {
    display: flex;
    gap: 16px;
    margin: 18px 0 24px;
    padding: 16px 18px;
    background: var(--bg-alt);
    border-left: 4px solid var(--isfb-teal);
    border-radius: var(--radius);
}
.isfb-cfg-step-num {
    flex-shrink: 0;
    width: 32px; height: 32px;
    border-radius: 50%;
    background: var(--isfb-primary);
    color: var(--white);
    font-weight: 700;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.isfb-cfg-step-body { flex: 1; min-width: 0; }
.isfb-cfg-step-body h3 { margin-bottom: 8px; }

.isfb-cfg-snippet-wrap {
    position: relative;
    background: var(--isfb-primary-dark);
    border-radius: var(--radius);
    padding: 0;
    margin: 8px 0;
    overflow: hidden;
}
.isfb-cfg-snippet-wrap pre {
    margin: 0;
    padding: 14px 100px 14px 16px;
    color: #f5efe6;
    font-family: 'SF Mono', Menlo, Consolas, monospace;
    font-size: 0.88rem;
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-all;
}
.isfb-cfg-snippet-wrap pre code {
    background: transparent;
    color: inherit;
    padding: 0;
}
.isfb-cfg-snippet-wrap .isfb-cfg-copy {
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--isfb-teal);
    color: var(--white);
    border-color: var(--isfb-teal);
}
.isfb-cfg-snippet-wrap .isfb-cfg-copy:hover { background: #379ba9; color: var(--white); }
.isfb-cfg-snippet-wrap .isfb-cfg-copy:disabled {
    background: var(--success);
    border-color: var(--success);
    cursor: default;
}

.isfb-cfg-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin: 12px 0;
    padding: 14px 16px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}
.isfb-cfg-form .isfb-cfg-field { margin-bottom: 0; }
.isfb-cfg-form fieldset { padding: 8px 12px; }
.isfb-cfg-form fieldset .inline {
    display: flex;
    margin-bottom: 4px;
    font-weight: 400;
}

.isfb-cfg-preview-frame {
    margin-top: 8px;
    padding: 16px;
    background: var(--white);
    border: 1px dashed var(--border);
    border-radius: var(--radius);
    min-height: 80px;
}

/* ===========================================================================
   CODE / DIVERS
   =========================================================================== */
code {
    background: var(--bg-alt);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
    font-family: 'SF Mono', Menlo, Consolas, monospace;
}
hr {
    border: none;
    border-top: 1px solid var(--border);
}
