/* =====================================================================
   Onex Shop — blog_details.css
   Complète blog.css (chargé en parallèle) : mise en forme de l'article
   complet, barre de progression de lecture, bloc de partage.
   ===================================================================== */

/* ---------------------------------------------------------------------
   Barre de progression de lecture
   --------------------------------------------------------------------- */
.onex-reading-progress {
    position: sticky;
    top: 0;
    z-index: 120;
    height: 4px;
    background: var(--paper-dark);
}

.onex-reading-progress #readingProgressBar {
    height: 100%;
    width: 0%;
    background: var(--turquoise);
    transition: width 0.1s linear;
}

/* ---------------------------------------------------------------------
   En-tête d'article
   --------------------------------------------------------------------- */
.onex-article { max-width: 780px; margin-inline: auto; padding-bottom: 3rem; }

.onex-article__header { padding-block: 1.5rem 2rem; text-align: center; }
.onex-article__header h1 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); margin: 1rem 0 1.2rem; }

.onex-article__meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.4rem;
    flex-wrap: wrap;
    font-size: 0.85rem;
    color: var(--ink-soft);
}

.onex-article__meta i { color: var(--turquoise-deep); margin-right: 0.35rem; }
.onex-article__rating i { color: var(--ink); margin-right: 0.1rem; }

/* ---------------------------------------------------------------------
   Image de couverture
   --------------------------------------------------------------------- */
.onex-article__cover {
    border: 3px solid var(--ink);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 8px 8px 0 var(--turquoise);
    aspect-ratio: 16 / 9;
    background: var(--paper-dark);
    margin-bottom: 2.5rem;
}

.onex-article__cover img { width: 100%; height: 100%; object-fit: cover; }

/* ---------------------------------------------------------------------
   Contenu
   --------------------------------------------------------------------- */
.onex-article__content {
    font-family: var(--font-body);
    color: var(--ink);
    font-size: 1.05rem;
    line-height: 1.9;
}

.onex-article__content p {
    text-transform: none;
    margin-bottom: 1.5rem;
}

.onex-article__content p:first-of-type {
    font-size: 1.15rem;
    color: var(--ink-soft);
}

/* ---------------------------------------------------------------------
   Partage
   --------------------------------------------------------------------- */
.onex-article__share {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 2.5rem;
    padding-top: 1.8rem;
    border-top: 2px solid var(--ink);
    font-size: 0.88rem;
    color: var(--ink-soft);
}

.onex-article__share button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--white);
    border: 2px solid var(--ink);
    border-radius: var(--radius-sm);
    padding: 0.6rem 1.1rem;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--ink);
    transition: background-color 0.2s ease, color 0.2s ease;
}

.onex-article__share button:hover,
.onex-article__share button.is-copied { background: var(--yellow); }

/* ---------------------------------------------------------------------
   Articles similaires : rendu plus soigné et homogène
   --------------------------------------------------------------------- */
.onex-blog-grid--related {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
    padding-bottom: 0;
    align-items: stretch;
}

.onex-blog-card--related {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.onex-blog-card--related .onex-blog-card__media {
    aspect-ratio: 16 / 10;
}

.onex-blog-card--related .onex-blog-card__body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 1rem 1rem 1.1rem;
}

.onex-blog-card--related .onex-blog-card__body h2 {
    font-size: 0.98rem;
    line-height: 1.45;
    margin-bottom: 0.75rem;
}

.onex-blog-card--related .onex-blog-card__meta {
    flex-wrap: wrap;
    gap: 0.45rem 0.9rem;
    margin-top: auto;
    padding-top: 0.8rem;
}

@media (max-width: 860px) {
    .onex-blog-grid--related { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
    .onex-blog-grid--related { grid-template-columns: 1fr; }
}