@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+Display:wght@100..900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Display:wght@100..900&family=Noto+Serif+Display:ital,wght@0,100..900;1,100..900&display=swap');

:root {
    --bg-main: hsl(0, 0%, 93%);
    --bg-light: hsl(0, 0%, 100%);
    --bg-medium-light: hsl(0, 0%, 96%);
    --bg-medium : hsl(0, 0%, 88%);
    --bg-item: hsl(0, 0%, 50%);
    --bg-dark: hsl(0, 0%, 20%);

    --text-main: hsl(0, 0%, 20%);
    --text-light: hsl(0, 0%, 100%);
    --text-medium-light: hsl(0, 0%, 80%);
    --text-medium: hsl(0, 0%, 33%);
    --text-placeholder: hsl(0, 0%, 67%);

    --border-medium: hsl(0, 0%, 87%);
    --border-light: hsl(0, 0%, 80%);
    --border-radius-main : 1.5rem;
    --border-radius-scnd : 1rem;
	--border-radius-thrd : 0.5rem;

    --padding-large : 2rem;
    --padding : 1rem;
    --padding-small : 0.5rem;

    --tab-padding : var(--padding-large);
    --tab-gap : var(--padding-large);

    --accent-color: hsl(173, 35%, 50%); 
    --accent-color-light: hsl(173, 35%, 85%); 
    --accent-color-dark: hsl(173, 35%, 35%); 
    --font-title: 'Noto Serif Display', 'Cormorant Garamond', serif;
    --font-text: 'Noto Sans Display', 'Lato', sans-serif;
}


html {
    height: 100%; /* Nécessaire pour que le body puisse prendre 100vh */
}

body {
    font-family: var(--font-text);
    font-weight: 300;
    margin: 0;
    padding: 0;
    background-color: var(--bg-main);
    color: var(--text-main);
    min-height: 100vh; /* Prend au moins toute la hauteur de la vue */
    display: flex; /* Active Flexbox */
    flex-direction: column; /* Empile les éléments (header, main, footer) verticalement */
}

header {
    background: url('images/logoBlanc.png') center 2rem/auto 10rem no-repeat, var(--bg-dark);
    color: var(--text-light);
    padding: var(--padding-large) 0;
    text-align: center;
    font-size:0;
    height: 10rem;
}

/* Appliquer la police serif aux titres */
h1,
h2,
h3 {
    font-family: var(--font-title);
    font-weight: 300; /* Utiliser la graisse Light */
}

header h1 {
    margin: 0; /* Remove default margin if any */
    font-size: 3.5em; /* Exemple d'ajustement */
    line-height: 1.8;
}

main {
    max-width: 1200px;
    margin: 1.25rem auto; /* Garde les marges horizontales auto pour centrer */
    padding: var(--padding);
    position: relative; /* Nécessaire pour positionner .podcast-list */
    flex-grow: 1; /* Permet à main de grandir et de pousser le footer */
    width: 100%; /* Assure que main prend la largeur nécessaire */
    box-sizing: border-box; /* Inclut padding dans la largeur */
}

a{
    color:var(--accent-color);
}
a:active, a:visited{
    color:var(--text-medium-light);
}

/* INTRO et AUTHOR */
/* Styles pour le texte introductif */
section{
    margin-bottom: 2rem;
}

.intro-text {
    padding: var(--padding-large);
    background-color: var(--bg-light);
    border-radius: var(--border-radius-main);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.intro-text h2 {
    margin-top: 0;
    color: var(--text-main);
    font-size: 2em;
    margin-bottom: 0.8em;
}

/* Styles pour la présentation auteur */
.author-presentation {
    display: flex;
    align-items: flex-start; /* Aligne le haut de l'image avec le haut du texte */
    gap: 1.5rem; /* Espace entre image et texte */
    margin-top: 2.5rem; /* Espace après la liste de podcasts ou la grille */
    padding: var(--padding-large);
    background-color: var(--bg-medium-light);
    border-radius: var(--border-radius-main);
    flex-wrap: wrap;
}

.author-image {
    flex-basis: 15rem; /* Largeur de base pour l'image */
    aspect-ratio: 1;
    border-radius: 50%; /* Mettre le radius sur le conteneur */
    overflow: hidden; /* Cacher les parties de l'image qui dépassent */
    border: 3px solid var(--bg-light);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.author-image img {
    display: block;
    width: 100%;
    height: 100%; /* Forcer l'image à remplir le conteneur carré */
    object-fit: cover; /* Recadre l'image pour remplir sans déformer */
    object-position: top; /* Aligne l'image en haut du conteneur */
}

.author-details {
    flex-grow: 1; /* Prend l'espace restant */
    flex-basis: 20rem;
}

.author-details h2 {
    margin-top: 0;
    color: var(--text-main);
    font-size: 2em;
    margin-bottom: 0.8em;
}

.author-details p {
    color: var(--text-medium);
    line-height: 1.5;
    font-family: var(--font-text);
}


/* Exemple d'ajustement pour les titres de section/auteur */
.intro-text h2,
.author-details h2 {
    font-size: 2em;
    margin-bottom: 0.8em;
}

/* ZONE PODCASTS */
/* --- Structure des tabs --- */
.seasons {
    margin-bottom: 2rem;
    counter-reset: season; /* Initialise le compteur de saisons */
}

.season-details {
    margin-bottom: 1rem;
    border-radius: var(--border-radius-main);
    overflow: hidden;
    interpolate-size: allow-keywords;
    
    &::details-content {
      transition:
        block-size 0.5s,
        content-visibility 0.5s allow-discrete;
      overflow: hidden;
      block-size: 0;     /* Or also:  height:0; */
    }
    
    &[open]::details-content {
      block-size: auto;  /* Or also:  height:auto; */
    }
  }

/* Contenu de la saison */
.season-details .season-content {
    background-color: var(--bg-light);
    padding: var(--padding) var(--padding-large) var(--padding-large) var(--padding-large);
    border-radius: 0 0 var(--border-radius-main) var(--border-radius-main);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}


.season-content h2 {
    margin: 0;
    color: var(--text-main);
    font-size: 2em;
    line-height: 2;
    display: none;
}

.season-summary {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: var(--padding);
    background-color: var(--bg-light);
    cursor: pointer;
    border-radius: var(--border-radius-main);
    transition: all 0.3s ease;
    position: relative;
    counter-increment: season; /* Incrémente le compteur de saisons */
    /*counter-reset: podcast; /* Réinitialise le compteur de podcasts */
}

.season-summary:hover {
    background-color: var(--bg-medium-light);
}

/* Style pour la flèche des balises summary */
.season-summary::marker,
.season-summary::-webkit-details-marker {
    display: none;
}

.season-summary::after {
    content: "⊿";
    font-size: 2rem;
    margin-left: auto;
    transition: transform 0.3s ease;
    transform: rotate(45deg);
}

.season-details[open] .season-summary::after {
    transform: rotate(225deg) translate(0, -20px);
}

/* Style pour l'image dans le summary */
.season-summary img {
    width: 8rem;
    height: 8rem;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid var(--bg-light);
    transition: transform 0.3s ease;
    transition: width 0.3s ease, height 0.3s ease;
}

.season-details[open] .season-summary img {
    width: 5rem;
    height: 5rem;
}

.season-details[open] .season-summary {
    border-radius: var(--border-radius-main) var(--border-radius-main) 0 0;
}

/* Style pour le titre dans le summary */
.season-title {
    font-family: var(--font-title);
    font-weight: 500;
    font-size: 2rem;
}

/* Style spécifique pour le compteur de saison */
.season-title::before {
    content: "Saison " counter(season) " : ";
    font-family: var(--font-title);
    font-weight: 300;
    color: var(--accent-color);
}

.podcast-item {
    counter-increment: podcast; /* Incrémente le compteur de podcasts */
}

/* Style pour les titres des podcasts avec compteur */
.podcast-details h3 {
    position: relative;
    margin-top: 0;
    margin-bottom: 5px;
    font-size: 1.6em;
    font-family: var(--font-title);
    font-weight: 300;
}

.podcast-details h3::before {
    content: "Podcast " counter(season) "." counter(podcast) " : ";
    font-weight: normal;
    color: var(--accent-color-light);
    font-weight: 300;
}

.podcast-details h4{
    margin: 0;
    font-family: var(--font-title);
}

.podcast-details h4.guest::before{
    content: "Mon invité·e : ";
    font-weight: normal;
    color: var(--accent-color-light);
    font-weight: 300;
}
.podcast-details h4.infos{
	font-weight:normal;
	font-style:italic;
	color:var(--text-medium-light);
	font-size:0.8rem;
}

.podcast-details p {
    font-size: 0.95em;
    margin-bottom: 10px;
    line-height: 1.4;
    font-family: var(--font-text);
}

.podcast-details a{
	color: var(--accent-color-light);
}

.podcast-details li {
    position: relative;
    padding-left: 1.5em;
    list-style-type: none;
}

.podcast-details li::before {
    content: "✨ ";
    position: absolute;
    left: 0;
}

/* Style pour la liste de podcasts */
.podcast-list {
    display: flex;
    flex-direction: column;
    gap: var(--padding);
}


/* Style pour chaque élément podcast */
.podcast-item {
    background-color: var(--bg-item);
    color: var(--text-light);
    padding: var(--padding);
    border: 1px solid var(--bg-medium-light); 
    border-radius: var(--border-radius-scnd);
}

.podcast-thumbnail {
    float: left;
    margin-right: 1rem;
	margin-bottom: 0.5rem;
    width: 10rem; /* Taille fixe pour la vignette */
    height: 10rem;
}

.podcast-thumbnail img,
.podcast-thumbnail svg {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover; /* S'assure que l'image couvre la zone */
    border-radius: var(--border-radius-thrd);
}

.podcast-details {
    flex-grow: 1; /* Permet aux détails de prendre l'espace restant */
    min-width: 0; /* Correction flexbox pour éviter dépassement */
}

/* Style pour l'élément audio placé sous les détails */
.podcast-item audio {
    width: 100%; /* Prendre toute la largeur disponible */
    margin-top: 0.75rem; /* Espacement au-dessus du lecteur */
}

footer {
    background-color: var(--bg-dark);
    color: var(--text-light);
    padding: var(--padding-large) calc(50% - 600px);
    margin-top: auto; /* Pousse le footer vers le bas lorsque flex-grow est utilisé sur main */
    font-size: 0.9em;
    flex-shrink: 0; /* Empêche le footer de rétrécir */
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
}

footer a{
	color : var(--text-light);
}

/* Animation légère */
@keyframes fadeIn {
    from { opacity: 0; transform: translateX(10px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Animation pour l'accordéon */
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 9.91px) {
    .season-summary {
        padding: var(--padding);
    }
}

@media (max-width: 7.67px) {
    main{
        padding:0px;
        margin:0px;
    }

    .intro-text, .author-details{
        border-radius: 0px;
    }
    
    .season-summary {
        padding: var(--padding-small);
    }
    
    .season-summary img {
        width: 3.5rem;
        height: 3.5rem;
        margin-left: 0; /* Réinitialiser la marge sur mobile */
    }
    
    .season-summary::before {
        position: static; /* Remettre en flux normal */
        margin-right: 0.5rem;
    }
    
    .podcast-details h3 {
        padding-left: 2.5rem; /* Réduire l'espace sur mobile */
    }
    
    .season-content {
        padding: var(--padding);
        border-radius: 0;
    }
    
    /* Transformer les season-label en accordéon pour mobile */
    .season-labels {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .season-label {
        display: flex;
        align-items: center;
        width: 100%;
        height: auto;
        padding: var(--padding);
        margin-bottom: 0.5rem;
        background-color: var(--bg-medium-light);
        border-radius: var(--border-radius-scnd);
        box-shadow: 0 1px 3px rgba(0,0,0,0.1);
        text-align: left;
    }
    
    /* Ajouter une flèche pour indiquer l'expansion */
    .season-label::after {
        content: "▼";
        font-size: 0.8rem;
        margin-left: 0.5rem;
        transition: transform 0.3s ease;
    }
    
    /* Pour le label actif */
    .season-label.active {
        background-color: var(--bg-light);
        border-radius: var(--border-radius-scnd) var(--border-radius-scnd) 0 0;
        margin-bottom: 0;
    }
    
    .season-label.active::after {
        transform: rotate(180deg);
    }
    
    /* Afficher le titre accordéon et cacher la vignette sur mobile */
    .season-visual {
        width: 5rem;
        height: 5rem;
        border-radius: 50%;
        margin-right: 0.75rem;
        background-color: transparent;
        border: none;
    }
    
    .season-visual img {
        border-radius: 50%;
        border: 2px solid var(--bg-light);
    }
    
    .accordion-title {
        display: block;
        font-family: var(--font-title);
        font-weight: 500;
        flex-grow: 1;
    }
    
    .season-title {
        display: none; /* Cacher le titre overlay sur l'image */
    }
    
    /* Modifier la taille des vignettes de podcast en mobile */
    .podcast-thumbnail {
        width: 6rem; /* Réduire la largeur des vignettes */
        height: 6rem; /* Réduire la hauteur des vignettes */
    }
    
    /* Réorganiser la section auteur en colonne pour mobile */
    .author-presentation {
        flex-direction: column; /* Empiler les éléments verticalement */
        padding: var(--padding); /* Réduire le padding */
    }
    
    .author-image {
        margin-bottom: 1.5rem; /* Espace entre l'image et le texte */
        flex-basis: 12rem; 
        aspect-ratio: 1;
    }
    
    .author-details {
        width: 100%; /* Prendre toute la largeur */
    }
    
    /* Réduire le padding des éléments de podcast */
    .podcast-item {
        padding: var(--padding-small);
    }

    /* Ajuster l'alignement de l'audio en mobile */
    .podcast-item audio {
        margin-left: calc(6rem + 15px); /* Ajuster en fonction de la largeur réduite des vignettes sur mobile */
    }
}

.podcast-platforms {
    padding: var(--padding-large);
    background-color: var(--bg-light);
    border-radius: var(--border-radius-main);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    text-align: center;
}

.podcast-platforms h2 {
    margin-top: 0;
    color: var(--text-main);
    font-size: 1.8em;
    margin-bottom: 0.5em;
}

.podcast-platforms p {
    color: var(--text-medium);
    margin-bottom: 1.5rem;
}

.platform-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
    align-items: center;
}

.platform-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background-color: var(--bg-light);
    border-radius: 50%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.platform-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.platform-link img {
    width: 100%;
    height: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 50%;
}
