/* Assignments Static CSS */

/* General Assignment Styles */
.assignment-container {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    margin: 20px 0;
}

.assignment-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px;
}

.assignment-timer {
    background: #fff3cd;
    border: 2px solid #ffc107;
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    margin-bottom: 20px;
    font-size: 1.2em;
    font-weight: bold;
}

.assignment-timer.warning {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.8; }
    100% { opacity: 1; }
}

/* Ordering Assignment Styles */
.ordering-container {
    min-height: 400px;
    padding: 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.ordering-item {
    background: white;
    border: 3px solid #e3e6ea;
    border-radius: 12px;
    padding: 20px;
    margin: 15px 0;
    cursor: move;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    overflow: hidden;
    user-select: none;
}

.ordering-item:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 4px;
    background: linear-gradient(to bottom, #007bff, #0056b3);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.ordering-item:hover:before {
    transform: scaleY(1);
}

.ordering-item:hover {
    border-color: #007bff;
    box-shadow: 0 8px 25px rgba(0,123,255,0.15);
    transform: translateY(-2px);
}

.ordering-item.dragging {
    opacity: 0.7;
    transform: scale(1.02);
    z-index: 1000;
    box-shadow: 0 15px 30px rgba(0,0,0,0.3);
    cursor: grabbing !important;
    border-color: #007bff;
    background: #f8f9fa;
}

.ordering-item.drag-over {
    border-color: #28a745 !important;
    background: #d4edda !important;
    border-style: dashed;
    transform: scale(1.02);
}
    border-style: dashed;
    transform: scale(1.02);
}

.drag-handle {
    color: #6c757d;
    font-size: 1.5em;
    cursor: grab;
    transition: color 0.3s;
    padding: 5px;
}

.ordering-item:hover .drag-handle {
    color: #007bff;
}

.ordering-item:active .drag-handle,
.ordering-item.dragging .drag-handle {
    cursor: grabbing;
}

.sortable-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
    min-height: 200px;
}

.drop-placeholder {
    background: #e3f2fd;
    border: 3px dashed #2196f3;
    height: 80px;
    margin: 15px 0;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2196f3;
    font-weight: bold;
    font-size: 14px;
}

.sortable-placeholder {
    background: #f8f9fa !important;
    border: 2px dashed #6c757d !important;
    height: 60px !important;
    margin: 15px 0 !important;
    border-radius: 8px !important;
    visibility: visible !important;
}

/* Mosaic Assignment Styles */
.mosaic-playground {
    background: #f8f9fa;
    border-radius: 16px;
    padding: 30px;
    margin: 20px 0;
}

.mosaic-grid {
    background: #333;
    border-radius: 12px;
    padding: 8px;
    margin: 0 auto;
    box-shadow: inset 0 4px 8px rgba(0,0,0,0.3);
}

.mosaic-cell {
    background: #f0f0f0;
    border: 2px dashed #bbb;
    border-radius: 6px;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.mosaic-cell.drag-over {
    background: #e3f2fd;
    border-color: #2196f3;
    border-style: solid;
    box-shadow: inset 0 0 10px rgba(33,150,243,0.3);
}

.mosaic-cell.filled {
    border: none;
    background: transparent;
}

.mosaic-piece {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
    cursor: grab;
    transition: all 0.3s;
}

.mosaic-piece:hover {
    filter: brightness(1.1);
    transform: scale(1.02);
}

.mosaic-piece.dragging {
    opacity: 0.7;
    transform: rotate(2deg) scale(0.95);
    z-index: 1000;
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

.pieces-container {
    background: white;
    border: 3px solid #dee2e6;
    border-radius: 16px;
    padding: 25px;
    margin: 30px 0;
    min-height: 180px;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
}

.pieces-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    align-items: center;
}

.piece-slot {
    width: 90px;
    height: 90px;
    border: 3px solid #e9ecef;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s;
    cursor: grab;
    position: relative;
}

.piece-slot:hover {
    border-color: #007bff;
    box-shadow: 0 4px 12px rgba(0,123,255,0.2);
    transform: scale(1.05);
}

.piece-slot.empty {
    border-style: dashed;
    background: #f8f9fa;
}

/* Quiz Assignment Styles */
.quiz-progress {
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.question-card {
    background: white;
    border: 1px solid #e3e6ea;
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.question-card:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2);
}

.question-card:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.question-number {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.1em;
    box-shadow: 0 4px 8px rgba(102,126,234,0.3);
}

.answer-option {
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    margin: 12px 0;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    background: white;
}

.answer-option:hover {
    border-color: #007bff;
    background: rgba(0,123,255,0.05);
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(0,123,255,0.15);
}

.answer-option.selected {
    border-color: #28a745;
    background: rgba(40,167,69,0.1);
    box-shadow: 0 4px 12px rgba(40,167,69,0.15);
}

.answer-option.selected:before {
    content: '✓';
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #28a745;
    font-weight: bold;
    font-size: 1.2em;
}

.true-false-options {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 25px;
}

.true-false-option {
    flex: 1;
    max-width: 250px;
    text-align: center;
    padding: 30px 20px;
    border: 3px solid #e9ecef;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.3s;
    background: white;
    position: relative;
    overflow: hidden;
}

.true-false-option:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, transparent 0%, transparent 100%);
    transition: all 0.3s;
    opacity: 0;
}

.true-false-option:hover:before {
    opacity: 0.1;
}

.true-false-option:hover {
    border-color: #007bff;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,123,255,0.2);
}

.true-false-option.selected {
    border-color: #28a745;
    background: rgba(40,167,69,0.05);
    box-shadow: 0 8px 20px rgba(40,167,69,0.2);
}

.true-false-option .icon {
    font-size: 2.5em;
    margin-bottom: 15px;
    transition: transform 0.3s;
}

.true-false-option:hover .icon {
    transform: scale(1.1);
}

/* Assignment Results */
.result-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    overflow: hidden;
    margin: 20px 0;
}

.result-header {
    padding: 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-align: center;
}

.result-score {
    font-size: 3em;
    font-weight: bold;
    margin: 10px 0;
}

.result-status.passed {
    background: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    display: inline-block;
    font-weight: bold;
}

.result-status.failed {
    background: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    display: inline-block;
    font-weight: bold;
}

/* Assignment Controls */
.assignment-controls {
    background: white;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    position: sticky;
    bottom: 20px;
    z-index: 100;
    margin: 30px 0;
}

.submit-button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
    padding: 15px 40px;
    font-size: 1.1em;
    font-weight: bold;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(102,126,234,0.3);
}

.submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102,126,234,0.4);
}

.submit-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    .assignment-container {
        padding: 15px;
        margin: 10px 0;
    }
    
    .question-card {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .true-false-options {
        flex-direction: column;
        gap: 15px;
    }
    
    .true-false-option {
        max-width: none;
        padding: 20px;
    }
    
    .ordering-item {
        padding: 15px;
        margin: 10px 0;
    }
    
    .pieces-grid {
        gap: 10px;
    }
    
    .piece-slot {
        width: 70px;
        height: 70px;
    }
    
    .mosaic-grid {
        padding: 4px;
    }
    
    .assignment-controls {
        padding: 20px;
        position: static;
        margin: 20px 0;
    }
}