* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #4a90e2, #357abd);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    transition: background 0.8s ease;
}

body.correct {
    background: linear-gradient(135deg, #4caf50, #45a049);
}

body.incorrect {
    background: linear-gradient(135deg, #f44336, #d32f2f);
}

.background-decorations {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    opacity: 0.1;
}

.flag, .monument {
    position: absolute;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    animation: float 6s ease-in-out infinite;
}

.flag {
    width: 60px;
    height: 40px;
}

.monument {
    width: 80px;
    height: 80px;
    object-fit: cover;
}

.flag-1 { top: 10%; left: 5%; animation-delay: 0s; }
.flag-2 { top: 20%; right: 8%; animation-delay: 1s; }
.flag-3 { top: 60%; left: 3%; animation-delay: 2s; }
.flag-4 { top: 70%; right: 5%; animation-delay: 3s; }
.flag-5 { top: 40%; left: 2%; animation-delay: 4s; }
.flag-6 { top: 85%; right: 12%; animation-delay: 5s; }

.monument-1 { top: 15%; right: 15%; animation-delay: 0.5s; }
.monument-2 { top: 50%; right: 10%; animation-delay: 1.5s; }
.monument-3 { top: 80%; left: 10%; animation-delay: 2.5s; }
.monument-4 { top: 30%; left: 8%; animation-delay: 3.5s; }

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(2deg); }
}

header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    position: relative;
    z-index: 10;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    flex-wrap: wrap;
}

.logo {
    height: 80px;
    width: auto;
}

.title-section {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.title-image {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #4a90e2;
}

h1 {
    color: #2c3e50;
    font-size: 2.5rem;
    font-weight: bold;
    text-align: center;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.website-link {
    text-align: center;
    margin-top: 15px;
}

.website-link a {
    color: #4a90e2;
    text-decoration: none;
    font-size: 1.2rem;
    font-weight: bold;
    transition: color 0.3s ease;
}

.website-link a:hover {
    color: #357abd;
    text-decoration: underline;
}

main {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 20px;
    position: relative;
    z-index: 10;
}

.exercise-container {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    backdrop-filter: blur(10px);
    margin-bottom: 30px;
}

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e0e0e0;
}

.question-header h2 {
    color: #2c3e50;
    font-size: 1.5rem;
}

.score {
    background: #4a90e2;
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: bold;
}

.question-content {
    margin-bottom: 30px;
    text-align: center;
}

.instruction {
    font-size: 1.2rem;
    color: #555;
    margin-bottom: 20px;
}

.error-sentence {
    background: #ffebee;
    border: 2px solid #f44336;
    border-radius: 10px;
    padding: 20px;
    font-size: 1.5rem;
    font-weight: bold;
    color: #d32f2f;
    display: inline-block;
    min-width: 200px;
}

.answer-section {
    margin-bottom: 30px;
}

#user-answer {
    width: 100%;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 10px;
    font-size: 1.1rem;
    resize: vertical;
    min-height: 80px;
    transition: border-color 0.3s ease;
}

#user-answer:focus {
    outline: none;
    border-color: #4a90e2;
    box-shadow: 0 0 10px rgba(74, 144, 226, 0.3);
}

.submit-btn, .next-btn, .retry-btn, .nav-btn, .restart-btn {
    background: #4a90e2;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 5px;
}

.submit-btn:hover, .next-btn:hover, .retry-btn:hover, .nav-btn:hover:not(:disabled), .restart-btn:hover {
    background: #357abd;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.nav-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.feedback-section {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    margin-top: 20px;
    border-left: 5px solid #4a90e2;
}

.feedback-section.correct {
    background: #e8f5e8;
    border-left-color: #4caf50;
}

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

.feedback-content h3 {
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.feedback-content h3.correct {
    color: #4caf50;
}

.feedback-content h3.incorrect {
    color: #f44336;
}

.correct-answers {
    background: #e3f2fd;
    border-radius: 8px;
    padding: 15px;
    margin: 15px 0;
    border-left: 4px solid #2196f3;
}

.correct-answers h4 {
    color: #1976d2;
    margin-bottom: 10px;
}

.correct-answers ul {
    list-style: none;
    padding-left: 0;
}

.correct-answers li {
    background: white;
    margin: 5px 0;
    padding: 8px 12px;
    border-radius: 5px;
    border-left: 3px solid #4caf50;
}

.navigation-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.question-indicators {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.indicator {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.indicator.current {
    background: #4a90e2;
    color: white;
    transform: scale(1.2);
}

.indicator.answered {
    background: #4caf50;
    color: white;
}

.indicator:hover {
    transform: scale(1.1);
}

.results-section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    text-align: center;
}

.results-section h2 {
    color: #2c3e50;
    margin-bottom: 30px;
    font-size: 2rem;
}

.final-score {
    background: #e3f2fd;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    border: 2px solid #2196f3;
}

.final-score p {
    font-size: 1.3rem;
    margin: 10px 0;
    color: #1976d2;
    font-weight: bold;
}

.results-summary {
    text-align: left;
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 30px;
}

.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
}

.result-item:last-child {
    border-bottom: none;
}

.result-item.correct {
    background: #e8f5e8;
    border-radius: 5px;
    padding: 10px;
    margin: 5px 0;
}

.result-item.incorrect {
    background: #ffebee;
    border-radius: 5px;
    padding: 10px;
    margin: 5px 0;
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 15px;
    }
    
    h1 {
        font-size: 1.8rem;
    }
    
    .title-section {
        flex-direction: column;
        text-align: center;
    }
    
    .exercise-container {
        padding: 20px;
        margin: 20px 10px;
    }
    
    .question-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .navigation-section {
        flex-direction: column;
        gap: 15px;
    }
    
    .flag, .monument {
        width: 40px;
        height: 30px;
    }
    
    .monument {
        width: 50px;
        height: 50px;
    }
}

