/* Onglet « Émissions » du menu principal (voir emissions.js) */

/* Noms d'émission cliquables dans la grille */
.show-link {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
  text-decoration: underline;
  text-decoration-color: rgba(255,255,255,0.35);
  text-underline-offset: 3px;
}
.show-link:hover { text-decoration-color: white; }

/* Recherche + filtre */
.emi-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}
.emi-tools input,
.emi-tools select {
  flex: 1 1 200px;
  box-sizing: border-box;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.35);
  background: rgba(255,255,255,0.12);
  color: white;
  font-size: 0.92rem;
  font-family: inherit;
}
.emi-tools select option { color: #111; }
.emi-tools input::placeholder { color: rgba(255,255,255,0.55); }
.emi-tools input:focus,
.emi-tools select:focus {
  outline: none;
  border-color: white;
  background: rgba(255,255,255,0.18);
}

/* Fiches : cartes larges, qui occupent toute la largeur de l'écran */
.emi-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  text-align: left;
}
.emi-card {
  display: flex;
  gap: 18px;
  padding: 18px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 20px;
  scroll-margin-top: 20px;
}
.emi-card.is-flash { animation: emiFlash 2.6s ease; }
@keyframes emiFlash {
  0%, 65% {
    box-shadow: 0 0 0 3px rgba(255,255,255,0.9);
    background: rgba(255,255,255,0.22);
  }
  100% {
    box-shadow: 0 0 0 3px rgba(255,255,255,0);
    background: rgba(255,255,255,0.08);
  }
}
.emi-cover {
  position: relative;
  width: 120px;
  height: 120px;
  flex: none;
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.emi-initials {
  font-weight: 800;
  font-size: 2.2rem;
  color: rgba(11,18,32,0.75);
}
.emi-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.emi-body { min-width: 0; flex: 1; }
.emi-title {
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.3;
  color: white;
  overflow-wrap: anywhere;
}
.emi-cat {
  font-size: 0.88rem;
  font-style: italic;
  color: rgba(255,255,255,0.6);
  margin: 4px 0 10px;
}
.emi-dur {
  display: inline-block;
  margin-left: 10px;
  padding: 1px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.16);
  color: white;
  font-style: normal;
  font-weight: 600;
  font-size: 0.82rem;
}
.emi-desc {
  font-size: 1rem;
  line-height: 1.55;
  color: rgba(255,255,255,0.88);
  margin-bottom: 10px;
  white-space: pre-line;
}
.emi-desc-label {
  display: block;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-bottom: 3px;
}
.emi-sched {
  list-style: none;
  font-size: 0.95rem;
  line-height: 1.7;
  color: rgba(255,255,255,0.9);
}
.emi-sched strong { font-weight: 700; color: white; }
.emi-note { color: rgba(255,255,255,0.6); }
.emi-link {
  display: inline-block;
  margin-top: 10px;
  font-size: 0.95rem;
  font-weight: 600;
  color: #7dd3fc;
  text-decoration: none;
}
.emi-link:hover { text-decoration: underline; }
.emi-empty {
  padding: 20px 4px;
  color: rgba(255,255,255,0.7);
  font-style: italic;
}

@media (min-width: 900px) {
  /* La grille des fiches sort de la colonne centrale et prend (presque)
     toute la largeur de la fenêtre (en laissant la place du décor latéral). */
  .emi-grid {
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100vw - 220px);
    max-width: 2200px;
    grid-template-columns: repeat(auto-fill, minmax(480px, 1fr));
    gap: 20px;
  }
  .emi-card { padding: 22px; gap: 22px; }
  .emi-cover { width: 170px; height: 170px; }
  .emi-initials { font-size: 3rem; }
  .emi-title { font-size: 1.4rem; }
  .emi-cat { font-size: 0.95rem; }
  .emi-desc { font-size: 1.05rem; }
  .emi-sched { font-size: 1rem; }
}
@media (min-width: 1300px) {
  .emi-grid { grid-template-columns: repeat(auto-fill, minmax(560px, 1fr)); }
  .emi-cover { width: 200px; height: 200px; }
  .emi-title { font-size: 1.55rem; }
  .emi-desc { font-size: 1.12rem; }
  .emi-sched { font-size: 1.08rem; }
}
@media (max-width: 480px) {
  .emi-card { padding: 14px; gap: 14px; }
  .emi-cover { width: 104px; height: 104px; }
  .emi-initials { font-size: 1.8rem; }
  .emi-title { font-size: 1.1rem; }
}
@media (prefers-reduced-motion: reduce) {
  .emi-card.is-flash { animation: none; box-shadow: 0 0 0 3px rgba(255,255,255,0.9); }
}
