:root {
    /* Primary Color Palette */
    --primary: #0f172a;
    --primary-light: #1e293b;
    --primary-gradient: linear-gradient(135deg, #0f172a, #1e293b);

    /* Accent Palette (Cyan/Teal) */
    --accent: #06b6d4;
    --accent-hover: #0891b2;
    --accent-light: rgba(6, 182, 212, 0.1);
    --accent-gradient: linear-gradient(135deg, #06b6d4, #0891b2);

    /* Backgrounds & Surfaces */
    --bg-body: #f8fafc;
    --bg-card: #ffffff;
    --bg-glass: rgba(255, 255, 255, 0.8);

    /* Typography */
    --text-main: #1e293b;
    --text-muted: #64748b;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Tajawal', sans-serif;

    /* Borders & Shadows */
    --border: #e2e8f0;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);

    /* Utils */
    --radius-lg: 16px;
    --radius-md: 12px;
    --success: #10b981;
    --danger: #ef4444;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-weight: 500;
    cursor: pointer;
    font-family: var(--font-body);
    border: none;
    transition: all 0.3s ease;
}

.btn-primary {
    background: var(--accent);
    color: white;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(6, 182, 212, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--text-main);
}

.btn-secondary:hover {
    color: var(--accent);
}

.btn-search {
    background: var(--primary);
    color: white;
    padding: 14px 32px;
}

.btn-outline {
    border: 2px solid var(--border);
    background: transparent;
    color: var(--text-main);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-light {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    backdrop-filter: blur(5px);
}

.btn-light:hover {
    background: white;
    color: var(--primary);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
    border-radius: 8px;
    gap: 6px;
    white-space: nowrap;
    height: auto;
    min-width: max-content;
}

.btn-outline-sm {
    padding: 8px 16px;
    font-size: 13px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: transparent;
    cursor: pointer;
    transition: 0.3s;
    font-family: inherit;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-outline-sm:hover {
    border-color: var(--primary);
    background: #f8fafc;
}

/* Navbar */
.navbar {
    height: 80px;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--primary);
}

.logo-icon {
    font-size: 32px;
    color: var(--accent);
}

.logo-text h1 {
    font-size: 20px;
    letter-spacing: 2px;
}

.logo-text .logo-sub {
    font-size: 10px;
    letter-spacing: 4px;
    color: var(--text-muted);
    display: block;
    margin-top: -5px;
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    color: var(--text-muted);
    font-weight: 500;
}

.nav-links a.active,
.nav-links a:hover {
    color: var(--primary);
}

.nav-actions {
    display: flex;
    gap: 15px;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
}

/* Hero Section */
.hero {
    padding-top: 160px;
    padding-bottom: 100px;
    text-align: center;
    position: relative;
    background: radial-gradient(circle at 10% 20%, rgba(6, 182, 212, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(15, 23, 42, 0.05) 0%, transparent 40%);
}

.hero-tag {
    background: rgba(6, 182, 212, 0.1);
    color: var(--accent-hover);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 500;
    display: inline-block;
    margin-bottom: 20px;
}

.hero-title {
    font-size: 48px;
    color: var(--primary);
    margin-bottom: 20px;
    font-family: 'Tajawal', sans-serif;
    /* Override for Arabic title */
    font-weight: 800;
}

.text-gradient {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    color: var(--text-muted);
    font-size: 18px;
    max-width: 600px;
    margin: 0 auto 40px;
}

.search-box {
    background: white;
    max-width: 750px;
    margin: 0 auto;
    border-radius: 100px;
    padding: 5px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    border: 1px solid var(--border);
    gap: 8px;
}

.input-group {
    flex: 1;
    display: flex;
    align-items: center;
    padding: 0 14px;
    gap: 6px;
    color: var(--text-muted);
}

/* Make search input wider, selects narrower */
.search-box .input-group:first-child {
    flex: 2;
    min-width: 200px;
}

.search-box .input-group:nth-child(3),
.search-box .input-group:nth-child(5) {
    flex: 0.65;
    max-width: 160px;
    min-width: 130px;
}

.input-group input,
.input-group select {
    border: none;
    width: 100%;
    outline: none;
    font-family: var(--font-body);
    font-size: 14px;
    background: transparent;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.input-group select {
    cursor: pointer;
    min-width: 100px;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05), rgba(147, 51, 234, 0.05));
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 8px;
    padding: 8px 12px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.input-group select:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(147, 51, 234, 0.1));
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
    transform: translateY(-1px);
}

.input-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Style select dropdown options */
.input-group select option {
    background: white;
    color: var(--text-primary);
    padding: 10px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.input-group select option:hover,
.input-group select option:checked {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(147, 51, 234, 0.15));
    color: var(--primary-color);
    font-weight: 500;
}

.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}

.filter-tag {
    appearance: none;
    border: 1px solid rgba(59, 130, 246, 0.35);
    background: rgba(59, 130, 246, 0.08);
    color: var(--primary);
    border-radius: 999px;
    padding: 8px 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 13px;
}

.filter-tag:hover,
.filter-tag:focus {
    background: rgba(59, 130, 246, 0.15);
    transform: translateY(-1px);
}

/* Modern Custom Select - Premium UI Component */
.custom-select {
    position: relative;
    width: 100%;
    user-select: none;
    z-index: 5;
    /* Base z-index */
}

.custom-select-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 14px;
    color: var(--primary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 40px;
}

.custom-select.open {
    z-index: 1000;
    /* High z-index when open to stay on top of everything */
}

.custom-select.open .custom-select-trigger {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.1);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.custom-select-trigger:after {
    content: '\f107';
    /* ph-caret-down placeholder */
    font-family: "Phosphor-Bold";
    font-size: 18px;
    margin-right: 10px;
    transition: transform 0.3s ease;
}

.custom-select.open .custom-select-trigger:after {
    transform: rotate(180deg);
}

.custom-options {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    /* Solid white to prevent transparency overlaps */
    border: 1px solid var(--border);
    border-top: none;
    border-bottom-left-radius: var(--radius-md);
    border-bottom-right-radius: var(--radius-md);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    max-height: 250px;
    overflow-y: auto;
    z-index: 10;
}

.custom-select.open .custom-options {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.custom-option {
    padding: 12px 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    text-align: right;
    /* Maintain Arabic text-align */
}

.custom-option:last-child {
    border-bottom: none;
}

.custom-option:hover {
    background: rgba(6, 182, 212, 0.05);
    color: var(--accent-hover);
    padding-right: 25px;
}

.custom-option.selected {
    background: rgba(6, 182, 212, 0.1);
    color: var(--accent);
    font-weight: 600;
}

/* Hide original native select but keep it accessible for forms */
.hidden-select {
    position: absolute;
    width: 0;
    height: 0;
    opacity: 0;
    pointer-events: none;
}

/* Specific styling for search-box selects to maintain rounded look */
.search-box select {
    border: none !important;
    background-color: transparent;
    padding-top: 5px !important;
    padding-bottom: 5px !important;
    border-radius: 0;
    box-shadow: none;
}

.search-box select:hover,
.search-box select:focus {
    background-color: rgba(6, 182, 212, 0.05);
    box-shadow: none;
}

/* Custom Checkbox Alignment */
.form-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 14px;
    color: var(--text-muted);
}

.form-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--accent);
}

.divider {
    width: 1px;
    height: 30px;
    background: var(--border);
}

.btn-search {
    border-radius: 100px;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Skeleton Loading */
.skeleton {
    position: relative;
    overflow: hidden;
    background: #f1f5f9 !important;
    border-color: transparent !important;
}

.skeleton::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    100% {
        transform: translateX(100%);
    }
}

.skeleton-text {
    height: 12px;
    background: #e2e8f0;
    border-radius: 4px;
    margin-bottom: 10px;
}

.skeleton-text.title {
    width: 70%;
    height: 20px;
}

.skeleton-text.subtitle {
    width: 40%;
}

.skeleton-icon,
.skeleton-logo {
    width: 60px;
    height: 60px;
    background: #e2e8f0;
    border-radius: 12px;
    margin-bottom: 15px;
}

.skeleton-tag {
    display: inline-block;
    width: 60px;
    height: 24px;
    background: #e2e8f0;
    border-radius: 20px;
    margin-right: 5px;
}


.animate {
    opacity: 0;
    animation-fill-mode: forwards;
}

.animate.visible {
    animation-duration: 0.6s;
    animation-timing-function: ease-out;
}

.fade-up {
    animation-name: fadeInUp;
}

.scale-in {
    animation-name: scaleIn;
}

.delay-100 {
    animation-delay: 0.1s;
}

.delay-200 {
    animation-delay: 0.2s;
}

.delay-300 {
    animation-delay: 0.3s;
}

/* Stats */
.hero-stats {
    display: flex;
    justify-content: center;
    gap: 50px;
    margin-top: 60px;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-num {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary);
    font-family: var(--font-heading);
}

.stat-label {
    font-size: 14px;
    color: var(--text-muted);
}

/* Categories */
.section {
    padding: 80px 0;
}

.section-header {
    margin-bottom: 40px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.section-header.center {
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 20px;
}

.cat-card {
    background: white;
    padding: 24px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    transition: 0.3s;
}

.cat-card i {
    font-size: 32px;
    color: var(--accent);
    margin-bottom: 5px;
}

.cat-card:hover {
    border-color: var(--accent);
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

/* Job Cards */
.jobs-grid {
    display: grid;
    grid-template-columns: 1fr;
    /* Vertical layout as requested */
    gap: 20px;
    margin-bottom: 50px;
}

.job-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 30px;
    /* More padding for cleaner look */
    border: 1px solid var(--border);
    transition: 0.3s;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.job-card:hover {
    box-shadow: var(--shadow-lg);
    border-color: transparent;
    transform: translateY(-5px);
}

.job-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 4px;
    height: 100%;
    background: var(--accent);
    opacity: 0;
    transition: 0.3s;
}

.job-card:hover::before {
    opacity: 1;
}

.job-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.company-logo {
    object-fit: contain;
    background: #fff;
    border: 1px solid var(--border);
    transition: transform 0.3s ease;
}

.logo-sm {
    width: 24px;
    height: 24px;
    border-radius: 4px;
}

.logo-md {
    width: 48px;
    height: 48px;
    border-radius: 10px;
}

.logo-lg {
    width: 100px;
    height: 100px;
    border-radius: 12px;
}


.job-type {
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 20px;
    background: #e0f2fe;
    color: #0284c7;
    font-weight: 500;
}

.job-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--primary);
}

.company-name {
    color: var(--text-muted);
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 20px;
}

.job-tags {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.tag {
    font-size: 13px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 5px;
}

.job-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.job-date {
    font-size: 13px;
    color: #94a3b8;
}

.apply-btn {
    color: var(--accent);
    font-weight: 600;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Tenders */
.tenders-section {
    background: var(--primary);
    color: white;
    border-radius: 30px;
    margin: 40px 20px;
}

.tenders-wrapper {
    display: flex;
    gap: 60px;
    padding: 40px;
    flex-wrap: wrap;
}

.tenders-info {
    flex: 1;
    min-width: 300px;
}

.tenders-info h2 {
    font-size: 36px;
    margin-bottom: 20px;
}

.tenders-info p {
    color: #94a3b8;
    margin-bottom: 30px;
}

.tenders-list {
    flex: 1.5;
    min-width: 300px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.tender-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 20px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: 0.3s;
    cursor: pointer;
}

.tender-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

.tender-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
}

.tender-details h4 {
    font-size: 16px;
    margin-bottom: 5px;
}

.tender-meta {
    font-size: 12px;
    color: #94a3b8;
    display: flex;
    gap: 15px;
}

/* Footer */
.footer {
    background: white;
    padding: 80px 0 40px;
    border-top: 1px solid var(--border);
}

.footer-container {
    display: flex;
    flex-direction: column;
    gap: 60px;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    margin-bottom: 60px;
    flex-wrap: wrap;
    gap: 40px;
}

.footer-brand h2 {
    color: var(--primary);
    letter-spacing: 2px;
    margin-bottom: 15px;
}

.footer-cols {
    display: flex;
    gap: 80px;
    flex-wrap: wrap;
}

.footer-cols h4 {
    margin-bottom: 20px;
    color: var(--primary);
}

.footer-cols ul li {
    margin-bottom: 12px;
}

.footer-cols ul li a {
    color: var(--text-muted);
}

.footer-cols ul li a:hover {
    color: var(--accent);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 30px;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
}

.socials {
    display: flex;
    gap: 20px;
    font-size: 20px;
}

@media (max-width: 768px) {
    .job-item-card {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 15px !important;
        padding: 15px !important;
    }
    
    .job-item-card .tender-info {
        width: 100% !important;
    }
    
    .job-item-card .tender-actions {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        width: 100% !important;
        margin-top: 10px !important;
        border-top: 1px solid var(--border) !important;
        padding-top: 12px !important;
    }
    
    .job-item-card .tender-actions button {
        padding: 8px 16px !important;
        flex: none !important;
    }

    .hero-title {
        font-size: 36px;
    }

    .search-box {
        flex-direction: column;
        border-radius: 20px;
    }

    .divider {
        display: none;
    }

    .input-group {
        width: 100%;
        padding: 15px;
        border-bottom: 1px solid var(--border);
    }

    .btn-search {
        width: 100%;
        margin-top: 10px;
    }

    .nav-links,
    .nav-actions {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
        color: var(--primary);
    }

    /* Mobile Menu Active State */
    .nav-links.active {
        display: flex;
        flex-direction: column;
        position: fixed;
        /* Changed to fixed to ensure it stays on top */
        top: 80px;
        right: 0;
        left: 0;
        width: 100%;
        background-color: #ffffff !important;
        /* Force white background */
        padding: 20px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        border-bottom: 1px solid var(--border);
        gap: 0;
        z-index: 9999;
        /* Super high z-index */
        animation: slideDown 0.3s ease-out;
        list-style: none !important;
        /* Force remove bullets */
        margin: 0 !important;
        padding-right: 0 !important;
        /* Remove RTL default padding */
    }

    .nav-links.active li {
        width: 100%;
        margin: 0;
        padding: 0;
        list-style: none;
        /* Double insurance */
    }

    .nav-links.active li a {
        display: block;
        padding: 15px 20px;
        border-bottom: 1px solid #f1f5f9;
        font-size: 16px;
        color: #1e293b !important;
        /* Force dark text color */
        text-align: right;
    }

    .nav-links.active li:last-child a {
        border-bottom: none;
    }

    .nav-actions.active {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 350px;
        /* Pushed down to avoid overlap */
        left: 0;
        right: 0;
        width: 100%;
        background-color: #ffffff !important;
        padding: 0 20px 20px;
        box-shadow: 0 10px 10px -5px rgba(0, 0, 0, 0.1);
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow-lg);
        gap: 15px;
        z-index: 9999;
        animation: slideDown 0.3s ease-out;
    }

    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .hero-stats {
        flex-direction: column;
        gap: 30px;
    }

    .tenders-wrapper {
        padding: 30px 20px;
        flex-direction: column;
    }
}

/* Job Details Header */
.job-header-section {
    padding: 120px 0 60px;
    background: white;
    border-bottom: 1px solid var(--border);
}

.job-header-content {
    display: flex;
    align-items: center;
    gap: 30px;
}

.company-logo-large img {
    width: 100px;
    height: 100px;
    border-radius: 20px;
    border: 1px solid var(--border);
    padding: 10px;
    object-fit: contain;
}

.job-header-info {
    flex: 1;
}

.job-title-large {
    font-size: 32px;
    margin-bottom: 15px;
    color: var(--primary);
}

.job-meta-large {
    display: flex;
    gap: 20px;
    color: var(--text-muted);
    font-size: 16px;
}

.job-meta-large span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.job-header-actions {
    display: flex;
    gap: 10px;
}

.btn-lg {
    padding: 16px 40px;
    font-size: 18px;
}

.btn-icon {
    padding: 16px;
    font-size: 20px;
}

/* Job Details Layout */
.job-details-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    margin-top: 40px;
    margin-bottom: 80px;
}

.card {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 30px;
}

.content-card h2,
.content-card h3 {
    color: var(--primary);
    margin-top: 30px;
    margin-bottom: 20px;
}

.content-card h2:first-child {
    margin-top: 0;
}

.content-card p {
    color: var(--text-muted);
    margin-bottom: 20px;
}

.job-list {
    list-style: none;
}

.job-list li {
    position: relative;
    padding-right: 25px;
    margin-bottom: 12px;
    color: var(--text-main);
}

.job-list li::before {
    content: "•";
    color: var(--accent);
    font-size: 24px;
    position: absolute;
    right: 0;
    top: -5px;
}

.job-list li.list-header {
    padding-right: 0;
    font-weight: 700;
    color: var(--primary);
    font-size: 1.1rem;
    margin-top: 20px;
    margin-bottom: 8px;
}

.job-list li.list-header::before {
    display: none;
}

.job-list li.no-bullet {
    padding-right: 0;
}

.job-list li.no-bullet::before {
    display: none;
}

/* LTR support for Job description and lists */
.ltr {
    text-align: left !important;
    direction: ltr !important;
}

.job-list li.ltr {
    padding-right: 0;
    padding-left: 25px;
    text-align: left;
    direction: ltr;
}

.job-list li.ltr::before {
    right: auto;
    left: 0;
}

.job-list li.list-header.ltr {
    padding-left: 0;
}

.job-list li.no-bullet.ltr {
    padding-left: 0;
}

/* Sidebar */
.job-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.summary-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.summary-list li {
    display: flex;
    align-items: center;
    gap: 15px;
}

.summary-list li i {
    font-size: 24px;
    color: var(--accent);
    background: #ecfeff;
    padding: 10px;
    border-radius: 10px;
}

.summary-list li div {
    display: flex;
    flex-direction: column;
}

.summary-list li div span {
    font-size: 13px;
    color: var(--text-muted);
}

.summary-list li div strong {
    color: var(--primary);
}

.btn-full {
    width: 100%;
    margin-top: 20px;
    justify-content: center;
}

@media (max-width: 768px) {
    .job-header-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .job-header-actions {
        width: 100%;
        display: flex;
        flex-wrap: wrap;
        gap: 10px;
    }

    .job-header-actions #apply-btn {
        width: 100%;
        flex: none;
        text-align: center;
        justify-content: center;
    }

    .job-header-actions .btn-icon {
        flex: 1;
        justify-content: center;
        padding: 12px;
    }

    .job-details-layout {
        grid-template-columns: 1fr;
    }
}

/* Dashboard Styles */
.dashboard-body {
    background-color: #f1f5f9;
}

.dashboard-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 280px;
    background: white;
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    right: 0;
    z-index: 100;
}

.sidebar-header {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid var(--border);
}

.sidebar-nav {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--radius-md);
    color: var(--text-muted);
    font-weight: 500;
    transition: 0.3s;
}

.nav-item i {
    font-size: 20px;
}

.nav-item:hover,
.nav-item.active {
    background: #ecfeff;
    color: var(--accent);
}

.nav-item .badge {
    margin-right: auto;
    background: var(--accent);
    color: white;
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 10px;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid var(--border);
}

.logout:hover {
    background: #fef2f2;
    color: #ef4444;
}

/* Dashboard Main */
.dashboard-main {
    flex: 1;
    margin-right: 280px;
    padding: 30px;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.user-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: var(--shadow-sm);
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.stat-card {
    background: white;
    padding: 24px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 20px;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-icon.blue {
    background: #e0f2fe;
    color: #0284c7;
}

.stat-icon.green {
    background: #dcfce7;
    color: #16a34a;
}

.stat-icon.purple {
    background: #f3e8ff;
    color: #9333ea;
}

.stat-info h3 {
    font-size: 14px;
    color: var(--text-muted);
    font-weight: 500;
}

.stat-info .number {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    font-family: var(--font-heading);
}

/* Table */
.recent-activity {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    padding: 24px;
}

.recent-activity .section-header {
    margin-bottom: 20px;
    align-items: center;
}

.applicants-table-wrapper {
    overflow-x: auto;
}

.applicants-table {
    width: 100%;
    border-collapse: collapse;
}

.applicants-table th {
    text-align: right;
    padding: 15px;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 14px;
    border-bottom: 1px solid var(--border);
}

.applicants-table td {
    padding: 15px;
    border-bottom: 1px solid var(--border);
    color: var(--text-main);
}

.applicant-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.applicant-info .avatar {
    width: 32px;
    height: 32px;
    background: #f1f5f9;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-muted);
}

.applicant-info div {
    display: flex;
    flex-direction: column;
}

.applicant-info span {
    font-size: 12px;
    color: var(--text-muted);
}

.status {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.status.new {
    background: #dcfce7;
    color: #16a34a;
}

.status.review {
    background: #fff7ed;
    color: #ea580c;
}

.btn-icon-sm {
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    border-radius: 5px;
    transition: 0.2s;
}

.btn-icon-sm:hover {
    background: #f1f5f9;
}

@media (max-width: 992px) {
    .sidebar {
        width: 80px;
    }

    .sidebar .logo-text,
    .nav-item span,
    .nav-item .badge {
        display: none;
    }

    .nav-item {
        justify-content: center;
        padding: 15px;
    }

    .dashboard-main {
        margin-right: 80px;
    }
}

/* Modern Form Styling */
.form-container {
    max-width: 800px;
    margin: 0 auto;
}

.post-job-form {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.form-section {
    background: white;
    padding: 30px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.form-section h3 {
    margin-bottom: 25px;
    color: var(--primary);
    font-size: 18px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 15px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 15px;
}

.form-group label {
    font-weight: 500;
    font-size: 14px;
    color: var(--text-main);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background-color: #f8fafc;
    font-family: var(--font-body);
    font-size: 15px;
    color: var(--text-main);
    transition: all 0.3s ease;
    width: 100%;
    outline: none;
}

.form-group input:hover,
.form-group select:hover,
.form-group textarea:hover {
    background-color: white;
    border-color: #cbd5e1;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    background-color: white;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #94a3b8;
}

/* Select custom styling fix */
.form-group select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2364748b'%3E%3Cpath d='M11.9999 13.1714L16.9497 8.22168L18.3639 9.63589L11.9999 16L5.63599 9.63589L7.0502 8.22168L11.9999 13.1714Z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 12px center;
    background-size: 20px;
}

.form-section textarea {
    resize: vertical;
    min-height: 120px;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 15px;
    margin-top: 10px;
}

@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}

/* About Page Styles */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-image {
    position: relative;
    height: 400px;
}

.img-placeholder {
    width: 100%;
    height: 100%;
    background: #f1f5f9;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 64px;
    color: #cbd5e1;
    border: 2px dashed #e2e8f0;
}

.about-content h2 {
    font-size: 32px;
    color: var(--primary);
    margin-bottom: 20px;
}

.features-list {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.feature-item {
    display: flex;
    gap: 15px;
}

.feature-item .icon-box {
    width: 50px;
    height: 50px;
    background: rgba(6, 182, 212, 0.1);
    color: var(--accent);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.feature-item h4 {
    margin-bottom: 5px;
    font-size: 18px;
    color: var(--primary);
}

.feature-item p {
    color: var(--text-muted);
    font-size: 14px;
}

/* Contact Page Styles */
.contact-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.info-card {
    background: white;
    padding: 25px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    transition: 0.3s;
}

.info-card:hover {
    border-color: var(--accent);
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.info-card i {
    font-size: 32px;
    color: var(--accent);
    margin-bottom: 15px;
    display: block;
}

.info-card h3 {
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--primary);
}

.info-card p {
    color: var(--text-muted);
    line-height: 1.6;
}

.center-cta {
    background: #f8fafc;
    border-top: 1px solid var(--border);
}

@media (max-width: 768px) {
    .about-grid {
        grid-template-columns: 1fr;
    }

}

/* Company Profile Page */
.company-header-section {
    padding-top: 120px;
    padding-bottom: 60px;
    background: linear-gradient(to bottom, #f0f9ff, #ffffff);
    border-bottom: 1px solid var(--border);
}

.company-profile-card {
    display: flex;
    align-items: center;
    gap: 30px;
}

.company-profile-card .company-logo-large img {
    width: 120px;
    height: 120px;
    background: white;
}

.company-info-large h1 {
    font-size: 36px;
    color: var(--primary);
    margin-bottom: 15px;
}

.company-meta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.company-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 16px;
    background: white;
    padding: 8px 16px;
    border-radius: 20px;
    border: 1px solid var(--border);
}

.company-actions {
    margin-right: auto;
    display: flex;
    gap: 15px;
}

.company-content-layout {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 40px;
    margin-top: 40px;
    margin-bottom: 80px;
}

.company-sidebar .card {
    position: sticky;
    top: 100px;
}

.contact-info-sm {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact-info-sm .info-item {
    display: flex;
    gap: 10px;
    align-items: center;
    color: var(--text-main);
}

.contact-info-sm i {
    color: var(--accent);
    font-size: 20px;
}

.jobs-grid {
    display: grid;
    gap: 20px;
}

@media (max-width: 992px) {
    .company-content-layout {
        grid-template-columns: 1fr;
    }

    .company-profile-card {
        flex-direction: column;
        text-align: center;
    }

    .company-actions {
        margin-right: 0;
        width: 100%;
        justify-content: center;
    }

    .company-meta {
        justify-content: center;
    }
}

/* Companies Directory */
.page-header-simple {
    padding-top: 140px;
    padding-bottom: 60px;
    text-align: center;
    background: linear-gradient(to bottom, #f8fafc, #ffffff);
}

.companies-directory-section {
    padding-bottom: 80px;
}

.companies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

.company-dir-card {
    background: white;
    padding: 30px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.company-dir-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.company-dir-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: #f8fafc;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
}

.company-dir-logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.company-dir-card h3 {
    font-size: 20px;
    color: var(--primary);
    margin-bottom: 10px;
}

.company-dir-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 20px;
}

.company-dir-btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: #f1f5f9;
    color: var(--primary);
    border-radius: var(--radius-md);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.company-dir-card:hover .company-dir-btn {
    background-color: var(--primary);
    color: white;
}

/* Toggle Switch Styling */
.toggle-switch-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cbd5e1;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
}

input:checked+.slider {
    background-color: var(--primary);
}

input:focus+.slider {
    box-shadow: 0 0 1px var(--primary);
}

input:checked+.slider:before {
    transform: translateX(26px);
}

.slider.round {
    border-radius: 34px;
}

.slider.round:before {
    border-radius: 50%;
}

/* Generic spinning animation */
.animate-spin {
    animation: spin 1s linear infinite;
    display: inline-block;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Hover effects for custom gradient buttons */
.tender-card-full button:hover,
.tender-item button:hover,
.company-dir-card button:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.3) !important;
    filter: brightness(1.1);
}

.tender-card-full button:active,
.tender-item button:active,
.company-dir-card button:active {
    transform: translateY(0) !important;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2) !important;
}

/* Hover effects for tender and job cards */
.tender-card-full:hover,
.tender-item:hover,
.company-dir-card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.15) !important;
    border-color: var(--primary-color) !important;
    cursor: pointer;
}

.tender-card-full:active,
.tender-item:active,
.company-dir-card:active {
    transform: translateY(-1px) !important;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1) !important;
}

/* Category Indicators */
.job-item-card.cat-it {
    border-right: 6px solid #3b82f6 !important;
}

.job-item-card.cat-accounting {
    border-right: 6px solid #22c55e !important;
}

.job-item-card.cat-engineering {
    border-right: 6px solid #f97316 !important;
}

.job-item-card.cat-healthcare {
    border-right: 6px solid #ec4899 !important;
}

.job-item-card.cat-other {
    border-right: 6px solid #cbd5e1 !important;
}

/* Animation System */
.animate {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-up {
    transform: translateY(30px);
}

/* Toast Container */
#toast-container {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
    max-width: 400px;
    width: calc(100% - 48px);
}

/* Toast Card */
.custom-toast {
    padding: 16px 24px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-main);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 12px;
    pointer-events: auto;
    opacity: 0;
    transform: translateY(20px) scale(0.95);
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    direction: rtl;
    border-right: 4px solid var(--accent);
}

.custom-toast.show {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.custom-toast.success {
    border-right-color: #10b981;
}

.custom-toast.error {
    border-right-color: #ef4444;
}

.custom-toast.warning {
    border-right-color: #f59e0b;
}

.custom-toast i {
    font-size: 20px;
}
.custom-toast.success i { color: #10b981; }
.custom-toast.error i { color: #ef4444; }
.custom-toast.warning i { color: #f59e0b; }

/* ===== Formatting Guide Cheatsheet ===== */
.formatting-guide {
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 24px;
    overflow: hidden;
    background: var(--card-bg);
}

.formatting-guide-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    cursor: pointer;
    user-select: none;
    background: linear-gradient(135deg, rgba(var(--primary-rgb, 99,102,241), 0.08), rgba(var(--accent-rgb, 139,92,246), 0.05));
    border-bottom: 1px solid transparent;
    transition: background 0.2s;
    font-weight: 600;
    color: var(--primary);
    gap: 8px;
}

.formatting-guide-header:hover {
    background: linear-gradient(135deg, rgba(var(--primary-rgb, 99,102,241), 0.14), rgba(var(--accent-rgb, 139,92,246), 0.10));
}

.formatting-guide-header span {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
}

.formatting-guide-header i.ph-magic-wand {
    font-size: 1.1rem;
}

.guide-caret {
    font-size: 1rem;
    transition: transform 0.25s ease;
    transform: rotate(180deg);
}

.formatting-guide-body {
    padding: 18px 20px;
    border-top: 1px solid var(--border);
}

.guide-intro {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 14px;
}

.guide-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 18px;
}

.guide-item {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-main);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 0.875rem;
    flex-wrap: wrap;
}

.guide-item-full {
    grid-column: 1 / -1;
}

.guide-item code {
    background: rgba(var(--primary-rgb, 99,102,241), 0.1);
    color: var(--primary);
    padding: 2px 8px;
    border-radius: 5px;
    font-family: 'Courier New', monospace;
    font-size: 0.83rem;
    direction: ltr;
    display: inline-block;
}

.guide-arrow {
    color: var(--text-muted);
    font-size: 0.85rem;
    flex-shrink: 0;
}

.guide-preview-header {
    font-weight: 700;
    color: var(--primary);
}

.guide-preview-note {
    color: var(--text-muted);
    font-style: italic;
}

.guide-example {
    background: var(--bg-main);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 14px 16px;
}

.guide-example-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.guide-example-code {
    font-family: 'Courier New', monospace;
    font-size: 0.82rem;
    line-height: 1.8;
    color: var(--text-main);
    white-space: pre-wrap;
    margin: 0;
    direction: rtl;
    text-align: right;
}

@media (max-width: 600px) {
    .guide-grid {
        grid-template-columns: 1fr;
    }
}