/* =========================================
   1. TECH DESIGN SYSTEM VARIABLES
   ========================================= */
:root {
    --primary: #174388;       
    --secondary: #d5242b;     
    --primary-glow: rgba(23, 67, 136, 0.4);
    --secondary-glow: rgba(213, 36, 43, 0.5);
    --bg-main: #f4f7fb;
    --bg-surface: #ffffff;
    --bg-dark-tech: #070e1c;
    --text-main: #1e293b;
    --text-muted: #475569;
    --border-color: #cbd5e1;
    --tech-border: 1px solid var(--primary);
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-dark: rgba(7, 14, 28, 0.75);
    --glass-border: rgba(23, 67, 136, 0.3);
    --radius: 0px; 
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* { 
    margin: 0; padding: 0; box-sizing: border-box; 
    border-radius: var(--radius) !important; 
}

body { 
    font-family: 'Tajawal', sans-serif; 
    color: var(--text-main); 
    background-color: var(--bg-main);
    background-image: 
        linear-gradient(rgba(23, 67, 136, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(23, 67, 136, 0.04) 1px, transparent 1px);
    background-size: 30px 30px; line-height: 1.6; overflow-x: hidden;
}

@media (hover: hover) and (pointer: fine) { html, a, button, input, textarea, .faq-question { cursor: none; } }
h1, h2, h3, h4, h5, h6 { font-family: 'Cairo', sans-serif; color: var(--primary); text-transform: uppercase; letter-spacing: 1px; }
p { color: var(--text-muted); }
a { text-decoration: none; color: var(--primary); transition: var(--transition); }
ul { list-style: none; }
.text-red { color: var(--secondary) !important; } .text-white { color: #fff !important; }

/* =========================================
   2. BRAND LOGO
   ========================================= */
.brand-logo { max-height: 50px; width: auto; object-fit: contain; display: block; }

/* =========================================
   3. CUSTOM TECH CURSOR & PROGRESS BAR
   ========================================= */
#tech-cursor { position: fixed; width: 6px; height: 6px; background: var(--secondary); pointer-events: none; transform: translate(-50%, -50%); z-index: 9999; transition: width 0.2s, height 0.2s; box-shadow: 0 0 10px var(--secondary); }
#tech-cursor-follower { position: fixed; width: 30px; height: 30px; border: 1px solid var(--primary); pointer-events: none; transform: translate(-50%, -50%); z-index: 9998; transition: width 0.3s, height 0.3s, border-color 0.3s, transform 0.1s; transition-timing-function: ease-out; }
#progress-bar { position: fixed; top: 0; left: 0; height: 3px; background: linear-gradient(90deg, var(--primary), var(--secondary)); width: 0%; z-index: 10001; transition: width 0.1s; box-shadow: 0 0 10px var(--secondary-glow); }
.animated-lines-container { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; overflow: hidden; opacity: 0.6; }
.data-stream { position: absolute; width: 1px; background: linear-gradient(to bottom, transparent, var(--primary), transparent); animation: streamFall linear infinite; }
@keyframes streamFall { 0% { transform: translateY(-100%); opacity: 0; } 50% { opacity: 1; box-shadow: 0 0 5px var(--primary); } 100% { transform: translateY(100vh); opacity: 0; } }

/* =========================================
   4. UTILITIES & LAYOUT
   ========================================= */
.container { max-width: 1280px; margin: 0 auto; padding: 0 5%; position: relative; z-index: 2; }
.section { padding: 100px 0; }
.glass-section { background: var(--glass-bg); border-top: var(--tech-border); border-bottom: var(--tech-border); backdrop-filter: blur(10px); }
.grid { display: grid; gap: 30px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.mt-4 { margin-top: 1.5rem; } .mt-5 { margin-top: 2.5rem; } .mb-4 { margin-bottom: 1.5rem; }
.text-center { text-align: center; } .text-left { text-align: left; } .w-full { width: 100%; }
.hidden { display: none !important; }

.section-header { margin-bottom: 50px; text-align: center; }
.section-header h2 { font-size: clamp(1.8rem, 4vw, 2.5rem); font-weight: 900; margin-bottom: 15px; text-shadow: 2px 2px 0px rgba(23,67,136,0.1); }
.header-line { width: 80px; height: 3px; background: var(--secondary); margin: 0 auto; position: relative; }
.header-line::after { content: ''; position: absolute; right: -15px; top: 0; width: 10px; height: 3px; background: var(--primary); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 12px 28px; font-family: 'Cairo', sans-serif; font-weight: 700; border: none; transition: var(--transition); letter-spacing: 1px; text-transform: uppercase; font-size: 0.9rem; }
.btn-tech { background: var(--primary); color: #fff; box-shadow: 4px 4px 0 var(--primary-glow); position: relative; overflow: hidden; border: 1px solid var(--primary); }
.btn-tech::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent); transition: 0.5s; }
.btn-tech:hover::before { left: 100%; }
.btn-tech:hover { background: #0f306b; transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--primary-glow); color: #fff; }
.btn-outline-tech { background: transparent; border: 1px solid var(--primary); color: var(--primary); box-shadow: 2px 2px 0 var(--primary-glow); }
.btn-outline-tech:hover { background: var(--primary); color: #fff; transform: translate(-2px, -2px); box-shadow: 4px 4px 0 var(--primary-glow); }
.btn-danger { background: transparent; border: 1px solid var(--secondary); color: var(--secondary); box-shadow: 2px 2px 0 var(--secondary-glow); }
.btn-danger:hover { background: var(--secondary); color: #fff; }

.tech-card { background: var(--bg-surface); padding: 40px 30px; border: 1px solid var(--border-color); border-left: 4px solid var(--primary); transition: var(--transition); position: relative; overflow: hidden; }
.tech-card:hover { transform: translateY(-5px); border-left-color: var(--secondary); box-shadow: 0 15px 30px var(--primary-glow); }
.icon-box { width: 60px; height: 60px; background: rgba(23, 67, 136, 0.05); border: 1px solid var(--primary); color: var(--primary); display: flex; justify-content: center; align-items: center; font-size: 1.8rem; margin-bottom: 20px; transition: var(--transition); }
.tech-card:hover .icon-box { background: var(--primary); color: #fff; transform: rotate(15deg); box-shadow: 0 0 15px var(--primary-glow); }
.tech-card h3 { font-size: 1.3rem; margin-bottom: 12px; }

.tech-card-horizontal { display: flex; gap: 20px; align-items: flex-start; padding: 30px; background: var(--bg-surface); border: 1px solid var(--border-color); border-bottom: 3px solid var(--primary); transition: var(--transition); }
.tech-card-horizontal:hover { border-bottom-color: var(--secondary); box-shadow: 0 10px 20px var(--primary-glow); transform: scale(1.02); }
.core-img-box { width: 80px; height: 80px; background: rgba(23, 67, 136, 0.05); border: 1px solid var(--primary); display: flex; justify-content: center; align-items: center; transition: var(--transition); flex-shrink: 0; overflow: hidden; }
.core-img-box img { width: 100%; height: 100%; object-fit: cover; transition: var(--transition); }
.tech-card-horizontal:hover .core-img-box { border-color: var(--secondary); box-shadow: 0 0 15px var(--primary-glow); transform: rotate(5deg); }
.tech-card-horizontal:hover .core-img-box img { transform: scale(1.1); }

.glass-panel { background: var(--glass-dark); backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px); border: 1px solid var(--glass-border); }

/* =========================================
   5. HEADER & NAV
   ========================================= */
.tech-header { position: fixed; top: 0; left: 0; width: 100%; z-index: 1000; background: var(--glass-bg); backdrop-filter: blur(20px); border-bottom: 1px solid var(--border-color); transition: var(--transition); }
.tech-header.scrolled { box-shadow: 0 4px 20px rgba(0,0,0,0.1); padding: 5px 0; background: rgba(255, 255, 255, 0.95); }
.header-container { display: flex; justify-content: space-between; align-items: center; height: 85px; }

.desktop-nav .nav-links { display: flex; gap: 30px; }
.desktop-nav a { font-family: 'Cairo', sans-serif; font-weight: 700; color: var(--text-main); font-size: 0.95rem; text-transform: uppercase; position: relative; padding: 5px 0; }
.desktop-nav a::after { content: ''; position: absolute; left: 0; bottom: 0; width: 0; height: 2px; background: var(--secondary); transition: var(--transition); }
.desktop-nav a:hover::after, .desktop-nav a.active::after { width: 100%; }
.desktop-nav a:hover, .desktop-nav a.active { color: var(--primary); }
.header-actions { display: flex; align-items: center; gap: 15px; }

.profile-trigger { display: flex; align-items: center; gap: 10px; padding: 5px 15px; border: 1px solid var(--border-color); font-weight: bold; color: var(--primary); transition: var(--transition); cursor: pointer; }
.profile-trigger:hover { background: var(--bg-main); border-color: var(--primary); }
.avatar-glow { background: rgba(23,67,136,0.1); width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--primary); }
.user-profile { position: relative; }
.tech-dropdown { position: absolute; top: calc(100% + 15px); right: 0; background: #fff; border: 1px solid var(--border-color); box-shadow: 0 10px 30px rgba(0,0,0,0.1); width: 180px; opacity: 0; visibility: hidden; transform: translateY(10px); transition: var(--transition); z-index: 100; }
.user-profile.active .tech-dropdown { opacity: 1; visibility: visible; transform: translateY(0); border-top: 3px solid var(--secondary); }
.tech-dropdown li a { display: flex; align-items: center; gap: 10px; padding: 12px 15px; color: var(--text-main); border-bottom: 1px solid var(--border-color); font-weight: 600; font-family: 'Cairo', sans-serif; text-transform: uppercase; font-size: 0.85rem; }
.tech-dropdown li a:hover { background: var(--bg-main); color: var(--primary); padding-left: 20px; border-left: 3px solid var(--primary); }

.hamburger { display: none; flex-direction: column; gap: 6px; z-index: 1005; cursor: pointer; }
.hamburger span { width: 30px; height: 3px; background: var(--primary); transition: var(--transition); display: block; }
.mobile-nav { position: fixed; top: 0; right: -100%; width: 320px; max-width: 100vw; height: 100vh; background: rgba(255,255,255,0.98); border-left: 2px solid var(--primary); z-index: 999; display: flex; align-items: center; justify-content: center; transition: var(--transition); padding: 40px 20px; box-shadow: -10px 0 30px rgba(0,0,0,0.1); }
.mobile-nav.active { right: 0; }
.mobile-links { display: flex; flex-direction: column; gap: 15px; width: 100%; }
.mobile-links a:not(.btn) { font-family: 'Cairo', sans-serif; font-size: 1.2rem; font-weight: 700; color: var(--primary); border-bottom: 1px solid var(--border-color); padding-bottom: 10px; display: block; text-transform: uppercase; }

/* =========================================
   6. HERO SECTION
   ========================================= */
.hero { min-height: 100vh; display: flex; align-items: center; padding-top: 80px; position: relative; }
.hero::before { content: ''; position: absolute; right: 0; top: 0; width: 50%; height: 100%; background: linear-gradient(90deg, transparent, rgba(23,67,136,0.05)); z-index: 0; pointer-events: none; }
.hero-container { display: flex; align-items: center; gap: 50px; background: var(--bg-surface); padding: 50px; border: 1px solid var(--border-color); box-shadow: 10px 10px 0 rgba(23,67,136,0.05); transform-style: preserve-3d; }
.hero-content { flex: 1; transform: translateZ(30px); }
.tech-badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 15px; background: rgba(213, 36, 43, 0.1); color: var(--secondary); font-weight: bold; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 20px; border: 1px solid rgba(213, 36, 43, 0.3); box-shadow: 2px 2px 0 rgba(213, 36, 43, 0.2); }
.hero-content .title { font-size: clamp(2.5rem, 6vw, 4.5rem); line-height: 1.1; margin-bottom: 20px; font-weight: 900; }
.hero-content .title .highlight { color: transparent; -webkit-text-stroke: 2px var(--primary); position: relative; }
.hero-content .title .highlight::before { content: attr(data-text); position: absolute; left: 0; top: 0; color: var(--primary); width: 0; overflow: hidden; animation: fillText 3s linear forwards; }
@keyframes fillText { 100% { width: 100%; } }
.hero-content .description { font-size: 1.1rem; margin-bottom: 30px; max-width: 500px; font-weight: 500; }

/* Video Frame (Updated for Vertical Video) */
.hero-video-box { 
    flex: 1; 
    transform: translateZ(50px); 
    width: 100%; 
    display: flex; 
    justify-content: center; /* توسيط الفيديو داخل النصف الخاص به */
    align-items: center;
}
.video-frame { 
    position: relative; 
    padding: 15px; 
    border: 1px solid var(--primary); 
    background: var(--bg-main); 
    width: 100%; 
    max-width: 320px; /* تحديد أقصى عرض حتى لا يصبح الفيديو طويلاً جداً */
    margin: 0 auto;
}
.video-frame video { 
    width: 100%; 
    height: auto; 
    aspect-ratio: 9/16; /* إجبار المتصفح على قراءة نسبة الفيديو الطولية */
    object-fit: cover; 
    display: block; 
    box-shadow: 0 10px 30px var(--primary-glow); 
    filter: contrast(1.1); 
}
.frame-corners { position: absolute; top: -5px; left: -5px; width: calc(100% + 10px); height: calc(100% + 10px); pointer-events: none; }
.frame-corners::before, .frame-corners::after { content: ''; position: absolute; width: 40px; height: 40px; border: 4px solid var(--secondary); }
.frame-corners::before { top: 0; left: 0; border-right: none; border-bottom: none; }
.frame-corners::after { bottom: 0; right: 0; border-left: none; border-top: none; }

/* =========================================
   7. SYSTEMS (DARK TECH SECTION)
   ========================================= */
.dark-tech-section { background-color: var(--bg-dark-tech); color: #fff; position: relative; border-top: 1px solid var(--glass-border); border-bottom: 1px solid var(--glass-border); }
.dark-tech-section::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(circle at center, rgba(23,67,136,0.3) 0%, transparent 70%); pointer-events: none; }
.glow-line { background: var(--primary); box-shadow: 0 0 15px var(--primary); }
.system-card { padding: 40px; text-align: center; border-top: 4px solid var(--primary); transition: var(--transition); transform-style: preserve-3d; background: rgba(7, 14, 28, 0.8); }
.system-card:hover { border-top-color: var(--secondary); box-shadow: 0 10px 40px rgba(23,67,136,0.4); }
.sys-icon { font-size: 3.5rem; color: #fff; margin-bottom: 20px; text-shadow: 0 0 20px var(--primary); transform: translateZ(20px); display: inline-block; }
.system-card h3 { color: #fff; font-size: 1.5rem; margin-bottom: 15px; transform: translateZ(10px); }
.system-card p { color: #94a3b8; margin-bottom: 25px; transform: translateZ(5px); }
.sys-link { display: inline-flex; align-items: center; gap: 8px; color: var(--primary); font-weight: bold; padding: 10px 20px; border: 1px solid var(--primary); transform: translateZ(15px); text-transform: uppercase; font-size: 0.9rem; }
.system-card:hover .sys-link { background: var(--primary); color: #fff; box-shadow: 0 0 15px var(--primary-glow); }

/* =========================================
   8. TESTIMONIALS & FAQ & CONTACT
   ========================================= */
.testimonial-card { background: var(--bg-surface); padding: 40px; text-align: center; border: 1px solid var(--border-color); border-bottom: 3px solid var(--primary); margin: 20px 10px; box-shadow: 5px 5px 0 rgba(23,67,136,0.05); }
.quote-mark { font-size: 2.5rem; color: rgba(23,67,136,0.1); margin-bottom: 20px; }
.testimonial-card h4 { color: var(--primary); margin: 15px 0 5px; }
.swiper-pagination-bullet { width: 12px !important; height: 12px !important; background: var(--border-color) !important; border-radius: 0 !important; opacity: 1 !important; transition: var(--transition); }
.swiper-pagination-bullet-active { background: var(--primary) !important; transform: scale(1.3); border: 1px solid var(--secondary); }

.faq-item { border: 1px solid var(--border-color); margin-bottom: 15px; background: var(--bg-surface); border-left: 4px solid var(--primary); transition: var(--transition); cursor: pointer; }
.faq-item:hover { border-left-color: var(--secondary); }
.faq-question { padding: 20px; display: flex; justify-content: space-between; align-items: center; font-weight: bold; color: var(--text-main); font-family: 'Cairo', sans-serif; text-transform: uppercase; font-size: 0.95rem; }
.faq-question i { color: var(--primary); transition: transform 0.3s; }
.faq-answer { padding: 0 20px; max-height: 0; overflow: hidden; transition: all 0.4s ease; background: var(--bg-main); color: var(--text-muted); }
.faq-item.active .faq-question i { transform: rotate(45deg); color: var(--secondary); }
.faq-item.active .faq-answer { padding: 20px; max-height: 300px; border-top: 1px solid var(--border-color); }

.info-item { display: flex; align-items: center; gap: 15px; margin-bottom: 15px; font-weight: 500; font-size: 1.1rem; }
.info-item i { color: var(--secondary); font-size: 1.2rem; width: 25px; text-align: center; }

.input-group { position: relative; margin-bottom: 20px; }
.input-group i { position: absolute; top: 16px; left: 16px; color: var(--primary); opacity: 0.6; }
.input-group input, .input-group textarea { width: 100%; padding: 15px 15px 15px 45px; border: 1px solid var(--border-color); background: var(--bg-main); color: var(--text-main); font-family: inherit; transition: var(--transition); font-size: 1rem; }
.input-group input:focus, .input-group textarea:focus { outline: none; border-color: var(--primary); background: #fff; box-shadow: inset 4px 0 0 var(--secondary); }
.input-group input:focus + i, .input-group textarea:focus + i { opacity: 1; color: var(--secondary); }

/* =========================================
   9. FOOTER
   ========================================= */
.tech-footer { background: var(--bg-surface); border-top: 3px solid var(--primary); padding: 80px 0 20px; position: relative; }
.footer-logo p { font-weight: 500; }
.social-links a { display: inline-flex; width: 40px; height: 40px; background: var(--bg-main); border: 1px solid var(--border-color); justify-content: center; align-items: center; color: var(--primary); margin-right: 10px; transition: var(--transition); }
.social-links a:hover { background: var(--primary); color: #fff; border-color: var(--primary); transform: translateY(-3px) rotate(5deg); box-shadow: 4px 4px 0 var(--primary-glow); }

.footer-links h4, .footer-divisions h4, .footer-language h4 { font-size: 1.1rem; margin-bottom: 20px; text-transform: uppercase; color: var(--primary); letter-spacing: 1px; }
.footer-links ul li, .footer-divisions ul li { margin-bottom: 10px; }
.footer-links ul li a, .footer-divisions ul li a { color: var(--text-muted); font-weight: 500; display: inline-block; transition: var(--transition); }
.footer-links ul li a:hover, .footer-divisions ul li a:hover { color: var(--secondary); transform: translateX(5px); }

.custom-dropdown { position: relative; }
.dropdown-trigger { display: flex; justify-content: space-between; align-items: center; padding: 12px 15px; border: 1px solid var(--border-color); background: var(--bg-main); font-weight: bold; color: var(--primary); transition: var(--transition); cursor: pointer; }
.dropdown-trigger:hover { border-color: var(--primary); }
.footer-language .tech-dropdown { top: auto; bottom: calc(100% + 15px); transform: translateY(10px); }
.custom-dropdown.active .tech-dropdown { opacity: 1; visibility: visible; transform: translateY(0); border-top: none; border-bottom: 3px solid var(--secondary); }
.footer-bottom { border-top: 1px solid var(--border-color); margin-top: 50px; padding-top: 20px; color: var(--text-muted); font-size: 0.9rem; font-weight: 600; }

/* =========================================
   10. CHAT WIDGET
   ========================================= */
.chat-widget { position: fixed; bottom: 30px; right: 30px; z-index: 1000; }
.chat-btn { width: 60px; height: 60px; background: var(--primary); color: #fff; border: 1px solid var(--primary); font-size: 1.5rem; box-shadow: 0 0 15px var(--primary-glow); transition: var(--transition); display: flex; justify-content: center; align-items: center; cursor: pointer;}
.chat-btn:hover { background: var(--secondary); border-color: var(--secondary); transform: scale(1.1); box-shadow: 0 0 25px var(--secondary-glow); }
.chat-container { position: absolute; bottom: 80px; right: 0; width: 350px; max-width: calc(100vw - 40px); background: #fff; border: 1px solid var(--primary); box-shadow: 10px 10px 0 rgba(23,67,136,0.1); opacity: 0; visibility: hidden; transform: translateY(20px); transition: var(--transition); display: flex; flex-direction: column; }
.chat-container.active { opacity: 1; visibility: visible; transform: translateY(0); }
.chat-header { background: var(--primary); color: #fff; padding: 15px; display: flex; justify-content: space-between; align-items: center; border-bottom: 2px solid var(--secondary); }
.chat-header h3 { color: #fff; font-size: 1.1rem; margin: 0; letter-spacing: 1px; }
.chat-close { background: none; border: none; color: #fff; font-size: 1.5rem; cursor: pointer; transition: var(--transition); }
.chat-close:hover { color: var(--secondary); transform: rotate(90deg); }
.chat-body { padding: 15px; height: 300px; overflow-y: auto; background: var(--bg-main); display: flex; flex-direction: column; gap: 10px; }
.message { padding: 10px 15px; max-width: 85%; font-size: 0.95rem; border: 1px solid; }
.message.incoming { background: #fff; border-color: var(--border-color); align-self: flex-start; border-left: 3px solid var(--secondary); }
.message.outgoing { background: var(--primary); color: #fff; border-color: var(--primary); align-self: flex-end; border-right: 3px solid var(--secondary); }
.chat-footer { padding: 10px; display: flex; border-top: 1px solid var(--border-color); background: #fff; }
.chat-footer input { flex: 1; border: 1px solid var(--border-color); padding: 12px; outline: none; font-family: inherit; }
.chat-footer input:focus { border-color: var(--primary); }
.chat-footer button { background: var(--primary); color: #fff; border: 1px solid var(--primary); padding: 0 20px; transition: var(--transition); cursor: pointer;}
.chat-footer button:hover { background: var(--secondary); border-color: var(--secondary); }

/* =========================================
   11. RESPONSIVE
   ========================================= */
@media (max-width: 992px) {
    .hero-container { flex-direction: column; padding: 30px; text-align: center; }
    .hero-content, .hero-video-box { transform: none; }
    .video-frame { padding: 10px; max-width: 280px; } /* تصغير المربع الطولي قليلاً في الشاشات الأصغر */
}
@media (max-width: 768px) {
    .desktop-nav, #desktop-login-btn, #desktop-user-profile { display: none; }
    .hamburger { display: flex; }
    .hamburger.active span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
    .hamburger.active span:nth-child(2) { opacity: 0; }
    .hamburger.active span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }
    .footer-wrapper { grid-template-columns: 1fr; text-align: center; }
    .footer-links ul li a:hover, .footer-divisions ul li a:hover { transform: translateY(-2px); }
    .chat-widget { bottom: 20px; right: 20px; }
    .chat-container { right: 0; bottom: 70px; }
    .hero { padding-top: 100px; } .section { padding: 60px 0; }
}

/* =========================================
   12. RTL (ARABIC) SUPPORT OVERRIDES
   ========================================= */
[dir="rtl"] { text-align: right; }
[dir="rtl"] .text-left { text-align: right !important; }

/* Utilities */
[dir="rtl"] .header-line::after { right: auto; left: -15px; }
[dir="rtl"] .btn-tech::before { left: auto; right: -100%; }
[dir="rtl"] .btn-tech:hover::before { right: 100%; left: auto; }
[dir="rtl"] .desktop-nav a::after { left: auto; right: 0; }

/* Dropdowns & Menus */
[dir="rtl"] .tech-dropdown { right: auto; left: 0; }
[dir="rtl"] .tech-dropdown li a { padding-left: 15px; padding-right: 15px; border-left: none; border-right: 0 solid transparent; }
[dir="rtl"] .tech-dropdown li a:hover { padding-left: 15px; padding-right: 20px; border-left: none; border-right: 3px solid var(--primary); }
[dir="rtl"] .mobile-nav { right: auto; left: -100%; border-left: none; border-right: 2px solid var(--primary); }
[dir="rtl"] .mobile-nav.active { left: 0; right: auto; }

/* Cards */
[dir="rtl"] .tech-card { border-left: none; border-right: 4px solid var(--primary); }
[dir="rtl"] .tech-card:hover { border-right-color: var(--secondary); border-left-color: transparent; }
[dir="rtl"] .faq-item { border-left: none; border-right: 4px solid var(--primary); }
[dir="rtl"] .faq-item:hover { border-right-color: var(--secondary); border-left-color: transparent; }

/* Hero */
[dir="rtl"] .hero::before { right: auto; left: 0; background: linear-gradient(-90deg, transparent, rgba(23,67,136,0.05)); }
[dir="rtl"] .hero-content .title .highlight::before { left: auto; right: 0; }

/* Inputs */
[dir="rtl"] .input-group i { left: auto; right: 16px; }
[dir="rtl"] .input-group input, [dir="rtl"] .input-group textarea { padding: 15px 45px 15px 15px; }
[dir="rtl"] .input-group input:focus, [dir="rtl"] .input-group textarea:focus { box-shadow: inset -4px 0 0 var(--secondary); }

/* Footer & Chat */
[dir="rtl"] .social-links a { margin-right: 0; margin-left: 10px; }
[dir="rtl"] .footer-links ul li a:hover, [dir="rtl"] .footer-divisions ul li a:hover { transform: translateX(-5px); }
[dir="rtl"] .chat-widget { right: auto; left: 30px; }
[dir="rtl"] .chat-container { right: auto; left: 0; }
[dir="rtl"] .message.incoming { border-left: none; border-right: 3px solid var(--secondary); }
[dir="rtl"] .message.outgoing { border-right: none; border-left: 3px solid var(--secondary); }
@media (max-width: 768px) {
    [dir="rtl"] .chat-widget { left: 20px; right: auto; }
}
