/* Global Styles */
/* Bootstrap handles box-sizing and resets */
/* * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
} */

:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --accent-color: #f59e0b;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --bg-light: #f9fafb;
    --bg-white: #ffffff;
    --border-color: #e5e7eb;
    --success-color: #10b981;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

body {
    font-family: 'Cairo', sans-serif;
    direction: rtl;
    text-align: right;
    /* line-height: 1.6; Bootstrap sets this */
    color: var(--text-dark);
    background-color: var(--bg-light);
}

/* .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
} */

/* Header */
.header {
    background: linear-gradient(135deg, #1f2937 0%, #374151 50%, #4b5563 100%);
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 2rem;
}

/* Header Bottom Section - Darker accent bar */
.header-bottom {
    background: linear-gradient(135deg, #111827 0%, #1f2937 100%);
    padding: 0.5rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Logo Link */
.logo-link {
    text-decoration: none;
    transition: all 0.3s ease;
}

.logo-link:hover .logo {
    transform: translateY(-2px);
}

.logo-link:hover .logo i {
    transform: scale(1.1) rotate(5deg);
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff;
    transition: all 0.3s ease;
}

.logo i {
    font-size: 2rem;
    color: #fbbf24;
    transition: all 0.3s ease;
}

/* Logo Image Styles */
.site-logo-image {
    height: 50px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
    transition: all 0.3s ease;
}

/* Responsive logo */
@media (max-width: 768px) {
    .site-logo-image {
        height: 40px;
        max-width: 150px;
    }
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

.nav-menu a {
    text-decoration: none;
    color: #ffffff;
    font-weight: 600;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 8px;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: #fbbf24;
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* Facebook Link */
.facebook-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #ffffff !important;
    text-decoration: none;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.facebook-link:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(255, 255, 255, 0.2);
    color: #fbbf24 !important;
}

.facebook-link i {
    font-size: 1.1rem;
    transition: transform 0.3s ease;
}

.facebook-link:hover i {
    transform: scale(1.2) rotate(360deg);
}

/* Hero Section */
.hero {
    height: 500px;
    background-image: url('https://images.unsplash.com/photo-1449824913935-59a10b8d2000?w=1200');
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.8), rgba(30, 64, 175, 0.8));
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: white;
    padding: 2rem;
}

.hero-title {
    font-size: 3rem;
    font-weight: 900;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 300;
}

/* Advertisement Banner */
.ad-banner {
    padding: 2rem 0;
}

.ad-placeholder {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    color: white;
    font-size: 1.2rem;
    font-weight: 600;
    box-shadow: var(--shadow-lg);
}

.ad-placeholder i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    display: block;
}

/* Search Section */
.search-section {
    position: absolute;
    bottom: 50px;
    left: 0;
    right: 0;
    z-index: 10;
    padding: 0;
}

.search-box {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
    padding: 0 20px;
}

.search-box i {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    font-size: 1.2rem;
}

.search-box input {
    width: 100%;
    padding: 1.2rem 3.5rem 1.2rem 1.5rem;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-family: 'Cairo', sans-serif;
    transition: all 0.3s ease;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.search-box input:focus {
    outline: none;
    box-shadow: 0 10px 50px rgba(37, 99, 235, 0.3);
}

/* Categories Section */
.categories-section {
    padding: 3rem 0;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 2rem;
    text-align: center;
}

/* Categories Container with Arrows */
.categories-container {
    position: relative;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.categories-grid {
    display: flex;
    gap: 1.5rem;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    padding: 1rem 0;
    flex: 1;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.categories-grid::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

/* Category Navigation Arrows */
.category-arrow {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
    flex-shrink: 0;
    font-size: 1.2rem;
    z-index: 10;
}

.category-arrow:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-lg);
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
}

.category-arrow:active {
    transform: scale(0.95);
}

.category-arrow i {
    pointer-events: none;
}

.category-card {
    background: var(--bg-white);
    padding: 2rem 1rem;
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
    border: 2px solid transparent;
    min-width: 140px;
    flex-shrink: 0;
}

.category-card:hover,
.category-card.active {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.05), rgba(30, 64, 175, 0.05));
}

.category-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    display: block;
}

.category-card span {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 1rem;
}

/* Featured Businesses Section */
.featured-section {
    padding: 3rem 0;
    background-color: #f3f4f6;
}

.regular-section {
    padding: 3rem 0;
}

.businesses-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.business-card {
    background: var(--bg-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    cursor: pointer;
}

.business-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.business-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.business-content {
    padding: 1.5rem;
}

/* Business Header with Name and Category inline */
.business-header-inline {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.business-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
    cursor: pointer;
    transition: color 0.3s ease;
}

.business-name:hover {
    color: var(--primary-color);
}

.business-category {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    white-space: nowrap;
}

/* Contact Button */
.contact-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-bottom: 1rem;
    width: 100%;
}

.phone-btn {
    background: var(--success-color);
    color: white;
}

.phone-btn:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.business-social {
    display: flex;
    gap: 0.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    text-decoration: none;
    color: white;
    transition: all 0.3s ease;
}

.social-link:hover {
    transform: scale(1.1);
    color:#fff !important;
    text-decoration: none;
}

.facebook {
    background: #1877f2;
}

.instagram {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
}

.twitter {
    background: #1da1f2;
}

.linkedin {
    background: #0077b5;
}

.website {
    background: #000088;
}.youtube {
    background: #ff0000;
}.tiktok {
    background: #000000;
}

/* Regular Businesses */
.regular-businesses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.regular-business-card {
    background: var(--bg-white);
    border-radius: 12px;
    padding: 1.2rem 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    border: 2px solid var(--border-color);
}

.regular-business-card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.regular-business-icon {
    display: none;
}

.regular-business-info {
    flex: 1;
}

.regular-business-name {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.regular-business-phone {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    text-decoration: none;
    font-weight: 600;
    padding: 0.6rem 1.2rem;
    background: var(--success-color);
    border-radius: 8px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.regular-business-phone:hover {
    background: #059669;
    transform: scale(1.05);
}

/* Footer */
.footer {
    background: linear-gradient(135deg, var(--text-dark), #111827);
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent-color);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: #d1d5db;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: var(--accent-color);
}

.footer-section p {
    color: #d1d5db;
    margin-bottom: 0.5rem;
}

.footer-section i {
    margin-left: 0.5rem;
    color: var(--accent-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
    text-align: center;
    color: #9ca3af;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero {
        height: 450px;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .search-section {
        bottom: 40px;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .categories-grid {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
        gap: 1rem;
    }

    .category-card {
        padding: 1.5rem 0.5rem;
    }

    .category-card i {
        font-size: 2rem;
    }

    .businesses-grid {
        grid-template-columns: 1fr;
    }

    /* Hide category arrows on mobile */
    .category-arrow {
        display: none;
    }

    .categories-container {
        gap: 0;
    }

    .navbar-right {
        gap: 1rem;
    }

    .nav-menu {
        gap: 0.5rem;
    }

    .nav-menu a {
        padding: 0.3rem 0.8rem;
        font-size: 0.85rem;
    }

    /* Hide Facebook text on mobile, show icon only */
    .facebook-link span {
        display: none;
    }

    .facebook-link {
            padding: 0.5rem;
            border-radius: 50%;
            width: 40px !important;
            height: 40px;
            justify-content: center;
        }

    .facebook-link i {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .hero {
        height: 450px;
        margin-bottom: 0;
    }

    .hero-title {
        font-size: 1.5rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .logo {
        font-size: 1.2rem;
    }

    .logo i {
        font-size: 1.5rem;
    }

    .search-section {
        bottom: 30px;
    }

    .search-box input {
        padding: 1rem 3rem 1rem 1.2rem;
        font-size: 0.95rem;
    }
}

/* Loading Animation */
.loading {
    text-align: center;
    padding: 3rem;
    color: var(--text-light);
}

.loading i {
    font-size: 3rem;
    animation: spin 1s linear infinite;
}

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

/* Responsive Grid for Featured Businesses */
/* Large screens (1200px+) - 4 columns */
@media (min-width: 1200px) {
    .businesses-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Medium screens (768px - 1199px) - 3 columns */
@media (min-width: 769px) and (max-width: 1199px) {
    .businesses-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Small tablets (481px - 768px) - 2 columns */
@media (min-width: 481px) and (max-width: 768px) {
    .businesses-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
    z-index: 1000;
}

.scroll-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-to-top:not(.show) {
    transform: translateY(20px);
}

.scroll-to-top:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    color: white;
}

.scroll-to-top:active {
    transform: scale(0.9);
}
