/* Section principale */
main {
    padding: 20px;
    padding-left: 10%; /* Marge de 10% sur les côtés */
    padding-right: 10%; /* Marge de 10% sur les côtés */
}

/* Box des statistiques */

/* Conteneur du titre et des boutons */
.header-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px; /* Espacement entre le header et le reste de la page */
}

/* Pour centrer les boutons */
.year-buttons-container {
    display: flex;
    justify-content: center;
    margin-top: 10px; /* Espacement entre le titre et les boutons */
}

/* Styles des boutons */
.year-button {
    background-color: #4CAF50; /* Couleur verte */
    color: white;
    padding: 10px 20px;
    margin: 0 10px; /* Espacement entre les boutons */
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.year-button:hover {
    background-color: #45a049; /* Couleur un peu plus sombre pour le hover */
}

.year-button.disabled {
    background-color: #808080; /* Gris pour les boutons désactivés */
    cursor: not-allowed;
}

/* Assurer que les boutons ne dépassent pas */
.page-container {
    max-width: 1200px;
    margin: auto;
    padding: 20px;
}




.stats-section .last-film-box {
    background-color: white;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease; /* Transition douce */
}

.last-film-box:hover {
    transform: translateY(-5px); /* Effet de surélévation */
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2); /* Ombre accentuée */
}

.stats-box {
    background-color: #ffffff;
    border-radius: 10px;
    padding: 20px;
    margin: 20px auto;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    width: 90%;
}

.stats-box:hover {
    transform: translateY(-5px); /* Effet flottant au survol */
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2); /* Ombre accentuée au survol */
}

.stats-box p {
    font-size: 18px;
    font-weight: bold;
    margin: 20px auto;
    color: #333;
}

.year-box {
    width: 45%;
    padding: 10px;
    border-radius: 10px;
    text-align: center;
}

/* Tableau des films */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 30px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    overflow: hidden; /* Pour que les bords arrondis s'appliquent au tableau */
}

th, td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background-color: #444;
    color: white;
    font-size: 18px;
    padding: 15px;
}

tr {
    transition: background-color 0.3s ease;
}

tr:hover {
    background-color: #d1cdcd;
}

/* Style des films Marvel */
.marvel-film {
    background-color: #f99;
}

.marvel-film:hover {
    background-color: rgb(250, 104, 104);
}

.animation-film {
    background-color: pink; /* Couleur choisie */
}

.animation-film:hover {
    background-color: rgb(253, 123, 145); /* Couleur choisie */
}

/* Box pour les statistiques globales */
.total {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 10px;
}

.total-stats-box {
    text-align: center;
    background-color: #f9f9f9;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.stats-box .total {
    text-align: center;
    width: 100%;
    margin-bottom: 20px;
    font-weight: bold;
}

.total-stats-box h3 {
    font-size: 24px;
    margin-bottom: 10px;
}

.total-stats-box p {
    font-size: 18px;
    color: #666;
}

.total-cinema, .total-economies {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 10px;
}

/* Box pour le dernier film vu */
.last-film-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: #f5f5f5;
    border-radius: 10px;
    padding: 15px;
    max-width: 280px;
    margin: 0 auto;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.year-container {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

.last-film-box img {
    width: 100%;
    border-radius: 8px;
    margin-bottom: 10px;
}

/* Podium des studios */
.podium {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    margin-top: 20px;
    margin-bottom: 20px;
}

.podium-box {
    background-color: #f5f5f5;
    border-radius: 8px;
    padding: 10px;
    text-align: center;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
}

.podium-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.2);
}

.podium-first {
    width: 150px;
    height: 200px;
    background-color: #ffdd57;
    font-weight: bold;
}

.podium-second {
    width: 120px;
    height: 150px;
    background-color: #c0c0c0;
}

.podium-third {
    width: 120px;
    height: 130px;
    background-color: #cd7f32;
}















.page-container {
    display: flex;
    flex-wrap: wrap; /* pour permettre aux cartes de se placer sur plusieurs lignes */
    justify-content: center; /* centre les cartes horizontalement */
    gap: 20px; /* Ajoute un espacement entre les cartes */
    margin-bottom: 30px;
}

.stats-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* Fixe exactement 4 cartes par ligne */
    gap: 20px; /* Espace entre les cartes */
    max-width: 1200px; /* Largeur maximale pour un bon centrage */
}

.stats-card {
    width: 100%;
    max-width: 250px; /* Fixe une largeur maximale pour toutes les cartes */
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    height: auto; /* Ajuste la hauteur automatiquement */
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Assure que le contenu soit bien espacé */
    align-items: center; /* Centre le contenu horizontalement */
}

.stats-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.stats-icon {
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: #4CAF50;
}

.stats-title {
    font-size: 1rem;
    font-weight: bold;
    margin-bottom: 8px;
}

.stats-value {
    font-size: 1.3rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.stats-detail {
    font-size: 0.9rem;
    margin-bottom: 5px; /* Ajoute de l'espace pour éviter que le texte soit trop collé */
}

.stats-comparatif {
    font-size: 0.9rem;
    margin-top: 15px; /* Éloigne le texte de comparaison pour éviter l'effet collé */
}

.stats-comparatif.positive {
    color: #4CAF50; /* Vert pour une valeur en augmentation */
}

.stats-comparatif.negative {
    color: #f44336; /* Rouge pour une valeur en baisse */
}

.stats-comparatif.equal {
    color: #808080; /* Gris pour une valeur stable */
}


.country-card {
    background-size: cover;
    background-position: center;
    color: #333; /* Change la couleur pour assurer une bonne lisibilité */
}

.hoverable-card .hover-content {
    display: none;
    position: absolute;
    bottom: -10px;
    left: 0;
    background: rgba(255, 255, 255, 0.95); /* Ajustement de la transparence pour un effet esthétique */
    padding: 10px;
    width: 100%;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    text-align: left; /* Pour un affichage plus clair des films */
    z-index: 10; /* Assure que le contenu est au-dessus des autres éléments */
}

.hoverable-card:hover .hover-content {
    display: block;
}

.search-container {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.search-bar {
    width: 60%;
    padding: 15px;
    font-size: 16px;
    border-radius: 25px;
    border: 1px solid #ccc;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
    transition: box-shadow 0.3s;
    margin-right: 15px;
}

.search-bar:focus {
    box-shadow: 0 0 10px rgba(0, 123, 255, 0.5);
    outline: none;
}

.film-count {
    font-size: 16px;
    font-weight: bold;
}
