/*
 * Fiche d’une actualité
 * Extrait de templates/public/news/show.html.twig : ce fichier remplace le bloc <style> que le
 * gabarit portait en ligne. Chargé via asset() (versionné par ASSETS_VERSION).
 */

/* ---------- Breadcrumb header ---------- */
.article-breadcrumb {
    padding: 110px 0 1rem;
    position: relative;
    z-index: 2;
}

.article-breadcrumb-nav {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.55);
    letter-spacing: 0.3px;
}

.article-breadcrumb-nav a {
    color: #9b7eed;
    text-decoration: none;
    transition: color 0.3s;
}

.article-breadcrumb-nav a:hover {
    color: #fff;
}

/* La liste ordonnée porte la sémantique ; l'apparence reste celle d'avant. */
.article-breadcrumb-nav ol {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    margin: 0;
    padding: 0;
}

.article-breadcrumb-nav li {
    display: inline-flex;
    align-items: center;
}

/* Séparateur décoratif : en CSS, donc jamais lu par un lecteur d'écran. */
.article-breadcrumb-nav li + li::before {
    content: "/";
    color: rgba(255, 255, 255, 0.25);
    margin: 0 0.5rem;
}

/* ---------- Hero ---------- */
.article-hero {
    position: relative;
    margin: 1rem 0 4rem;
    border-radius: 24px;
    overflow: hidden;
    min-height: 460px;
    display: flex;
    align-items: flex-end;
    border: 1px solid rgba(112, 69, 225, 0.18);
    box-shadow:
        0 30px 70px rgba(0, 0, 0, 0.55),
        0 0 0 1px rgba(112, 69, 225, 0.08);
    background: linear-gradient(135deg, #1a1226 0%, #0c0814 100%);
}

.article-hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    -webkit-filter: blur(5px); /* Safari 6.0 - 9.0 */
    filter: blur(5px);
}

.article-hero-fallback {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #2c178a 0%, #4828b3 50%, #7045e1 100%);
    color: rgba(255, 255, 255, 0.85);
    font-size: 5rem;
    z-index: 0;
}

.article-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(12, 8, 20, 0.1) 0%,
        rgba(12, 8, 20, 0.5) 55%,
        rgba(12, 8, 20, 0.95) 100%
    );
    z-index: 1;
    pointer-events: none;
}

.article-hero-content {
    position: relative;
    z-index: 2;
    padding: 3rem 3.5rem;
    width: 100%;
    max-width: 900px;
}

.article-hero-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 1.2rem;
}

.article-tag {
    display: inline-block;
    background: rgba(112, 69, 225, 0.25);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(155, 126, 237, 0.45);
    color: #fff;
    padding: 0.4rem 1rem;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
}

.article-hero-title {
    font-family: 'Poppins', sans-serif;
    font-size: 3rem;
    font-weight: 800;
    color: #fff;
    line-height: 1.15;
    margin-bottom: 1.2rem;
    letter-spacing: -0.035em;
    text-shadow: 0 6px 30px rgba(0, 0, 0, 0.6);
}

.article-hero-excerpt {
    font-size: 1.15rem;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.6;
    margin-bottom: 1.5rem;
    max-width: 720px;
}

.article-hero-meta {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

.article-hero-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.article-hero-meta-item i {
    color: #9b7eed;
}

/* ---------- Body ---------- */
.article-container {
    padding: 0 0 80px;
    position: relative;
}

.article-body {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.82);
}

.article-body p {
    margin-bottom: 0rem;
}

/* Blocs de paragraphe produits par Trix (<div>) */
.article-body > div {
    margin-bottom: 1rem;
}

.article-body h1,
.article-body h2 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.85rem;
    font-weight: 800;
    color: #fff;
    margin-top: 3rem;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
    scroll-margin-top: 110px;
}

.article-body h3 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    color: #fff;
    margin-top: 2rem;
    margin-bottom: 0.8rem;
    scroll-margin-top: 110px;
}

.article-body strong { color: #fff; font-weight: 600; }

.article-body a {
    color: #9b7eed;
    text-decoration: underline;
    text-decoration-color: rgba(112, 69, 225, 0.4);
    transition: all 0.3s;
}

.article-body a:hover {
    color: #fff;
    text-decoration-color: #7045e1;
}

.article-body ul, .article-body ol {
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.article-body li { margin-bottom: 0.5rem; }

.article-body blockquote {
    background: rgba(18, 13, 26, 0.7);
    border-left: 3px solid #7045e1;
    padding: 1.2rem 1.5rem;
    border-radius: 12px;
    margin: 2rem 0;
    color: rgba(255, 255, 255, 0.88);
    font-style: italic;
}

.article-body img {
    max-width: 100%;
    height: auto;
    border-radius: 14px;
    margin: 1.5rem 0;
}

.seo-callout {
    background: rgba(18, 13, 26, 0.7);
    backdrop-filter: blur(12px);
    padding: 1.5rem 1.8rem;
    border-radius: 14px;
    margin: 2.5rem 0;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-left: 3px solid #7045e1;
    color: rgba(255, 255, 255, 0.78);
}

/* ---------- Sidebar ---------- */
.article-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    position: sticky;
    top: 100px;
}

.sidebar-card {
    background: rgba(18, 13, 26, 0.78);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    padding: 1.5rem;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.sidebar-card-title {
    font-family: 'Poppins', sans-serif;
    font-size: 0.78rem;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.55);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 1.6px;
}

.sidebar-card-title i { color: #7045e1; }

/* TOC */
.toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.toc-list a {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.92rem;
    line-height: 1.45;
    padding: 0.45rem 0.7rem;
    border-radius: 8px;
    border-left: 2px solid rgba(112, 69, 225, 0.25);
    transition: all 0.25s;
}

.toc-list a:hover,
.toc-list a.active {
    color: #fff;
    background: rgba(112, 69, 225, 0.12);
    border-left-color: #7045e1;
}

.toc-list a.level-3 {
    padding-left: 1.4rem;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.55);
}

.toc-empty {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.45);
    font-style: italic;
}

/* Share */
.share-buttons {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.share-btn {
    flex: 1;
    min-width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(112, 69, 225, 0.12);
    border: 1px solid rgba(112, 69, 225, 0.3);
    color: #9b7eed;
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s;
    font-size: 1rem;
}

.share-btn:hover {
    background: rgba(112, 69, 225, 0.25);
    border-color: #7045e1;
    color: #fff;
    transform: translateY(-2px);
}

.share-btn.copied {
    background: rgba(72, 187, 120, 0.2);
    border-color: rgba(72, 187, 120, 0.5);
    color: #6ee7a8;
}

/* Contact sidebar */
.sidebar-contact p {
    font-size: 0.88rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.55;
    margin-bottom: 1rem;
}

.cta-button {
    background: linear-gradient(135deg, #2c178a 0%, #4828b3 50%, #7045e1 100%);
    background-size: 200% 200%;
    background-position: 0% 50%;
    color: #fff;
    padding: 0.85rem 1.2rem;
    text-align: center;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    text-decoration: none;
    display: block;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 10px 28px rgba(44, 23, 138, 0.45),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.cta-button:hover {
    background-position: 100% 50%;
    transform: translateY(-3px);
    box-shadow: 0 16px 38px rgba(44, 23, 138, 0.6), 0 0 0 1px rgba(112, 69, 225, 0.4);
    color: #fff;
}

/* ---------- Bottom navigation ---------- */
.article-navigation {
    display: flex;
    gap: 1rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    flex-wrap: wrap;
}

.article-nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.85rem 1.8rem;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 1.4px;
}

.article-nav-btn-secondary {
    background: rgba(20, 14, 30, 0.6);
    color: #fff;
    border: 1.5px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
}

.article-nav-btn-secondary:hover {
    background: rgba(30, 22, 44, 0.8);
    border-color: rgba(255, 255, 255, 0.25);
    color: #fff;
    transform: translateY(-3px);
}

.article-nav-btn-primary {
    background: transparent;
    color: #fff;
    border: 1.5px solid rgba(112, 69, 225, 0.6);
    box-shadow: 0 0 0 1px rgba(112, 69, 225, 0.15), 0 8px 24px rgba(44, 23, 138, 0.35);
}

.article-nav-btn-primary:hover {
    background: rgba(112, 69, 225, 0.1);
    border-color: #7045e1;
    color: #fff;
    gap: 0.8rem;
    transform: translateY(-3px);
}

/* ---------- Derniers articles (maillage interne) ---------- */
.related-section {
    margin-top: 5rem;
    padding-top: 3rem;
    padding-bottom: 5rem;
    border-top: 1px solid rgba(112, 69, 225, 0.2);
}

.related-eyebrow {
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #9b7eed;
    margin-bottom: 0.7rem;
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
}

.related-eyebrow::before {
    content: "";
    width: 32px;
    height: 1px;
    background: linear-gradient(90deg, rgba(155, 126, 237, 0.6), transparent);
}

.related-section-title {
    font-family: 'Poppins', sans-serif;
    font-size: 1.9rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 2.2rem;
    letter-spacing: -0.025em;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.75rem;
}

.related-card {
    background: rgba(18, 13, 26, 0.78);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    text-decoration: none;
    display: flex;
    flex-direction: column;
}

.related-card:hover {
    transform: translateY(-8px);
    border-color: rgba(112, 69, 225, 0.3);
    box-shadow: 0 22px 50px rgba(44, 23, 138, 0.4), 0 0 0 1px rgba(112, 69, 225, 0.3);
}

.related-card-image {
    height: 190px;
    overflow: hidden;
    background: linear-gradient(135deg, #1a1226 0%, #0c0814 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.55);
    font-size: 2.6rem;
}

.related-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.related-card:hover .related-card-image img {
    transform: scale(1.08);
}

.related-card-content {
    padding: 1.5rem 1.6rem 1.7rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.related-card-date {
    font-size: 0.72rem;
    color: #9b7eed;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.4px;
    margin-bottom: 0.7rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.related-card-title {
    font-family: 'Poppins', sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.4;
    letter-spacing: -0.015em;
    margin-bottom: 0.8rem;
}

.related-card-excerpt {
    font-size: 0.92rem;
    color: rgba(255, 255, 255, 0.68);
    line-height: 1.6;
    margin-bottom: 1.25rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #9b7eed;
    font-weight: 600;
    font-size: 0.9rem;
    margin-top: auto;
    transition: all 0.3s;
}

.related-card:hover .related-card-link {
    gap: 0.85rem;
    color: #fff;
}

@media (max-width: 992px) {
    .article-sidebar { position: static; }
    .article-hero { min-height: 380px; }
    .article-hero-title { font-size: 2.2rem; }
    .article-hero-content { padding: 2rem 2rem; }
    .related-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .article-breadcrumb { padding-top: 100px; }
    .article-hero {
        min-height: 320px;
        border-radius: 18px;
        margin-bottom: 2.5rem;
    }
    .article-hero-title { font-size: 1.7rem; }
    .article-hero-excerpt { font-size: 1rem; }
    .article-hero-content { padding: 1.5rem 1.5rem; }
    .article-body h2 { font-size: 1.45rem; }
    .related-section { margin-top: 3.5rem; }
    .related-section-title { font-size: 1.5rem; }
    .related-grid { grid-template-columns: 1fr; gap: 1.5rem; }
}
