/* ================================================
   وظائفي - Wazayfi.com
   ملف التنسيقات الرئيسي
   ================================================ */

:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --accent-color: #3b82f6;
    --success-color: #10b981;
    --dark-color: #1f2937;
    --light-bg: #f8fafc;
    --border-color: #e5e7eb;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--light-bg);
    overflow-x: hidden;
    color: #333;
}

/* ================================================
   Navbar
   ================================================ */
.navbar {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    padding: 1rem 0;
    transition: all 0.3s;
}

.navbar-brand {
    font-size: 1.8rem;
    font-weight: bold;
    color: white !important;
}

.nav-link {
    color: rgba(255,255,255,0.9) !important;
    font-weight: 500;
    margin: 0 0.5rem;
    transition: all 0.3s;
}

.nav-link:hover,
.nav-link.active {
    color: white !important;
    transform: translateY(-2px);
}

.btn-login, 
.btn-register {
    padding: 0.5rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn-login {
    border: 2px solid white;
    color: white;
    background: transparent;
}

.btn-login:hover {
    background: white;
    color: var(--primary-color);
}

.btn-register {
    background: var(--success-color);
    color: white;
    border: none;
}

.btn-register:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16,185,129,0.4);
    color: white;
}

/* ================================================
   Hero Section
   ================================================ */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 8rem 0 5rem;
    position: relative;
    overflow: hidden;
    margin-top: 70px;
}

.hero::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: moveBackground 20s linear infinite;
}

@keyframes moveBackground {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
    animation: fadeInDown 1s;
}

.hero p {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    animation: fadeInUp 1s;
}

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ================================================
   Search Box
   ================================================ */
.search-box {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    animation: scaleIn 0.8s;
}

@keyframes scaleIn {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.search-box input, 
.search-box select {
    padding: 0.8rem;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    transition: all 0.3s;
}

.search-box input:focus, 
.search-box select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
    outline: none;
}

.btn-search {
    background: var(--primary-color);
    color: white;
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    width: 100%;
    transition: all 0.3s;
    cursor: pointer;
}

.btn-search:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37,99,235,0.4);
}

/* ================================================
   Stats Section
   ================================================ */
.stats {
    padding: 4rem 0;
    background: white;
}

.stat-card {
    text-align: center;
    padding: 2rem;
    transition: transform 0.3s;
}

.stat-card:hover {
    transform: translateY(-10px);
}

.stat-number {
    font-size: 3rem;
    font-weight: bold;
    color: var(--primary-color);
    display: block;
}

.stat-label {
    font-size: 1.1rem;
    color: #6b7280;
    margin-top: 0.5rem;
}

/* ================================================
   Jobs Section
   ================================================ */
.jobs-section {
    padding: 4rem 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: bold;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--dark-color);
}

.job-card {
    background: white;
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.07);
    transition: all 0.3s;
    border: 2px solid transparent;
    text-decoration: none;
    display: block;
}

.job-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.15);
    border-color: var(--primary-color);
}

.company-logo {
    width: 60px;
    height: 60px;
    border-radius: 10px;
    background: var(--light-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    flex-shrink: 0;
}

.job-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.company-name {
    color: #6b7280;
    margin-bottom: 1rem;
}

.job-meta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.job-meta span {
    background: var(--light-bg);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
    color: #4b5563;
}

.job-salary {
    color: var(--success-color);
    font-weight: 600;
    font-size: 1.1rem;
}

.btn-apply {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.6rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
}

.btn-apply:hover {
    background: var(--secondary-color);
    transform: scale(1.05);
    color: white;
}

/* ================================================
   Categories
   ================================================ */
.categories {
    padding: 4rem 0;
    background: white;
}

.category-card {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    transition: all 0.3s;
    cursor: pointer;
    margin-bottom: 1.5rem;
    text-decoration: none;
    display: block;
}

.category-card:hover {
    transform: translateY(-10px) scale(1.05);
    box-shadow: 0 15px 30px rgba(37,99,235,0.3);
    color: white;
}

.category-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.category-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.category-count {
    opacity: 0.9;
}

/* ================================================
   Dashboard Styles
   ================================================ */
.dashboard {
    min-height: 100vh;
    padding-top: 70px;
    background: var(--light-bg);
}

.sidebar {
    background: white;
    min-height: calc(100vh - 70px);
    box-shadow: 2px 0 10px rgba(0,0,0,0.05);
    padding: 2rem 0;
    position: sticky;
    top: 70px;
}

.sidebar-menu {
    list-style: none;
    padding: 0;
}

.sidebar-menu li {
    margin-bottom: 0.5rem;
}

.sidebar-menu a {
    display: block;
    padding: 1rem 1.5rem;
    color: #4b5563;
    text-decoration: none;
    transition: all 0.3s;
    border-right: 3px solid transparent;
}

.sidebar-menu a:hover, 
.sidebar-menu a.active {
    background: var(--light-bg);
    color: var(--primary-color);
    border-right-color: var(--primary-color);
}

.dashboard-content {
    padding: 2rem;
}

.dashboard-card {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.07);
    margin-bottom: 2rem;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

/* ================================================
   Forms
   ================================================ */
.form-container {
    max-width: 500px;
    margin: 100px auto 50px;
    padding: 2rem;
}

.form-card {
    background: white;
    border-radius: 15px;
    padding: 3rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.form-card h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--dark-color);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--dark-color);
}

.form-control {
    width: 100%;
    padding: 0.8rem;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    transition: all 0.3s;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
    outline: none;
}

/* ================================================
   Google AdSense
   ================================================ */
.adsense-container {
    background: #f3f4f6;
    border: 2px dashed #d1d5db;
    padding: 2rem;
    text-align: center;
    margin: 2rem 0;
    border-radius: 10px;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ================================================
   Footer
   ================================================ */
footer {
    background: var(--dark-color);
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

footer h5 {
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: white;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: all 0.3s;
}

.social-links a:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
}

/* ================================================
   Utilities
   ================================================ */
.badge {
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.badge.bg-success {
    background: var(--success-color) !important;
}

.badge.bg-warning {
    background: #f59e0b !important;
}

.badge.bg-info {
    background: #06b6d4 !important;
}

/* ================================================
   Responsive
   ================================================ */
@media (max-width: 768px) {
    .hero {
        padding: 6rem 0 3rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .sidebar {
        position: static;
    }

    .navbar-brand {
        font-size: 1.4rem;
    }

    .category-icon {
        font-size: 2rem;
    }

    .dashboard-header {
        text-align: center;
    }
}

@media (max-width: 576px) {
    .search-box {
        padding: 1.5rem;
    }

    .btn-search {
        padding: 0.8rem 1rem;
    }

    .job-card {
        padding: 1rem;
    }

    .category-card {
        padding: 1.5rem;
    }
}

/* ================================================
   Animations
   ================================================ */
.fade-in {
    animation: fadeIn 0.5s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.slide-up {
    animation: slideUp 0.5s;
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* ================================================
   Loading
   ================================================ */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(37,99,235,0.3);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ================================================
   Messages
   ================================================ */
.alert {
    padding: 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #10b981;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #ef4444;
}

.alert-info {
    background: #dbeafe;
    color: #1e40af;
    border: 1px solid #3b82f6;
}

.bg-gradient {
    background: linear-gradient(135deg, #2563eb, #1e40af) !important;
}

.card:hover {
    transition: all 0.3s ease;
}

.modal-xl {
    max-width: 1000px;
}

.bg-purple {
    background-color: #8b5cf6 !important;
}

#displayLocationsContainer::-webkit-scrollbar {
    width: 8px;
}

#displayLocationsContainer::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

#displayLocationsContainer::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

#displayLocationsContainer::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.section-card {
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    overflow: hidden;
    transition: all 0.3s;
}

.section-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.section-header-custom {
    background: linear-gradient(to right, #f8fafc, #f1f5f9);
    padding: 1.25rem;
    border-bottom: 2px solid #e5e7eb;
}

.section-title-custom {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e40af;
    margin-bottom: 0.25rem;
}

.lesson-list-custom {
    padding: 1rem;
    background: white;
}

.lesson-item-custom {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 0.75rem;
    transition: all 0.2s;
}

.lesson-item-custom:hover {
    background: #f1f5f9;
    transform: translateX(-3px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.lesson-number {
    width: 32px;
    height: 32px;
    background: #2563eb;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
}

.video-icon {
    color: #ef4444;
}

.duration-badge {
    background: #dbeafe;
    color: #1e40af;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
}

.free-badge {
    background: #d1fae5;
    color: #065f46;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
}

.empty-section {
    text-align: center;
    padding: 2rem;
    background: #fef3c7;
    border-radius: 8px;
    color: #92400e;
}

.nav-tabs .nav-link {
    color: #4b5563 !important;
    font-weight: 500;
    border: none;
    border-bottom: 3px solid transparent;
    padding: 0.75rem 1.5rem;
}

.nav-tabs .nav-link:hover {
    color: #2563eb !important;
    border-color: #dbeafe;
}

.nav-tabs .nav-link.active {
    color: #2563eb !important;
    background: white !important;
    border-color: #2563eb !important;
    font-weight: 600;
}

/* ===============================================
   تحسين ألوان التابات - Courses Modal
   =============================================== */
#courseModal .nav-tabs {
    background: #f8fafc !important;
    border-bottom: 2px solid #e5e7eb !important;
    padding: 0.5rem 1rem 0 !important;
}

#courseModal .nav-tabs .nav-link {
    color: #1f2937 !important;
    font-weight: 600 !important;
    border: none !important;
    border-bottom: 3px solid transparent !important;
    padding: 0.875rem 1.5rem !important;
    background: transparent !important;
    position: relative;
    transition: all 0.3s ease;
}

#courseModal .nav-tabs .nav-link:hover {
    color: #2563eb !important;
    background: rgba(37, 99, 235, 0.05) !important;
    border-radius: 8px 8px 0 0;
}

#courseModal .nav-tabs .nav-link.active {
    color: #2563eb !important;
    background: white !important;
    border-bottom: 3px solid #2563eb !important;
    font-weight: 700 !important;
    border-radius: 8px 8px 0 0;
}

#courseModal .nav-tabs .nav-link i {
    margin-left: 0.5rem;
    font-size: 1.1rem;
}

/* تحسين المحتوى داخل التابات */
#courseModal .tab-content {
    background: white;
    padding: 1.5rem;
    min-height: 400px;
}

/* تحسين الـ Labels */
#courseModal .form-label {
    color: #1f2937 !important;
    font-weight: 600 !important;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

/* تحسين الـ Inputs */
#courseModal .form-control,
#courseModal .form-select {
    border: 2px solid #e5e7eb;
    padding: 0.75rem;
    font-size: 0.95rem;
    color: #1f2937;
    transition: all 0.3s;
}

#courseModal .form-control:focus,
#courseModal .form-select:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

#courseModal .form-control::placeholder {
    color: #9ca3af;
}