/* ============================================================
   LM Auto Moto École (astra-child) — Article pages
   ============================================================ */

/* ── Pleine largeur (neutralise le conteneur boxed Astra) ──── */
body.single #content .ast-container,
body.single .site-content > .ast-container {
    max-width: 100%;
    padding-left: 0;
    padding-right: 0;
}
body.single #content,
body.single .site-content { background: transparent; padding: 0; }
body.single #primary.lm-single {
    max-width: 100%;
    width: 100%;
    margin: 0;
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
}

.lm-article-header {
    background: var(--lm-dark, #1F2A24);
    color: #fff;
    padding: 3.5rem 0 3rem;
}
.lm-article-header .lm-wrap { max-width: 820px; }
.lm-byline__name { color: #fff; }
.lm-article__cat {
    display: inline-block;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--lm-accent, #C75D2C);
    margin: 0 0 1rem;
}
.lm-article__cat a { color: inherit; text-decoration: none; }
.lm-article__title {
    font-family: var(--lm-head, 'Oswald', sans-serif);
    font-size: clamp(1.85rem, 4vw, 2.75rem);
    font-weight: 700;
    line-height: 1.15;
    margin: 0 0 1.5rem;
    color: #fff;
}

.lm-byline {
    display: flex;
    align-items: center;
    gap: .75rem;
}
.lm-byline__av {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}
.lm-byline__name {
    display: block;
    font-weight: 700;
    font-size: .9rem;
}
.lm-byline__meta {
    display: block;
    font-size: .8rem;
    color: rgba(255,255,255,.5);
}

/* ── Corps de l'article ────────────────────────────────────── */
.lm-article-body { padding: 3rem 0 1rem; }
.lm-article-body .lm-wrap { max-width: 820px; }

.lm-article-content { font-size: 1.05rem; line-height: 1.8; color: var(--lm-text, #1A1A1A); }
.lm-article-content > *:first-child { margin-top: 0; }

.lm-article-content h2 {
    font-family: var(--lm-head, 'Oswald', sans-serif);
    font-size: 1.65rem;
    font-weight: 700;
    margin: 2.5rem 0 1.1rem;
    padding-top: .25rem;
    border-top: 2px solid var(--lm-border, #E5E7EB);
}
.lm-article-content > h2:first-of-type { border-top: none; padding-top: 0; }
.lm-article-content h3 {
    font-family: var(--lm-head, 'Oswald', sans-serif);
    font-size: 1.25rem;
    font-weight: 700;
    margin: 1.75rem 0 .75rem;
}
.lm-article-content p { margin: 0 0 1.15rem; }
.lm-article-content ul,
.lm-article-content ol { margin: 0 0 1.25rem; padding-left: 1.4rem; }
.lm-article-content li { margin-bottom: .4rem; }
.lm-article-content a { color: var(--lm-accent, #C75D2C); text-decoration: underline; }
.lm-article-content strong { font-weight: 700; }

.lm-article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0 2rem;
    font-size: .92rem;
}
.lm-article-content table th,
.lm-article-content table td {
    border: 1px solid var(--lm-border, #E5E7EB);
    padding: .6rem .75rem;
    text-align: left;
}
.lm-article-content table th {
    background: #F9FAFB;
    font-weight: 700;
    font-family: var(--lm-head, 'Oswald', sans-serif);
    letter-spacing: .01em;
}

.lm-article-content figure.wp-block-table { margin: 1.5rem 0 2rem; }

.lm-article-content figure.wp-block-image { margin: 2rem 0; }
.lm-article-content figure.wp-block-image img {
    width: 100%;
    height: auto;
    border-radius: var(--lm-radius, 6px);
    display: block;
}

/* ── TL;DR "À retenir" ─────────────────────────────────────── */
.lm-article-content .tldr {
    background: #FBF6F1;
    border: 1px solid #EBD9CC;
    border-left: 4px solid var(--lm-accent, #C75D2C);
    border-radius: 0 var(--lm-radius, 6px) var(--lm-radius, 6px) 0;
    padding: 1.25rem 1.5rem;
    margin: 2rem 0;
}
.lm-article-content .tldr > strong:first-child {
    display: block;
    font-family: var(--lm-head, 'Oswald', sans-serif);
    font-size: .72rem !important;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--lm-accent, #C75D2C);
    margin: 0 0 .85rem;
}
.lm-article-content .tldr ol {
    margin: 0;
    padding-left: 1.35rem;
    font-size: .9rem;
}
.lm-article-content .tldr li {
    margin-bottom: .5rem;
    line-height: 1.5;
    color: var(--lm-text, #1A1A1A);
}
.lm-article-content .tldr li:last-child { margin-bottom: 0; }
.lm-article-content .tldr li strong {
    display: inline !important;
    color: var(--lm-dark, #1F2A24);
    font-weight: 600;
    font-size: inherit !important;
    letter-spacing: normal !important;
    text-transform: none !important;
    font-family: var(--lm-body, 'Inter', sans-serif) !important;
    line-height: inherit;
    margin: 0 !important;
    padding: 0 !important;
}
.lm-article-content .tldr li::marker {
    color: var(--lm-accent, #C75D2C);
    font-weight: 700;
}

/* ── Encart "à retenir" ────────────────────────────────────── */
.key-takeaway {
    background: #FFF8E1;
    border-left: 4px solid #E6A700;
    padding: 1rem 1.25rem;
    margin: 1.75rem 0;
    border-radius: 0 4px 4px 0;
}
.key-takeaway p { margin: 0; }

/* ── Sources ───────────────────────────────────────────────── */
.lm-sources {
    margin-top: 2.5rem;
    padding: 1rem 1.2rem;
    background: #f8f8f8;
    border-left: 3px solid var(--lm-border, #ddd);
    font-size: .78rem;
    color: #777;
    line-height: 1.6;
}
.lm-sources strong { display: block; margin-bottom: .4rem; color: #555; }
.lm-sources ul { margin: 0; padding-left: 1.2rem; }
.lm-sources a { color: #777 !important; text-decoration: underline; }

/* ── Author box bas de page ───────────────────────────────── */
.lm-authorbox {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin: 3rem 0 0;
    padding: 1.75rem;
    background: #F9FAFB;
    border-radius: var(--lm-radius, 6px);
    border: 1px solid var(--lm-border, #E5E7EB);
}
.lm-authorbox__av {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}
.lm-authorbox__badge {
    display: block;
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--lm-accent, #C75D2C);
    margin-bottom: .3rem;
}
.lm-authorbox__name {
    font-family: var(--lm-head, 'Oswald', sans-serif);
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0 0 .3rem;
}
.lm-authorbox p.lm-authorbox__desc {
    font-size: .875rem;
    color: var(--lm-muted, #6B7280);
    margin: 0;
    line-height: 1.6;
}

@media (max-width: 640px) {
    .lm-article-header { padding: 2.5rem 0 2rem; }
    .lm-authorbox { flex-direction: column; text-align: center; }
}
