/* =============================================================
   Cours Plugin — Frontend Styles
   Agence Hi Web — Haris Ukalo
   ============================================================= */

:root {
    --cours-color: #27ae60;
    --cours-text:  #ffffff;
}

/* ---- Wrapper global ---- */
.cours-wrapper {
    font-family: inherit;
    margin-bottom: 40px;
}

/* ============================================================
   HEADER — pleine largeur (sort du conteneur boxed du thème)
   ============================================================ */
.cours-header {
    position: relative;
    min-height: 320px;
    background-color: #1a1a2e;
    background-size: cover;
    background-position: center;
    overflow: hidden;
    padding: 0;

    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    box-sizing: border-box;
}

/* Conteneur intérieur centré avec max-width */
.cours-header__inner {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 48px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    min-height: 320px;
}

.cours-header__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.45);
    z-index: 0;
}

/* Titre */
.cours-header__title-wrap {
    position: relative;
    z-index: 1;
    flex: 1;
}

.cours-header__title {
    display: inline-block;
    background-color: var(--cours-color);
    color: var(--cours-text);
    font-size: clamp(1.25rem, 3vw, 2rem);
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
    padding: 14px 24px;
    margin: 0;
    line-height: 1.2;
    border-radius: 2px;
}

/* Badge durée + niveau */
.cours-header__badge {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 24px;
    flex-shrink: 0;
}

/* Cercle durée */
.cours-badge-duree {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    border: 5px solid var(--cours-color);
    background: rgba(0,0,0,.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
    box-shadow: 0 0 0 3px rgba(255,255,255,.15);
}

.cours-badge-duree__num {
    font-size: 2.4rem;
    font-weight: 900;
    line-height: 1;
}

.cours-badge-duree__label {
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    opacity: .85;
}

/* Niveau */
.cours-badge-niveau {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    color: #fff;
}

.cours-niveau-dots {
    display: flex;
    gap: 6px;
    background: rgba(255,255,255,.2);
    border-radius: 30px;
    padding: 6px 12px;
}

.cours-niveau-dots .dot {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(255,255,255,.35);
    border: 2px solid rgba(255,255,255,.5);
    transition: background .2s;
}

.cours-niveau-dots .dot--active {
    background: var(--cours-color);
    border-color: var(--cours-color);
}

.cours-badge-niveau__meta {
    display: flex;
    flex-direction: column;
}

.cours-badge-niveau__tag {
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    opacity: .75;
}

.cours-badge-niveau__val {
    font-size: 1rem;
    font-weight: 700;
}

/* ============================================================
   BODY
   ============================================================ */
.cours-body {
    display: flex;
    gap: 40px;
    padding: 40px 0;
    align-items: flex-start;
}

/* ---- Colonne gauche ---- */
.cours-body__left {
    flex: 1 1 60%;
}

/* Ressort badge */
.cours-ressort-badge {
    display: inline-block;
    border: 1px solid #ccc;
    color: #555;
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    padding: 3px 10px;
    border-radius: 3px;
    margin-bottom: 18px;
}

/* Prof */
.cours-prof {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.cours-prof__photo {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid var(--cours-color);
}

.cours-prof__photo--placeholder {
    width: 56px;
    height: 56px;
    background: #f0f0f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #ddd;
}

.cours-prof__photo--placeholder svg {
    width: 36px;
    height: 36px;
}

.cours-prof__info strong {
    display: block;
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a1a;
}

.cours-prof__bio-link {
    font-size: .8rem;
    color: var(--cours-color);
    cursor: pointer;
    text-decoration: underline;
}

.cours-prof__bio {
    display: none;
    margin-top: 6px;
    font-size: .85rem;
    color: #555;
    line-height: 1.5;
}

/* Infos liste */
.cours-infos {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cours-infos__item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: .9rem;
    color: #333;
    line-height: 1.45;
}

.cours-infos__icon {
    width: 34px;
    height: 34px;
    border-radius: 6px;
    background: var(--cours-color);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cours-infos__icon svg {
    width: 18px;
    height: 18px;
}

/* ---- Colonne droite ---- */
.cours-body__right {
    flex: 0 0 260px;
}

.cours-horaires__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 16px;
}

.cours-horaires {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cours-horaire-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: #f8f9fa;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    padding: 14px 16px;
}

.cours-horaire-card__icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--cours-color);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cours-horaire-card__icon svg {
    width: 18px;
    height: 18px;
}

.cours-horaire-card > div {
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.cours-horaire-card__jour {
    font-size: .95rem;
    font-weight: 700;
    color: #1a1a1a;
    letter-spacing: .04em;
}

.cours-horaire-card__heure {
    font-size: .82rem;
    color: #555;
}

.cours-no-horaire {
    color: #888;
    font-size: .85rem;
    font-style: italic;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
    .cours-header__inner {
        flex-direction: column;
        align-items: flex-start;
        padding: 28px 20px;
        min-height: 240px;
        gap: 20px;
    }

    .cours-header__badge {
        align-self: flex-end;
        gap: 16px;
    }

    .cours-badge-duree {
        width: 80px;
        height: 80px;
    }

    .cours-badge-duree__num {
        font-size: 1.8rem;
    }

    .cours-body {
        flex-direction: column;
        padding: 28px 0;
        gap: 28px;
    }

    .cours-body__right {
        flex: none;
        width: 100%;
    }

    .cours-header__title {
        font-size: 1.1rem;
        padding: 10px 16px;
    }
}
