/**
 * ONNRC Platform - Main Stylesheet
 * Online Neuroscience Network Research Center
 */

/* Custom Properties */
:root {
    --onnrc-primary: #0d47a1;
    --onnrc-secondary: #1976d2;
    --onnrc-accent: #2196f3;
    --onnrc-dark: #1a237e;
    --onnrc-light: #e3f2fd;
    --onnrc-success: #4caf50;
    --onnrc-warning: #ff9800;
    --onnrc-danger: #f44336;
}

/* Base Styles */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    color: #1a237e;
}

/* Links */
a {
    color: var(--onnrc-primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--onnrc-dark);
}

/* Cards */
.card {
    border: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.card-header {
    background: linear-gradient(135deg, var(--onnrc-primary), var(--onnrc-secondary));
    color: white;
    font-weight: 600;
    border-radius: 12px 12px 0 0 !important;
    border: none;
}

/* Buttons */
.btn-primary {
    background: linear-gradient(135deg, var(--onnrc-primary), var(--onnrc-secondary));
    border: none;
    border-radius: 8px;
    padding: 10px 24px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--onnrc-dark), var(--onnrc-primary));
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(13, 71, 161, 0.3);
}

/* Forms */
.form-control, .form-select {
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    padding: 12px 16px;
}

.form-control:focus, .form-select:focus {
    border-color: var(--onnrc-accent);
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

/* Alerts */
.alert {
    border-radius: 10px;
    border: none;
}

/* Badges */
.badge {
    border-radius: 6px;
    font-weight: 500;
    padding: 6px 12px;
}

/* Tables */
.table {
    border-radius: 8px;
    overflow: hidden;
}

.table thead th {
    background: var(--onnrc-light);
    border-bottom: 2px solid var(--onnrc-primary);
    font-weight: 600;
}

/* Sidebar */
.sidebar {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.sidebar .nav-link {
    color: #555;
    border-radius: 8px;
    padding: 10px 15px;
    margin-bottom: 5px;
    transition: all 0.2s ease;
}

.sidebar .nav-link:hover {
    background: var(--onnrc-light);
    color: var(--onnrc-primary);
}

.sidebar .nav-link.active {
    background: var(--onnrc-primary);
    color: white;
}

/* Article Content */
.article-content {
    font-size: 1.1rem;
    line-height: 1.8;
}

.article-content h2 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.article-content h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

.article-content p {
    margin-bottom: 1.25rem;
}

.article-content ul, .article-content ol {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}

.article-content blockquote {
    border-left: 4px solid var(--onnrc-primary);
    padding-left: 1rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #666;
}

/* Preprint Styles */
.preprint .article-content {
    font-size: 1rem;
}

/* Footer */
footer {
    background: var(--onnrc-dark);
}

footer a {
    color: rgba(255, 255, 255, 0.7);
}

footer a:hover {
    color: white;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.3s ease;
}

/* Responsive */
@media (max-width: 768px) {
    .display-4 {
        font-size: 2rem;
    }
    
    .display-5 {
        font-size: 1.75rem;
    }
    
    .sidebar {
        margin-bottom: 1.5rem;
    }
}

/* Loading Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--onnrc-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Print Styles */
@media print {
    .navbar, .sidebar, footer, .btn {
        display: none !important;
    }
    
    .card {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}
