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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 40px;
    color: white;
}

header h1 {
    font-size: 3em;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

header p {
    font-size: 1.2em;
    opacity: 0.9;
}

.section {
    background: white;
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.section:hover {
    transform: translateY(-2px);
}

.section h2 {
    margin-bottom: 20px;
    color: #4a5568;
    font-size: 1.5em;
}

.input-group {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 10px;
}

input[type="password"], input[type="text"], select {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

input[type="password"]:focus, input[type="text"]:focus, select:focus {
    outline: none;
    border-color: #667eea;
}

button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.help-text {
    font-size: 14px;
    color: #718096;
    margin-top: 10px;
}

.help-text a {
    color: #667eea;
    text-decoration: none;
}

.upload-area {
    border: 3px dashed #cbd5e0;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 20px;
}

.upload-area:hover, .upload-area.dragover {
    border-color: #667eea;
    background-color: #f7fafc;
}

.upload-content {
    pointer-events: none;
}

.upload-icon {
    font-size: 4em;
    margin-bottom: 15px;
}

.upload-area p {
    font-size: 1.1em;
    color: #4a5568;
}

.file-list {
    display: grid;
    gap: 15px;
}

.file-item {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.file-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.file-icon {
    font-size: 1.5em;
}

.file-name {
    font-weight: 600;
    color: #2d3748;
}

.file-size {
    color: #718096;
    font-size: 0.9em;
}

.file-actions {
    display: flex;
    gap: 10px;
}

.btn-small {
    padding: 6px 12px;
    font-size: 14px;
}

.btn-danger {
    background: linear-gradient(135deg, #fc8181 0%, #f56565 100%);
}

.btn-refresh {
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
    margin-bottom: 20px;
}

.btn-refresh:hover {
    box-shadow: 0 5px 15px rgba(72, 187, 120, 0.4);
}

.file-item.selectable {
    cursor: pointer;
    transition: all 0.3s ease;
}

.file-item.selectable:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.file-item.selected {
    border: 2px solid #667eea;
    background: #ebf8ff;
}

.file-checkbox {
    margin-right: 10px;
    transform: scale(1.2);
}

.quiz-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.option-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.option-group label {
    font-weight: 600;
    color: #4a5568;
}

.loading {
    text-align: center;
    padding: 60px 30px;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #e2e8f0;
    border-top: 5px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.quiz-question {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 25px;
    border-left: 4px solid #667eea;
}

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.question-number {
    background: #667eea;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9em;
}

.question-type {
    background: #e2e8f0;
    color: #4a5568;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 600;
}

.question-text {
    font-size: 1.1em;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 20px;
    line-height: 1.6;
}

.answer-options {
    display: grid;
    gap: 10px;
}

.answer-option {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.answer-option:hover {
    border-color: #667eea;
    background-color: #f7fafc;
}

.answer-option.selected {
    border-color: #667eea;
    background-color: #ebf8ff;
}

.answer-option.correct {
    border-color: #48bb78;
    background-color: #f0fff4;
}

.answer-option.incorrect {
    border-color: #f56565;
    background-color: #fef5e7;
}

.text-answer {
    width: 100%;
    min-height: 100px;
    padding: 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    resize: vertical;
    font-family: inherit;
}

.text-answer:focus {
    outline: none;
    border-color: #667eea;
}

.quiz-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 40px;
}

.score-display {
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
    color: white;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 20px;
}

.score-display h3 {
    font-size: 1.5em;
    margin-bottom: 10px;
}

.score-breakdown {
    text-align: left;
}

.score-breakdown p {
    margin-bottom: 8px;
    font-size: 1.1em;
}

.sample-answer {
    margin-top: 15px;
    background: #e6fffa;
    border: 2px solid #38b2ac;
    border-radius: 8px;
    padding: 15px;
}

.sample-answer-header {
    font-weight: 600;
    color: #234e52;
    margin-bottom: 10px;
    font-size: 1.1em;
}

.sample-answer-content {
    color: #2c7a7b;
    line-height: 1.6;
    font-size: 1rem;
}

.error-message {
    background: #fed7d7;
    color: #c53030;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #f56565;
}

.success-message {
    background: #c6f6d5;
    color: #276749;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #48bb78;
}

.info-message {
    background: #bee3f8;
    color: #2c5282;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #3182ce;
}

.no-files {
    text-align: center;
    color: #718096;
    font-style: italic;
    padding: 40px 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 2px dashed #cbd5e0;
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2em;
    }
    
    .section {
        padding: 20px;
    }
    
    .quiz-options {
        grid-template-columns: 1fr;
    }
    
    .input-group {
        flex-direction: column;
        align-items: stretch;
    }
    
    .quiz-actions {
        flex-direction: column;
    }
} 