/* ================================
   Custom CSS for وسيط الإستثمار
   ================================ */

/* استخدام خط Cairo */
* {
    font-family: 'Cairo', sans-serif;
}

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --dark-color: #212529;
    --light-color: #f8f9fa;
}

body {
    background-color: #f8f9fa;
    line-height: 1.8;
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* النافبار */
.navbar {
    padding: 1rem 0;
    transition: all 0.3s ease;
}

.navbar-brand {
    font-size: 1.5rem;
    transition: color 0.3s ease;
}

.navbar-brand:hover {
    color: var(--primary-color) !important;
    transform: scale(1.05);
}

.nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    right: 50%;
    background-color: var(--primary-color);
    transition: all 0.3s ease;
}

.nav-link:hover::after {
    width: 80%;
    right: 10%;
}

.nav-link:hover {
    color: var(--primary-color) !important;
}

/* الأزرار */
.btn {
    padding: 0.6rem 1.5rem;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.btn-primary {
    background: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0a58ca 0%, #0d6efd 100%);
}

/* البطاقات */
.card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.card-img-top {
    height: 200px;
    object-fit: cover;
}

/* Progress Bar */
.progress {
    height: 8px;
    border-radius: 10px;
    background-color: #e9ecef;
}

.progress-bar {
    background: linear-gradient(90deg, #198754 0%, #20c997 100%);
    border-radius: 10px;
}

/* Badges */
.badge {
    padding: 0.5rem 1rem;
    font-weight: 600;
    border-radius: 6px;
}

/* Forms */
.form-control, .form-select {
    border-radius: 8px;
    padding: 0.7rem 1rem;
    border: 1px solid #dee2e6;
    transition: all 0.3s ease;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.15);
}

.form-label {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #495057;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 80px 0;
    color: white;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%23ffffff" fill-opacity="0.1" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,138.7C960,139,1056,117,1152,96C1248,75,1344,53,1392,42.7L1440,32L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') no-repeat bottom;
    background-size: cover;
}

.hero-section h1 {
    font-size: 3rem;
    font-weight: 900;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.hero-section p {
    font-size: 1.3rem;
    opacity: 0.9;
}

/* Stats Section */
.stats-card {
    text-align: center;
    padding: 2rem;
    border-radius: 12px;
    background: white;
    transition: all 0.3s ease;
}

.stats-card:hover {
    transform: translateY(-5px);
}

.stats-card i {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.stats-card h3 {
    font-size: 2.5rem;
    font-weight: 900;
    margin-bottom: 0.5rem;
}

.stats-card p {
    color: #6c757d;
    font-weight: 600;
}

/* Project Card */
.project-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    height: 100%;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.project-card-image {
    height: 200px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.project-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(255,255,255,0.95);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.85rem;
}

.project-card-body {
    padding: 1.5rem;
}

/* Footer */
.footer {
    margin-top: auto;
}

.footer .hover-link:hover {
    color: white !important;
    padding-right: 5px;
    transition: all 0.3s ease;
}

.social-links a {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background-color: var(--primary-color) !important;
    transform: translateY(-3px);
}

/* Dashboard Styles */
.dashboard-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    margin-bottom: 1.5rem;
}

.dashboard-stat {
    text-align: center;
}

.dashboard-stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 1.5rem;
}

.dashboard-stat h3 {
    font-size: 2rem;
    font-weight: 900;
    margin-bottom: 0.5rem;
}

/* Activity Timeline */
.activity-item {
    border-right: 2px solid #dee2e6;
    padding-right: 1.5rem;
    padding-bottom: 1.5rem;
    position: relative;
}

.activity-item::before {
    content: '';
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    position: absolute;
    right: -7px;
    top: 5px;
}

.activity-item:last-child {
    border-right: none;
    padding-bottom: 0;
}

/* Responsive Design للموبايل */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .hero-section p {
        font-size: 1.1rem;
    }
    
    .navbar-brand span {
        font-size: 1.2rem;
    }
    
    .stats-card h3 {
        font-size: 2rem;
    }
    
    .card-img-top {
        height: 180px;
    }
    
    .btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .hero-section {
        padding: 50px 0;
    }
    
    .hero-section h1 {
        font-size: 1.75rem;
    }
    
    .stats-card {
        padding: 1.5rem;
    }
    
    .dashboard-stat h3 {
        font-size: 1.5rem;
    }
}

/* Animation Classes */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Loading Spinner */
.spinner-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
}

/* Alerts تنسيق محسن */
.alert {
    border-radius: 8px;
    border: none;
    padding: 1rem 1.5rem;
    font-weight: 500;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0a58ca;
}

/* Print Styles */
@media print {
    .navbar, .footer, .btn {
        display: none;
    }
}

/* Hover Card Effect */
.hover-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15) !important;
}

/* FAQ Accordion Styles */
.faq-accordion .accordion-item {
    border: none;
    margin-bottom: 1rem;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.faq-accordion .accordion-button {
    font-weight: 600;
    font-size: 1.1rem;
    padding: 1.25rem 1.5rem;
    background-color: white;
    color: #212529;
    border: none;
    border-radius: 12px !important;
}

.faq-accordion .accordion-button:not(.collapsed) {
    background-color: #f8f9fa;
    color: var(--primary-color);
    box-shadow: none;
}

.faq-accordion .accordion-button:focus {
    box-shadow: none;
    border: none;
}

.faq-accordion .accordion-button::after {
    margin-right: auto;
    margin-left: 0;
}

.faq-accordion .accordion-body {
    padding: 1.5rem;
    background-color: white;
    color: #6c757d;
    line-height: 1.8;
}

/* Image Placeholder for Missing Images */
.img-placeholder {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
}

/* Projects Slider for Mobile */
.projects-slider-container {
    position: relative;
    overflow: hidden;
}

.projects-slider {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
    gap: 1rem;
    padding-bottom: 1rem;
}

.projects-slider::-webkit-scrollbar {
    display: none;
}

.projects-slider .slider-item {
    flex: 0 0 calc(50% - 0.5rem);
    scroll-snap-align: start;
}

.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-nav:hover {
    background: var(--primary-color);
    color: white;
}

.slider-nav.prev {
    right: 10px;
}

.slider-nav.next {
    left: 10px;
}

.slider-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* Mobile Responsive Improvements */
@media (max-width: 768px) {
    /* Projects - 2 columns */
    .mobile-grid-2 {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .mobile-grid-2 > .col-lg-4,
    .mobile-grid-2 > .col-lg-3,
    .mobile-grid-2 > .col-md-6 {
        width: 100%;
        padding: 0;
    }
    
    /* Categories - 2 columns */
    .categories-mobile-2 .col-lg-4,
    .categories-mobile-2 .col-md-6 {
        flex: 0 0 50%;
        max-width: 50%;
    }
    
    /* Statistics - horizontal scroll */
    .stats-mobile-scroll {
        display: flex;
        overflow-x: auto;
        gap: 1rem;
        padding-bottom: 1rem;
        scrollbar-width: thin;
    }
    
    .stats-mobile-scroll .col-lg-3,
    .stats-mobile-scroll .col-md-6 {
        flex: 0 0 250px;
        max-width: 250px;
    }
    
    /* How It Works - horizontal scroll */
    .how-it-works-mobile {
        display: flex;
        overflow-x: auto;
        gap: 1rem;
        padding-bottom: 1rem;
    }
    
    .how-it-works-mobile .col-lg-4 {
        flex: 0 0 280px;
        max-width: 280px;
    }
    
    /* Platform Features - 2 columns */
    .features-mobile-2 .col-lg-3,
    .features-mobile-2 .col-md-6 {
        flex: 0 0 50%;
        max-width: 50%;
    }
}

@media (max-width: 576px) {
    /* Smaller font sizes for mobile */
    .display-3 {
        font-size: 2rem !important;
    }
    
    .display-4 {
        font-size: 1.75rem !important;
    }
    
    .display-5 {
        font-size: 1.5rem !important;
    }
    
    .lead {
        font-size: 1rem !important;
    }
}
/* حل مشكلة الصور الشفافة */
.navbar-brand img {
    padding: 8px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* صور المشاريع الشفافة */
.project-card img,
.card-img-top {
    background: #ffffff;
}

/* صور المستثمرين الشفافة */
.investor-image {
    background: #ffffff;
    padding: 5px;
}

/* اللوجو في الفوتر */
footer img {
    background: transparent;
}

/* اللوجو البديل في المشاريع */
.img-placeholder {
    background: #ffffff !important;
    border: 1px solid #e9ecef;
}