@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;700&family=Playfair+Display:ital,wght@0,600;1,600&display=swap');

:root {
    --bg: #fffdf5; /* Papier crème doux */
    --text: #2d3436;
    --accent: #6c5ce7;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg);
    color: var(--text);
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* HEADER */
header {
    text-align: center;
    padding: 60px 20px;
    width: 100%;
    background: radial-gradient(circle at 50% 50%, #ffffff 0%, #f3f0ff 100%);
    border-bottom: 1px solid #e0e0e0;
}

h1 {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    margin: 0;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    font-size: 1.2rem;
    color: #636e72;
    margin-top: 10px;
}

/* UPLOAD ZONE */
.upload-container {
    margin: -30px auto 40px;
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
    text-align: center;
    width: 90%;
    max-width: 500px;
    transition: 0.3s;
    border: 2px dashed #dfe6e9;
}

.upload-container:hover {
    border-color: var(--accent);
    transform: translateY(-5px);
}

.file-input {
    display: none;
}

.upload-btn {
    background: var(--accent);
    color: white;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 700;
    cursor: pointer;
    display: inline-block;
    transition: 0.2s;
    font-size: 1rem;
}

.upload-btn:hover {
    background: #5649c0;
    box-shadow: 0 5px 15px rgba(108, 92, 231, 0.3);
}

/* LOADER */
.loader {
    display: none;
    margin: 20px auto;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--accent);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* READER (LE TEXTE PIMPÉ) */
#reader {
    width: 100%;
    max-width: 900px;
    background: white;
    padding: 60px;
    margin-bottom: 50px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    border-radius: 5px; /* Effet feuille de papier */
    line-height: 1.9;
    font-size: 1.15rem;
    display: none; /* Caché au début */
}

/* STYLES PIMPÉS */
#reader h2 {
    font-family: 'Playfair Display', serif;
    color: #2d3436;
    border-bottom: 3px solid #ffeaa7;
    display: inline-block;
    padding-bottom: 5px;
    margin-top: 40px;
}

/* Surlignage "Stabilo" */
.highlight-yellow {
    background: linear-gradient(120deg, rgba(255, 234, 167, 0) 0%, rgba(255, 234, 167, 1) 100%);
    background-repeat: no-repeat;
    background-size: 100% 40%;
    background-position: 0 88%;
    font-weight: 500;
}

.highlight-green {
    background-color: #dff9fb;
    color: #00b894;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.9em;
    border: 1px solid #81ecec;
}

.highlight-pink {
    background-color: #ffeef2;
    color: #e84393;
    border-bottom: 2px solid #e84393;
    font-style: italic;
}

strong {
    color: #2d3436;
    font-weight: 800;
}
