/* Origine : style.css (ancien) — section Responsive */

/* Header premium — mobile */
@media (max-width: 480px){
  .mhg-header-premium__box{
    padding: 8px 10px !important;
    border-radius: 9px;
  }
  .mhg-header-premium__subtitle{
    font-size: 13px;
  }
  .mhg-header-premium__line{
    font-size: 12px;
  }
}

/* Header — Shortcodes recherche PDF/Image (style widget) */
@media (max-width: 600px){
  .mhg-header-search{
    width: 100%;
  }
}

/* HOME — Ressources populaires (bloc SEO / maillage interne) */
@media (max-width: 620px){
  .mhg-home-popular__card{
    width: 100%;
    margin-right: 0;
  }
}

/* Liste des cours – Conteneur */
@media (max-width: 480px) {
  body.mhg-mes-cours-fullwidth .img-my-courses {
    padding: 0 12px;
  }
}

/* Liste des cours – Grille adaptative */
@media (max-width: 640px) {
  body.mhg-mes-cours-fullwidth .img-my-courses-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   FIX RESPONSIVE – CTA HERO PREMIUM (MOBILE)
   Supprime débordement boutons (width 100% + margins)
   ========================================================= */

@media (max-width: 520px){

  .mhg-home-hero-premium .mhg-home-hero-premium__actions{
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    max-width: 100%;
  }

  .mhg-home-hero-premium .mhg-home-hero-premium__actions a,
  .mhg-home-hero-premium .mhg-home-hero-premium__actions .button,
  .mhg-home-hero-premium .mhg-home-hero-premium__actions .wp-element-button,
  .mhg-home-hero-premium .mhg-home-hero-premium__btn{
    width: 100%;
    max-width: 100%;
    margin: 0; /* CRITIQUE : supprime le débordement */
    padding: 12px 14px;
    white-space: normal;
    box-sizing: border-box;
    text-align: center;
  }
}

/* =====================
   MOBILE
   ===================== */

@media (max-width: 620px){

  .mhg-home-hero-premium{
    border-radius: 12px;
    background-position: center top;
  }

  .mhg-home-hero-premium__inner{
    padding: 20px 16px;
    max-width: 100%;
  }

  .mhg-home-hero-premium__title{
    font-size: 22px;
  }

  .mhg-home-hero-premium__lead{
    font-size: 1rem;
  }

  .mhg-home-hero-premium__text{
    font-size: 1.05rem;
  }

  .mhg-home-hero-premium__btn{
    display: block;
    width: 100%;
    text-align: center;
    margin-right: 0;
  }
}

/* HOME — Ressources populaires (premium bois / doré) */
@media (max-width: 620px){
  .mhg-home-popular-premium{
    border-radius: 12px;
    background-position: center top;
  }

  .mhg-home-popular-premium__inner{
    padding: 14px 12px;
  }

  .mhg-home-popular-premium__card{
    width: 100%;
    margin-right: 0;
  }
}

/* HOME — Section premium "Espace en ligne" */
@media (max-width: 620px){
  .mhg-home-online-premium{
    border-radius: 12px;
    background-position: center top;
  }

  .mhg-home-online-premium__inner{
    padding: 14px 12px;
    max-width: 100%;
  }

  .mhg-home-online-premium__item{
    width: 100%;
    margin-right: 0;
  }

  .mhg-home-online-premium__btn{
    display: block;
    width: 100%;
    text-align: center;
    margin-right: 0;
  }
}

/* CTA premium (discret) — bas de page Ressources / Outils */
@media (max-width: 480px){
  .mhg-cta-premium{
    padding: 12px 12px;
  }
  .mhg-cta-premium__link{
    padding: 10px 10px;
  }
}

/* Widget about */
@media (max-width: 640px) {
  .mhg-widget-about {
    flex-direction: column;
  }
  .mhg-about-media {
    flex: none;
  }
  .mhg-about-photo {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
  }
}
