/* AlSadiq Seminar Registration System - Main Styles */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --light-color: #f8f9fa;
    --dark-color: #212529;
}

/* Global Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
}

/* Urdu Font */
.urdu, [lang="ur"] {
    font-family: 'Noto Nastaliq Urdu', serif;
    font-size: 1.1em;
    line-height: 1.8;
}

/* Urdu specific styling */
[dir="rtl"] {
    font-family: 'Noto Nastaliq Urdu', serif;
}

[dir="rtl"] .navbar-brand,
[dir="rtl"] .nav-link,
[dir="rtl"] .dropdown-item {
    font-family: 'Noto Nastaliq Urdu', serif;
    font-size: 1.1em;
}

[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, 
[dir="rtl"] h4, [dir="rtl"] h5, [dir="rtl"] h6 {
    font-family: 'Noto Nastaliq Urdu', serif;
    line-height: 1.6;
}

[dir="rtl"] p, [dir="rtl"] span, [dir="rtl"] div {
    font-family: 'Noto Nastaliq Urdu', serif;
    line-height: 1.8;
}

/* Navigation Improvements */
.navbar {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.navbar-brand {
    font-weight: 600;
}

.dropdown-menu {
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    min-width: 200px;
}

.dropdown-menu-end {
    --bs-position: end;
}

.dropdown-item {
    padding: 0.5rem 1rem;
    transition: background-color 0.15s ease-in-out;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
}

.dropdown-item.active {
    background-color: var(--primary-color);
    color: white;
}

.dropdown-item.active:hover {
    background-color: var(--primary-color);
    color: white;
}

/* Responsive Navigation */
@media (max-width: 576px) {
    .navbar-brand {
        font-size: 1rem;
    }
    
    .nav-link {
        padding: 0.5rem 0.75rem;
    }
    
    .dropdown-menu {
        min-width: 180px;
    }
}

/* Main Content */
.main-content {
    min-height: calc(100vh - 200px);
}

/* Cards */
.card {
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    transition: box-shadow 0.15s ease-in-out;
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

/* Buttons */
.btn {
    border-radius: 0.375rem;
    font-weight: 500;
    transition: all 0.15s ease-in-out;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
}

/* Forms */
.form-control, .form-select {
    border-radius: 0.375rem;
    border: 1px solid #ced4da;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

/* Navigation */
.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
    color: #ffffff !important;
}

.navbar-nav .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem;
    color: #ffffff !important;
    opacity: 0.9;
    transition: opacity 0.15s ease-in-out;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus {
    color: #ffffff !important;
    opacity: 1;
}

.navbar-nav .nav-link.active {
    color: #ffffff !important;
    opacity: 1;
    font-weight: 600;
}

.dropdown-menu .dropdown-item {
    color: #212529;
    font-weight: 500;
}

.dropdown-menu .dropdown-item:hover {
    background-color: var(--primary-color);
    color: #ffffff;
}

/* Hero Section */
.display-4 {
    font-weight: 700;
    color: var(--dark-color);
}

.lead {
    font-size: 1.25rem;
    font-weight: 300;
}

/* Feature Cards */
.card-body i {
    color: var(--primary-color);
}

/* Tables */
.table {
    border-collapse: separate;
    border-spacing: 0;
}

.table th {
    background-color: var(--light-color);
    font-weight: 600;
    border-bottom: 2px solid #dee2e6;
}

/* Badges */
.badge {
    font-size: 0.875em;
    font-weight: 500;
}

/* Alerts */
.alert {
    border: none;
    border-radius: 0.5rem;
}

/* File Upload */
.file-upload-wrapper {
    position: relative;
    display: inline-block;
    cursor: pointer;
    width: 100%;
}

.file-upload-input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.file-upload-button {
    display: inline-block;
    padding: 0.5rem 1rem;
    background-color: var(--primary-color);
    color: white;
    border-radius: 0.375rem;
    text-align: center;
    width: 100%;
    transition: background-color 0.15s ease-in-out;
}

.file-upload-button:hover {
    background-color: #0b5ed7;
}

/* Photo Preview */
.photo-preview {
    max-width: 150px;
    max-height: 150px;
    border-radius: 0.5rem;
    border: 2px solid #dee2e6;
    object-fit: cover;
}

/* Barcode Scanner */
.barcode-scanner {
    background-color: #000;
    border-radius: 0.5rem;
    padding: 1rem;
    text-align: center;
}

.barcode-result {
    background-color: var(--light-color);
    border-radius: 0.5rem;
    padding: 1rem;
    margin-top: 1rem;
}

/* Dashboard Cards */
.dashboard-card {
    background: linear-gradient(135deg, var(--primary-color), #0b5ed7);
    color: white;
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    transition: transform 0.15s ease-in-out;
}

.dashboard-card:hover {
    transform: translateY(-5px);
}

.dashboard-card i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.8;
}

.dashboard-card h3 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .display-4 {
        font-size: 2rem;
    }
    
    .lead {
        font-size: 1.1rem;
    }
    
    .dashboard-card {
        padding: 1.5rem;
    }
    
    .dashboard-card h3 {
        font-size: 2rem;
    }
}

/* Print Styles */
@media print {
    .navbar, .footer, .btn, .no-print {
        display: none !important;
    }
    
    .main-content {
        margin: 0;
        padding: 0;
    }
    
    .card {
        border: 1px solid #000;
        box-shadow: none;
    }
}

/* Loading Spinner */
.spinner-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.spinner-border-lg {
    width: 3rem;
    height: 3rem;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0b5ed7;
}