/* =========================
   BASE
========================= */
body {
    margin: 0;
    font-family: Georgia, serif;
    background-color: #f4f4f4;
    color: #111;
}

img {
    max-width: 100%;
    height: auto;
}

/* =========================
   HEADER
========================= */
header {
    background: #222;
    color: white;
    padding: 20px;
    text-align: center;
}

nav a {
    color: #ddd;
    margin: 0 15px;
    text-decoration: none;
}

nav a:hover {
    text-decoration: underline;
}

nav a.active {
    color: white;
    font-weight: bold;
}

/* =========================
   HERO (PAGE D'ACCUEIL)
========================= */
.hero {
    position: relative;
    height: 100vh;
    overflow: hidden;
}

/* IMAGE PLEIN ÉCRAN */
.hero-img {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(1);
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.6s ease;
    z-index: 0;
}

/* ZOOM AU SURVOL */
.hero:hover .hero-img {
    transform: translate(-50%, -50%) scale(1.03);
}

/* FILTRE SOMBRE */
.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1;
}

/* CARTOUCHE TEXTE */
.overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 600px;
    width: 80%;
    background: rgba(0,0,0,0.5);
    color: white;
    padding: 25px;
    z-index: 2;
    text-align: center;
    backdrop-filter: blur(4px);
}

/* =========================
   ANIMATION TEXTE HERO
========================= */
.overlay .fade-line {
    opacity: 0;
    transform: translateY(15px);
    animation: fadeUp 1s ease forwards;
}

/* Délais progressifs */
.overlay .fade-line:nth-of-type(1) {
    animation-delay: 0.5s;
}

.overlay .fade-line:nth-of-type(2) {
    animation-delay: 1.8s;
}

.overlay .fade-line:nth-of-type(3) {
    animation-delay: 3s;
}

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================
   TYPOGRAPHIE
========================= */
h1, h2 {
    font-family: 'Times New Roman', serif;
}

/* =========================
   SECTIONS GÉNÉRALES
========================= */
section {
    padding: 50px;
    max-width: 800px;
    margin: auto;
}

/* =========================
   MACHINE À ÉCRIRE (TITRE)
========================= */
.typewriter-title {
    display: inline-block;
    text-align: center;
    margin: 0 auto;
    font-family: 'Times New Roman', serif;
    font-size: 2em;
    white-space: nowrap;
}

/* =========================
   MACHINE À ÉCRIRE (TEXTE)
========================= */
.typewriter-text {
    display: block;
    margin: 15px auto;
    white-space: normal;
    max-width: 100%;
    text-align: center;
    opacity: 0;
    animation: fadeIn 0.5s ease forwards;
    animation-delay: 0.5s;
    font-size: 1.3em; /* Police légèrement agrandie */
    font-family: Georgia, serif; /* Police élégante */
    line-height: 1.5; /* Espacement des lignes pour une meilleure lisibilité */
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* =========================
   BOUTON (APPARITION DÉLAYÉE)
========================= */
#delayed-button {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

/* =========================
   BOUTONS (STYLE DE BASE)
========================= */
button {
    padding: 10px 15px;
    background: #b30000;
    color: white;
    border: none;
    cursor: pointer;
    transition: transform 0.2s ease;
}

button:hover {
    transform: scale(1.05);
}
/* =========================
   QUATRIÈME DE COUVERTURE
========================= */
.quatrieme {
    max-width: 700px;
    margin: 30px auto;
    padding: 30px;
    background: #ffffff;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
}

/* COUVERTURE */
.quatrieme .cover {
    display: block;
    margin: 0 auto 40px auto;
    width: 260px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
}

/* TEXTE */
.resume {
    font-size: 17px;
    line-height: 1.5;
    color: #222;
}

.resume p {
    text-align: justify;
    hyphens: auto;
    margin-bottom: 25px;
    text-indent: 20px;
}

/* IMAGE BASSE */
.image-roman {
    display: block;
    margin: 30px auto 0 auto;
    width: 65%;
    max-width: 500px;
    height: auto;
    filter: grayscale(100%);
    opacity: 0.9;
}

.cta-download {
    margin: 30px auto 10px auto;
    max-width: 500px;
    background: #b30000;
    color: white;
    padding: 20px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
}

.cta-download p {
    margin: 0 0 15px 0;
    font-size: 16px;
    font-weight: bold;
}

.download-link {
    display: inline-block;
    padding: 8px 15px;
    background: white;
    color: #b30000;
    text-decoration: none;
    font-weight: bold;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.download-link:hover {
    background: #222;
    color: white;
}

/* =========================
   PERSONNAGES (STYLE DOSSIER)
========================= */
.fiche-personnage {
    display: flex;
    gap: 20px;
    margin-bottom: 40px;
    padding: 20px;
    background: #fdfdfd;
    border-left: 6px solid #222;
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
}

.fiche-personnage img {
    width: 120px;
    height: 150px;
    object-fit: cover;
    filter: grayscale(100%);
}

.fiche-personnage .contenu {
    flex: 1;
}

.fiche-personnage h3 {
    margin-top: 0;
    text-transform: uppercase;
}

.fiche-personnage span {
    font-weight: bold;
    letter-spacing: 1px;
}

.image-roman {
    display: block;
    margin: 40px auto;
    margin-top: 60px;
    max-width: 600px;
    width: 100%;
    height: auto;
    border: 2px solid #222;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
    filter: grayscale(100%);
}

/* =========================
   EXTRAITS
========================= */
.extrait {
    max-width: 600px;
    margin: auto;
    line-height: 1.7;
    text-align: justify;
    hyphens: auto;
}

/* IMAGES EXTRAITS */
.image-extrait {
    display: block;
    width: auto;
    max-width: 280px;
    height: auto;
    margin: 40px auto;
    border: 2px solid #222;
    filter: grayscale(100%);
}

/* Variante plus petite */
.image-petite {
    max-width: 180px;
}

/* Style pour le footer */
.footer-content {
    display: flex;             /* Affiche les éléments en ligne */
    align-items: center;       /* Centre verticalement */
    justify-content: center;   /* Centre horizontalement */
    gap: 15px;                 /* Espace entre le texte et le logo */
    padding: 10px 0;          /* Espace interne */
    text-align: center;        /* Alignement du texte */
}

/* Style pour le logo dans le footer */
.footer-logo {
    height: 140px;             /* Hauteur plus grande pour le logo */
    width: auto;              /* Largeur automatique (conserve les proportions) */
    margin-left: 10px;        /* Espace à gauche du logo */
}