/* SIKAMITRA - Exam & Extra Styles */

/* Exam Layout */
.exam-layout { display: grid; grid-template-columns: 1fr 280px; gap: 1.5rem; min-height: calc(100vh - 80px); }
.exam-question-area { background: #fff; border-radius: 0.75rem; padding: 2rem; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }
.exam-sidebar { position: sticky; top: 80px; height: fit-content; }
.exam-timer { background: #2d3748; color: #fff; border-radius: 0.75rem; padding: 1rem; text-align: center; margin-bottom: 1rem; }
.exam-timer .timer-value { font-size: 2rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.exam-timer .timer-label { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 1px; opacity: 0.7; }
.exam-timer.warning { background: #dc4a5a; animation: pulse 1s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.85; } }

/* Question Navigation */
.question-nav { background: #fff; border-radius: 0.75rem; padding: 1rem; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }
.question-nav-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0.4rem; }
.q-nav-btn { width: 100%; aspect-ratio: 1; border: 2px solid #e2e8f0; border-radius: 0.5rem; background: #fff; font-size: 0.78rem; font-weight: 600; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; justify-content: center; }
.q-nav-btn:hover { border-color: #4a6fa5; }
.q-nav-btn.active { border-color: #4a6fa5; background: #4a6fa5; color: #fff; }
.q-nav-btn.answered { background: #28a770; border-color: #28a770; color: #fff; }
.q-nav-btn.flagged { background: #e8a838; border-color: #e8a838; color: #fff; }
.question-legend { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 0.75rem; font-size: 0.72rem; }
.legend-item { display: flex; align-items: center; gap: 0.35rem; }
.legend-dot { width: 12px; height: 12px; border-radius: 3px; }
.legend-dot.unanswered { border: 2px solid #e2e8f0; }
.legend-dot.answered { background: #28a770; }
.legend-dot.flagged { background: #e8a838; }

/* Options */
.option-item { display: flex; align-items: flex-start; gap: 0.75rem; padding: 0.75rem 1rem; border: 2px solid #e2e8f0; border-radius: 0.5rem; margin-bottom: 0.5rem; cursor: pointer; transition: all 0.2s; }
.option-item:hover { border-color: #6b8fc5; background: #f8fafc; }
.option-item.selected { border-color: #4a6fa5; background: rgba(74,111,165,0.08); }
.option-item input[type="radio"] { margin-top: 2px; accent-color: #4a6fa5; }
.option-label { font-weight: 600; min-width: 24px; color: #4a6fa5; }

/* Document Preview */
.doc-preview-container { border: 1px solid #e2e8f0; border-radius: 0.5rem; overflow: hidden; margin-bottom: 1rem; }
.doc-preview-container img { width: 100%; max-height: 400px; object-fit: contain; background: #f8f9fa; }
.doc-preview-container iframe { width: 100%; height: 400px; border: none; }

/* Selection Steps */
.selection-steps { display: flex; justify-content: center; gap: 0; margin-bottom: 1.5rem; }
.step-item { display: flex; align-items: center; gap: 0.5rem; }
.step-circle { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 0.85rem; border: 3px solid #e2e8f0; background: #fff; color: #94a3b8; }
.step-circle.active { border-color: #4a6fa5; background: #4a6fa5; color: #fff; }
.step-circle.completed { border-color: #28a770; background: #28a770; color: #fff; }
.step-circle.failed { border-color: #dc4a5a; background: #dc4a5a; color: #fff; }
.step-label { font-size: 0.78rem; font-weight: 500; color: #94a3b8; }
.step-label.active { color: #4a6fa5; font-weight: 600; }
.step-label.completed { color: #28a770; }
.step-connector { width: 60px; height: 3px; background: #e2e8f0; margin: 0 0.5rem; align-self: center; margin-bottom: 18px; }
.step-connector.completed { background: #28a770; }

/* Auth */
.auth-wrapper { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #e8ecf1 0%, #f7f8fc 100%); padding: 1rem; }
.auth-card { width: 100%; max-width: 420px; background: #fff; border-radius: 0.75rem; box-shadow: 0 10px 15px rgba(0,0,0,0.1); padding: 2.5rem; }
.auth-card .auth-logo { text-align: center; margin-bottom: 2rem; }
.auth-card .auth-logo h4 { font-weight: 700; color: #2d3748; margin-bottom: 0.25rem; }
.auth-card .auth-logo p { color: #94a3b8; font-size: 0.82rem; }

/* Toast */
.toast-container { position: fixed; top: 1rem; right: 1rem; z-index: 9999; }

/* Loading */
.loading-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(255,255,255,0.8); display: none; align-items: center; justify-content: center; z-index: 9998; }
.loading-overlay.active { display: flex; }

/* Mobile Toggle */
.sidebar-toggle { display: none; background: none; border: none; font-size: 1.25rem; color: #2d3748; cursor: pointer; }
.sidebar-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); z-index: 1035; }

/* Animations */
.fade-in { animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* Responsive */
@media (max-width: 991.98px) {
    .sidebar { transform: translateX(-100%); }
    .sidebar.show { transform: translateX(0); }
    .sidebar-overlay.show { display: block; }
    .sidebar-toggle { display: block; }
    .main-content { margin-left: 0; }
    .content-wrapper { padding: 1rem; }
    .exam-layout { grid-template-columns: 1fr; }
    .exam-sidebar { position: fixed; bottom: 0; left: 0; right: 0; z-index: 1020; display: flex; gap: 0.5rem; padding: 0.75rem; background: #fff; box-shadow: 0 -2px 10px rgba(0,0,0,0.1); border-radius: 0.75rem 0.75rem 0 0; }
    .exam-timer { margin-bottom: 0; padding: 0.5rem 1rem; display: flex; align-items: center; gap: 0.5rem; }
    .exam-timer .timer-value { font-size: 1.25rem; }
    .exam-timer .timer-label { display: none; }
    .question-nav { flex: 1; padding: 0.5rem; overflow-x: auto; }
    .question-nav-grid { display: flex; gap: 0.3rem; flex-wrap: nowrap; }
    .q-nav-btn { min-width: 36px; min-height: 36px; }
    .question-legend { display: none; }
    .exam-question-area { padding: 1rem; margin-bottom: 100px; }
}
@media (max-width: 575.98px) {
    .stat-card .stat-value { font-size: 1.35rem; }
    .selection-steps { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
    .step-connector { width: 3px; height: 20px; margin: 0 0 0 18px; }
}
@media print { .sidebar, .top-bar, .sidebar-toggle, .btn { display: none !important; } .main-content { margin-left: 0 !important; } }
