/* ============================================================
   school-accreditations.css — CORPS de la page « Accréditations, labels
   et affiliations des écoles d'anglais à Malte ».
   Le HERO vient de ling-article.css (.ling-article-hero--split), chargé juste
   avant : on ne définit ici que le reste. Tout est préfixé .acc-.

   Code couleur des 5 niveaux (du plus fiable au moins pertinent) :
     essentiel  vert    — contrôle réel de l'enseignement
     examen     bleu    — contrôle réel mais limité aux examens
     selectif   indigo  — sélection adossée à d'autres accréditations
     utile      ambre   — aucun contrôle pédagogique
     commercial gris    — simple adhésion à un réseau
   ============================================================ */

.acc {
    --acc-max: 1000px;
    --acc-ink: #0f172a;
    --acc-muted: #64748b;
    --acc-line: #e6e8ee;
    --acc-soft: #f6f8fc;

    --lv-essentiel: #15803d;   --lv-essentiel-bg: #eaf7ef;
    --lv-examen: #1d4ed8;      --lv-examen-bg: #e8f1ff;
    --lv-selectif: #6d28d9;    --lv-selectif-bg: #f1ebfd;
    --lv-utile: #b45309;       --lv-utile-bg: #fff5e6;
    --lv-commercial: #64748b;  --lv-commercial-bg: #f1f5f9;
}

/* ---- Légende des niveaux ---- */
.acc-legend {
    max-width: var(--acc-max);
    margin: 3.5rem auto 0;
    padding: 1.5rem;
    background: var(--acc-soft);
    border: 1px solid var(--acc-line);
    border-radius: 16px;
    width: calc(100% - 2 * var(--padding-x, 1.25rem));
}
.acc-legend-title {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.6rem;
    margin: 0 0 1rem;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--acc-muted);
}
.acc-legend-count {
    letter-spacing: 0;
    text-transform: none;
    font-weight: 400;
    color: var(--acc-muted);
}
.acc-legend-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.5rem;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}
.acc-lv {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 0.7rem 0.85rem;
    background: #fff;
    border: 1px solid var(--acc-line);
    border-radius: 12px;
    text-decoration: none;
    height: 100%;
    transition: border-color 0.15s, transform 0.15s;
}
.acc-lv:hover { border-color: currentColor; transform: translateY(-1px); }
.acc-lv-dot {
    flex: 0 0 auto;
    width: 10px; height: 10px;
    margin-top: 5px;
    border-radius: 50%;
    background: currentColor;
}
.acc-lv-txt { display: flex; flex-direction: column; gap: 2px; }
.acc-lv-txt strong { font-size: 0.9rem; line-height: 1.25; }
.acc-lv-txt span { font-size: 0.78rem; line-height: 1.35; color: var(--acc-muted); }
.acc-lv--essentiel  { color: var(--lv-essentiel); }
.acc-lv--examen     { color: var(--lv-examen); }
.acc-lv--selectif   { color: var(--lv-selectif); }
.acc-lv--utile      { color: var(--lv-utile); }
.acc-lv--commercial { color: var(--lv-commercial); }

/* ---- Groupe (un niveau) ---- */
.acc-group {
    max-width: var(--acc-max);
    margin: 4rem auto 0;
    padding: 0 var(--padding-x, 1.25rem);
    scroll-margin-top: 90px;
}
.acc-group-head { margin-bottom: 1.75rem; }
.acc-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 0.9rem;
}
.acc-badge--essentiel  { background: var(--lv-essentiel-bg);  color: var(--lv-essentiel); }
.acc-badge--examen     { background: var(--lv-examen-bg);     color: var(--lv-examen); }
.acc-badge--selectif   { background: var(--lv-selectif-bg);   color: var(--lv-selectif); }
.acc-badge--utile      { background: var(--lv-utile-bg);      color: var(--lv-utile); }
.acc-badge--commercial { background: var(--lv-commercial-bg); color: var(--lv-commercial); }
.acc-group-head h2 {
    font-size: clamp(1.35rem, 1.1rem + 1vw, 1.7rem);
    line-height: 1.3;
    margin: 0 0 0.9rem;
    padding-left: 0.9rem;
    border-left: 4px solid currentColor;
    color: var(--color-dark, #1f2937);
}
.acc-group--essentiel  .acc-group-head h2 { border-left-color: var(--lv-essentiel); }
.acc-group--examen     .acc-group-head h2 { border-left-color: var(--lv-examen); }
.acc-group--selectif   .acc-group-head h2 { border-left-color: var(--lv-selectif); }
.acc-group--utile      .acc-group-head h2 { border-left-color: var(--lv-utile); }
.acc-group--commercial .acc-group-head h2 { border-left-color: var(--lv-commercial); }
.acc-group-intro { font-size: 1.02rem; line-height: 1.75; color: #334155; margin: 0; }

/* ---- Fiche label ---- */
.acc-cards { display: flex; flex-direction: column; gap: 1rem; }
.acc-card {
    display: grid;
    grid-template-columns: 170px minmax(0, 1fr);
    gap: 1.5rem;
    align-items: start;
    padding: 1.4rem 1.5rem;
    background: #fff;
    border: 1px solid var(--acc-line);
    border-radius: 16px;
    scroll-margin-top: 90px;
}
.acc-card-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 84px;
    padding: 0.5rem 0.75rem;
    background: var(--acc-soft);
    border-radius: 12px;
}
.acc-card-logo img {
    display: block;
    max-width: 100%;
    max-height: 66px;
    width: auto;
    height: auto;
    object-fit: contain;
}
/* Pastille texte quand aucun logo n'est disponible */
.acc-card-logo--text span {
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--acc-muted);
    text-align: center;
}

.acc-card-body > * + * { margin-top: 0.75rem; }
.acc-card h3 {
    font-size: 1.14rem;
    line-height: 1.3;
    margin: 0;
    color: var(--acc-ink);
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.acc-card-full {
    font-size: 0.82rem;
    font-weight: 400;
    color: var(--acc-muted);
}
.acc-card-text { font-size: 0.97rem; line-height: 1.7; color: #334155; margin: 0; }

/* Encart « Notre avis » : voix éditoriale du site */
.acc-card-avis {
    position: relative;
    padding: 0.9rem 1rem 0.9rem 1.1rem;
    border-radius: 12px;
    border-left: 3px solid currentColor;
    font-size: 0.95rem;
    line-height: 1.65;
}
.acc-card-avis::before {
    content: attr(data-label);
    display: block;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 0.3rem;
}
.acc-group--essentiel  .acc-card-avis { background: var(--lv-essentiel-bg);  color: var(--lv-essentiel); }
.acc-group--examen     .acc-card-avis { background: var(--lv-examen-bg);     color: var(--lv-examen); }
.acc-group--selectif   .acc-card-avis { background: var(--lv-selectif-bg);   color: var(--lv-selectif); }
.acc-group--utile      .acc-card-avis { background: var(--lv-utile-bg);      color: var(--lv-utile); }
.acc-group--commercial .acc-card-avis { background: var(--lv-commercial-bg); color: var(--lv-commercial); }
/* le texte de l'avis reste lisible : la couleur du niveau ne sert qu'au liseré/titre */
.acc-card-avis { color: #334155; }
.acc-group--essentiel  .acc-card-avis { border-left-color: var(--lv-essentiel); }
.acc-group--examen     .acc-card-avis { border-left-color: var(--lv-examen); }
.acc-group--selectif   .acc-card-avis { border-left-color: var(--lv-selectif); }
.acc-group--utile      .acc-card-avis { border-left-color: var(--lv-utile); }
.acc-group--commercial .acc-card-avis { border-left-color: var(--lv-commercial); }
.acc-group--essentiel  .acc-card-avis::before { color: var(--lv-essentiel); }
.acc-group--examen     .acc-card-avis::before { color: var(--lv-examen); }
.acc-group--selectif   .acc-card-avis::before { color: var(--lv-selectif); }
.acc-group--utile      .acc-card-avis::before { color: var(--lv-utile); }
.acc-group--commercial .acc-card-avis::before { color: var(--lv-commercial); }

.acc-card-link { margin: 0; }
.acc-card-link a {
    font-size: 0.9rem;
    color: var(--color-primary, #3b82f6);
    text-decoration: underline;
    text-underline-offset: 3px;
}
.acc-card-link a:hover { color: var(--color-primary-dark, #2563eb); }

/* ---- Conclusion : la marche a suivre ---- */
.acc-outro {
    max-width: var(--acc-max);
    margin: 4.5rem auto 5rem;
    padding: 1.9rem 1.75rem;
    background: var(--acc-soft);
    border: 1px solid var(--acc-line);
    border-radius: 16px;
    width: calc(100% - 2 * var(--padding-x, 1.25rem));
    scroll-margin-top: 90px;
}
.acc-outro h2 {
    font-size: clamp(1.3rem, 1.05rem + 1vw, 1.6rem);
    line-height: 1.3;
    margin: 0 0 1.4rem;
    color: var(--color-dark, #1f2937);
}
.acc-steps {
    list-style: none;
    counter-reset: acc-step;
    margin: 0 0 1.4rem;
    padding: 0;
    display: grid;
    gap: 0.7rem;
}
.acc-steps li {
    counter-increment: acc-step;
    position: relative;
    padding: 0.85rem 1rem 0.85rem 3.1rem;
    background: #fff;
    border: 1px solid var(--acc-line);
    border-radius: 12px;
    font-size: 0.98rem;
    line-height: 1.6;
    color: #334155;
}
.acc-steps li::before {
    content: counter(acc-step);
    position: absolute;
    left: 1rem;
    top: 0.85rem;
    width: 1.55rem;
    height: 1.55rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--lv-essentiel-bg);
    color: var(--lv-essentiel);
    font-size: 0.8rem;
    font-weight: 700;
}
/* le 3e point est un bonus, pas un prerequis : couleur du niveau « examen » */
.acc-steps li:last-child::before { background: var(--lv-examen-bg); color: var(--lv-examen); }
.acc-steps strong { color: var(--acc-ink); }
.acc-outro-note {
    margin: 0;
    padding-left: 1.1rem;
    border-left: 3px solid var(--lv-utile);
    font-size: 0.97rem;
    line-height: 1.7;
    color: #334155;
}

/* Dernier groupe : marge de fin de page */
.acc-group:last-of-type { margin-bottom: 0; }

/* ---- Mobile ---- */
@media (max-width: 700px) {
    .acc-card { grid-template-columns: 1fr; gap: 1rem; padding: 1.2rem; }
    .acc-card-logo { min-height: 0; padding: 0.9rem; }
    .acc-card-logo img { max-height: 54px; }
    .acc-legend { padding: 1.2rem; }
    .acc-outro { padding: 1.4rem 1.2rem; }
    .acc-steps li { padding: 0.8rem 0.9rem 0.8rem 2.9rem; }
}
