.hidden {
    display: none !important;
}



:root {
    --primary: #8a6e42;
    --primary-dark: #6d582e;
    --secondary: #c1a872;
    --light: #f4eee1;
    --dark: #2c2418;
    --accent: #a64b31;
    --text: #3a3a3a;
    --text-light: #f4eee1;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Lato', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: var(--light);
    color: var(--text);
    font-size: 16px;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--text-light);
    padding: 1rem;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

h1 {
    font-family: 'Cinzel', serif;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    position: relative;
    z-index: 2;
}

h2 {
    font-family: 'Cinzel', serif;
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--primary-dark);
}

main {
    flex: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
}

.hidden {
    display: none !important;
}

/* Écran d'accueil */
.welcome-screen {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.welcome-title {
    font-family: 'Cinzel', serif;
    color: var(--primary-dark);
    margin-bottom: 1.5rem;
}

.welcome-image {
    width: 100%;
    max-width: 500px;
    height: auto;
    border-radius: 8px;
    margin: 1rem 0;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.welcome-text {
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.start-button {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.2rem;
    border-radius: 30px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: bold;
    margin: 1rem 0;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.start-button:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
}

/* Game Container */
.game-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.game-header {
    background-color: white;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.progress-container {
    flex: 1;
    background-color: #e0e0e0;
    height: 16px;
    border-radius: 10px;
    overflow: hidden;
    margin: 0 1rem;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--secondary) 0%, var(--primary) 100%);
    width: 0%;
    transition: width 0.5s ease;
}

.score-display {
    font-weight: bold;
    font-size: 1.1rem;
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.score-display i {
    color: var(--accent);
}

.game-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.game-stage {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.stage-image {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-bottom: 3px solid var(--secondary);
}

.stage-content {
    padding: 1.5rem;
}

.stage-title {
    color: var(--primary-dark);
    margin-bottom: 1rem;
    font-family: 'Cinzel', serif;
}

.stage-description {
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.choice-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.choice-button {
    background-color: var(--light);
    border: 2px solid var(--secondary);
    padding: 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
    text-align: left;
}

.choice-button:hover {
    background-color: var(--secondary);
    color: var(--text-light);
    transform: translateY(-2px);
}

.game-info {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.info-section {
    border-left: 3px solid var(--secondary);
    padding-left: 1rem;
}

.info-title {
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
    font-family: 'Cinzel', serif;
}

.feedback-container {
    background-color: #f8f8f8;
    border-radius: 8px;
    padding: 1rem;
    margin-top: 1rem;
    border-left: 4px solid;
    display: none;
}

.feedback-container.correct {
    border-left-color: #4caf50;
    background-color: #e8f5e9;
}

.feedback-container.incorrect {
    border-left-color: #f44336;
    background-color: #ffebee;
}

.next-button {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 30px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: bold;
    margin-top: 1rem;
    align-self: flex-end;
}

.next-button:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

/* Results Screen */
.results-screen {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.results-title {
    color: var(--primary-dark);
    margin-bottom: 1.5rem;
}

.results-score {
    font-size: 2rem;
    margin: 1.5rem 0;
    color: var(--primary);
    font-weight: bold;
}

.results-message {
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.restart-button {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 30px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: bold;
    margin-top: 1rem;
}

.restart-button:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

.credits {
    margin-top: 2rem;
    font-size: 0.9rem;
    color: #666;
}

footer {
    background-color: var(--primary-dark);
    color: var(--text-light);
    text-align: center;
    padding: 1rem;
    margin-top: 2rem;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

@keyframes scorePulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); color: var(--accent); }
    100% { transform: scale(1); }
}

.score-pulse {
    animation: scorePulse 0.5s ease;
}

/* Responsive Design */
@media (max-width: 768px) {
    .game-content {
        grid-template-columns: 1fr;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    .game-header {
        flex-direction: column;
        gap: 1rem;
    }
    
    main {
        padding: 1rem;
    }
}

.debug-borders section {
    border: 3px solid transparent;
}

.debug-borders #welcomeScreen {
    border-color: blue;
}

.debug-borders #gameContainer {
    border-color: green;
}

.debug-borders #resultsScreen {
    border-color: red;
}
