/* ==========================================================
   SOF Olympiad Platform - Custom & OMR Simulator Styles
   ========================================================== */

/* Modern Font and Body Smoothing */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #0f172a;
    --accent: #f59e0b;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
}

.font-mono {
    font-family: 'JetBrains Mono', monospace;
}

/* Glassmorphism & Custom Shadows */
.glass-nav {
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.glass-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(241, 245, 249, 1);
}

.card-hover {
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.03);
}

/* ==========================================================
   REALISTIC OMR BUBBLE SHEET STYLES
   ========================================================== */

.omr-sheet-container {
    background: #ffffff;
    border: 2px solid #334155;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    font-family: 'JetBrains Mono', 'Plus Jakarta Sans', sans-serif;
    user-select: none;
}

.omr-header-bar {
    background: #0f172a;
    color: #ffffff;
    border-bottom: 2px solid #0f172a;
}

.omr-row {
    display: flex;
    align-items: center;
    padding: 6px 10px;
    border-bottom: 1px dashed #e2e8f0;
    transition: background 0.15s ease;
}

.omr-row:hover {
    background-color: #f8fafc;
}

.omr-row.active-question {
    background-color: #eff6ff !important;
    border-left: 4px solid #2563eb;
}

.omr-qnum {
    width: 32px;
    font-weight: 700;
    font-size: 0.85rem;
    color: #475569;
    text-align: right;
    margin-right: 12px;
}

.omr-bubbles-group {
    display: flex;
    gap: 8px;
}

.omr-bubble {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid #475569;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.75rem;
    color: #475569;
    cursor: pointer;
    background: #ffffff;
    transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.omr-bubble:hover {
    border-color: #1e293b;
    background-color: #e2e8f0;
}

/* Realistic Dark Pen-Inked Bubble Effect */
.omr-bubble.filled {
    background: radial-gradient(circle, #0f172a 75%, #1e293b 100%) !important;
    border-color: #020617 !important;
    color: #ffffff !important;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.5), 0 1px 2px rgba(0, 0, 0, 0.3);
    transform: scale(0.96);
}

.omr-bubble.filled::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.2);
    filter: blur(1px);
}

/* Question Palette in CBT Mode */
.palette-btn {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.85rem;
    transition: all 0.15s ease;
}

.palette-btn.current {
    ring: 3px;
    ring-offset: 2px;
    --tw-ring-color: #2563eb;
}

.status-answered {
    background-color: #10b981;
    color: #ffffff;
}

.status-marked {
    background-color: #8b5cf6;
    color: #ffffff;
}

.status-unanswered {
    background-color: #f43f5e;
    color: #ffffff;
}

.status-unvisited {
    background-color: #f1f5f9;
    color: #475569;
    border: 1px solid #cbd5e1;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Math Rendering Container Tweaks */
.katex-display {
    margin: 0.75em 0 !important;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 4px 0;
}

/* Print Mode for Printable Offline Mock Papers */
@media print {
    .no-print, header, footer, .dashboard-sidebar, .test-controls {
        display: none !important;
    }
    .print-only {
        display: block !important;
    }
    body {
        background: #ffffff !important;
        color: #000000 !important;
    }
    .omr-sheet-container {
        border: 1px solid #000000 !important;
        box-shadow: none !important;
    }
}
