/* Interactive Learning Features Styles */

/* Bookmarks Section */
.bookmarks-section {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin: 15px 0;
    border: 1px solid #e9ecef;
}

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

.bookmark-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9em;
    transition: all 0.3s ease;
}

.bookmark-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.bookmark-btn.bookmarked {
    background: linear-gradient(135deg, #f093fb, #f5576c);
}

.bookmark-item {
    background: white;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
}

.bookmark-item:hover {
    background: #f8f9fa;
    transform: translateX(-3px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.bookmark-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.bookmark-title {
    font-weight: 600;
    color: #333;
}

.remove-bookmark {
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    cursor: pointer;
    font-size: 12px;
}

.bookmark-note {
    margin: 8px 0;
    font-size: 0.9em;
    color: #666;
    font-style: italic;
}

.bookmark-date {
    font-size: 0.8em;
    color: #999;
}

.no-bookmarks {
    text-align: center;
    color: #999;
    font-style: italic;
    padding: 20px;
}

/* Notes Section */
.notes-section {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    padding: 15px;
    margin: 15px 0;
}

.notes-input-area {
    margin-bottom: 15px;
}

.note-textarea {
    width: 100%;
    min-height: 80px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: inherit;
    resize: vertical;
}

.add-note-btn {
    background: #28a745;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 8px;
}

.note-item {
    background: white;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 10px;
    border: 1px solid #e9ecef;
}

.note-content {
    margin-bottom: 8px;
    line-height: 1.5;
}

.note-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8em;
    color: #666;
}

.delete-note {
    background: #dc3545;
    color: white;
    border: none;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8em;
}

.no-notes {
    text-align: center;
    color: #999;
    font-style: italic;
    padding: 20px;
}

/* Quiz Section */
.quiz-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    border-radius: 12px;
    margin: 20px 0;
}

.quiz-container {
    margin: 20px 0;
}

.quiz-question {
    background: rgba(255,255,255,0.1);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    backdrop-filter: blur(10px);
}

.quiz-question h4 {
    margin-bottom: 15px;
    color: white;
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.quiz-option {
    display: flex;
    align-items: center;
    padding: 10px;
    background: rgba(255,255,255,0.1);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.quiz-option:hover {
    background: rgba(255,255,255,0.2);
    transform: translateX(-3px);
}

.quiz-option input[type="radio"] {
    margin-left: 10px;
    transform: scale(1.2);
}

.submit-quiz-btn {
    background: #28a745;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 1em;
    font-weight: 600;
    transition: all 0.3s ease;
}

.submit-quiz-btn:hover {
    background: #218838;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.quiz-results {
    margin-top: 20px;
}

.quiz-score {
    text-align: center;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.quiz-excellent {
    background: rgba(40, 167, 69, 0.2);
    border: 2px solid #28a745;
}

.quiz-good {
    background: rgba(255, 193, 7, 0.2);
    border: 2px solid #ffc107;
}

.quiz-poor {
    background: rgba(220, 53, 69, 0.2);
    border: 2px solid #dc3545;
}

.quiz-explanations {
    margin-top: 15px;
}

.quiz-explanation {
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 10px;
}

.quiz-explanation.correct {
    background: rgba(40, 167, 69, 0.1);
    border-left: 4px solid #28a745;
}

.quiz-explanation.incorrect {
    background: rgba(220, 53, 69, 0.1);
    border-left: 4px solid #dc3545;
}

/* Code Challenge Section */
.code-challenge-section {
    background: #2d3748;
    color: white;
    padding: 20px;
    border-radius: 12px;
    margin: 20px 0;
}

.code-challenge {
    background: rgba(255,255,255,0.05);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.code-challenge h4 {
    color: #4fd1c7;
    margin-bottom: 10px;
}

.challenge-code-area {
    margin: 15px 0;
}

.challenge-textarea {
    width: 100%;
    background: #1a202c;
    color: #e2e8f0;
    border: 1px solid #4a5568;
    border-radius: 6px;
    padding: 15px;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    line-height: 1.5;
    resize: vertical;
}

.challenge-actions {
    display: flex;
    gap: 10px;
    margin: 15px 0;
    flex-wrap: wrap;
}

.challenge-actions button {
    padding: 8px 15px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.challenge-actions button:first-child {
    background: #48bb78;
    color: white;
}

.challenge-actions button:nth-child(2) {
    background: #ed8936;
    color: white;
}

.challenge-actions button:last-child {
    background: #667eea;
    color: white;
}

.challenge-actions button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.challenge-output {
    margin-top: 15px;
}

.code-output {
    background: #1a202c;
    border: 1px solid #4a5568;
    border-radius: 6px;
    padding: 15px;
}

.code-output h5 {
    color: #4fd1c7;
    margin-bottom: 10px;
}

.code-output pre {
    color: #e2e8f0;
    font-family: 'Courier New', monospace;
    white-space: pre-wrap;
    margin: 0;
}

.challenge-hints {
    background: rgba(237, 137, 54, 0.1);
    border: 1px solid #ed8936;
    border-radius: 6px;
    padding: 15px;
    margin-top: 15px;
}

.hints-content h5 {
    color: #ed8936;
    margin-bottom: 10px;
}

.hints-content ul {
    margin: 0;
    padding-right: 20px;
}

.hints-content li {
    margin-bottom: 5px;
    color: #e2e8f0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .quiz-options {
        gap: 8px;
    }
    
    .challenge-actions {
        flex-direction: column;
    }
    
    .challenge-actions button {
        width: 100%;
    }
    
    .bookmark-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}
