/* ═══════════════════════════════════════════════════════════
   Consulator · Shared Arabic RTL Stylesheet
   Fonts: Cairo + Tajawal (Google Fonts, loaded in <head>)
   ═══════════════════════════════════════════════════════════ */

/* ── Variables ──────────────────────────────────────────── */
:root {
  --brand-blue:        #3F6177;
  --brand-blue-dark:   #2D4B5F;
  --brand-blue-deeper: #1E3A4C;
  --brand-orange:      #C96A1A;
  --brand-orange-dark: #B25B12;
  --brand-orange-glow: rgba(201,106,26,.15);
  --bg:           #F6F8FA;
  --bg-soft:      #EEF4F7;
  --bg-cream:     #FBF7F2;
  --surface:      #FFFFFF;
  --text:         #1F2937;
  --text-muted:   #667085;
  --text-light:   #98A2B3;
  --border:       #DDE5EC;
  --success:      #15803D;
  --whatsapp:     #25D366;
  --shadow:       0 8px 32px rgba(38,69,87,.10);
  --shadow-lg:    0 20px 60px rgba(38,69,87,.14);
  --radius:       16px;
  --radius-lg:    24px;
  --font:         'Cairo', 'Tajawal', sans-serif;
  --header-h:     72px;
}

/* ── Reset ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  direction: rtl;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
button { border: none; background: none; cursor: pointer; font-family: inherit; }
.container { width: min(1140px, calc(100% - 32px)); margin: 0 auto; }
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* ── Animations ─────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes slideRight {
  from { transform: translateX(100%); }
  to   { transform: translateX(0); }
}
@keyframes slideUp {
  from { transform: translateY(100%); }
  to   { transform: translateY(0); }
}

/* ═══════════════════════════════════════════════════════════
   HEADER
   ═══════════════════════════════════════════════════════════ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow .3s;
}
.site-header.scrolled { box-shadow: 0 4px 24px rgba(38,69,87,.1); }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 12px;
}
.logo-area { display: flex; align-items: center; gap: 10px; }
.logo-area img { height: 48px; width: auto; }
.logo-text strong { display: block; color: var(--brand-blue-dark); font-size: 1.05rem; }
.logo-text span   { display: block; color: var(--text-muted); font-size: .78rem; }

.header-nav { display: flex; align-items: center; gap: 6px; }
.header-nav a {
  padding: 8px 14px;
  border-radius: 10px;
  font-size: .85rem;
  font-weight: 600;
  color: var(--text);
  transition: .2s;
}
.header-nav a:hover,
.header-nav a.active { background: var(--bg-soft); color: var(--brand-blue); }
.header-nav a[aria-current="page"] { color: var(--brand-orange); font-weight: 700; }

.header-wa {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--whatsapp);
  color: #fff;
  padding: 9px 18px;
  border-radius: 30px;
  font-size: .82rem;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(37,211,102,.3);
  transition: .2s;
  white-space: nowrap;
}
.header-wa:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(37,211,102,.4); }

/* Mobile toggle */
.mobile-toggle {
  display: none;
  width: 40px; height: 40px;
  border-radius: 10px;
  align-items: center; justify-content: center;
  background: var(--bg-soft);
}
.mobile-toggle span { display: block; width: 20px; height: 2px; background: var(--text); border-radius: 2px; transition: .3s; }
.mobile-toggle span + span { margin-top: 5px; }

/* Mobile drawer */
.mobile-drawer {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99;
  background: rgba(0,0,0,.5);
  backdrop-filter: blur(4px);
}
.mobile-drawer.open { display: block; }
.drawer-panel {
  position: absolute;
  top: 0; right: 0;
  width: 280px; height: 100%;
  background: var(--surface);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  animation: slideRight .3s ease;
}
.drawer-close { align-self: flex-start; font-size: 1.4rem; color: var(--text-muted); padding: 4px 8px; }
.drawer-panel a {
  display: block;
  padding: 12px 16px;
  border-radius: 12px;
  font-weight: 600;
  color: var(--text);
  transition: .2s;
}
.drawer-panel a:hover { background: var(--bg-soft); }

@media (max-width: 820px) {
  .header-nav { display: none; }
  .mobile-toggle { display: flex; }
}

/* ═══════════════════════════════════════════════════════════
   HERO
   ═══════════════════════════════════════════════════════════ */
.hero {
  position: relative;
  background: linear-gradient(145deg, var(--brand-blue-deeper), var(--brand-blue), #4E7B94);
  padding: 80px 0 90px;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 600px 400px at 20% 80%, rgba(201,106,26,.12), transparent),
    radial-gradient(ellipse 400px 300px at 80% 20%, rgba(255,255,255,.06), transparent);
  pointer-events: none;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0; right: 0;
  height: 60px;
  background: linear-gradient(to top, var(--bg), transparent);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 40px;
  align-items: center;
  position: relative;
  z-index: 1;
}
.hero-eyebrow {
  display: inline-block;
  background: rgba(255,255,255,.12);
  color: rgba(255,255,255,.9);
  padding: 6px 16px;
  border-radius: 30px;
  font-size: .8rem;
  font-weight: 600;
  margin-bottom: 18px;
  animation: fadeInUp .6s ease;
}
.hero h1 {
  color: #fff;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 800;
  line-height: 1.45;
  margin-bottom: 16px;
  animation: fadeInUp .6s .1s ease both;
}
.hero h1 span { color: var(--brand-orange); }
.hero-desc {
  color: rgba(255,255,255,.82);
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 28px;
  animation: fadeInUp .6s .2s ease both;
}
.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  animation: fadeInUp .6s .3s ease both;
}
.btn-hero-primary {
  background: linear-gradient(135deg, var(--brand-orange), var(--brand-orange-dark));
  color: #fff;
  padding: 14px 28px;
  border-radius: 14px;
  font-size: .95rem;
  font-weight: 700;
  box-shadow: 0 8px 24px rgba(201,106,26,.3);
  transition: .25s;
}
.btn-hero-primary:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(201,106,26,.4); }
.btn-hero-secondary {
  background: rgba(255,255,255,.12);
  color: #fff;
  padding: 14px 28px;
  border-radius: 14px;
  font-size: .95rem;
  font-weight: 600;
  border: 1px solid rgba(255,255,255,.2);
  transition: .25s;
}
.btn-hero-secondary:hover { background: rgba(255,255,255,.2); }
.hero-card {
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius-lg);
  padding: 32px;
  backdrop-filter: blur(8px);
  animation: fadeInUp .6s .25s ease both;
}
.hero-card h3 { color: #fff; font-size: 1.15rem; margin-bottom: 16px; }
.hero-card ul { list-style: none; }
.hero-card li {
  color: rgba(255,255,255,.85);
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .92rem;
}
.hero-card li:last-child { border-bottom: none; }
.hero-card li::before {
  content: '✓';
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(201,106,26,.25);
  color: var(--brand-orange);
  font-size: .7rem;
  font-weight: 800;
  flex-shrink: 0;
}

@media (max-width: 820px) {
  .hero { padding: 50px 0 60px; }
  .hero-grid { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════════
   STATISTICS BAR
   ═══════════════════════════════════════════════════════════ */
.stats-bar {
  position: relative;
  z-index: 2;
  margin-top: -50px;
  margin-bottom: 40px;
}
.stats-inner {
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  overflow: hidden;
}
.stat-item {
  text-align: center;
  padding: 28px 16px;
  border-left: 1px solid var(--border);
  transition: .2s;
}
.stat-item:last-child { border-left: none; }
.stat-item:hover { background: var(--bg-soft); }
.stat-num { font-size: 1.8rem; font-weight: 800; color: var(--brand-blue-dark); line-height: 1; }
.stat-num span { color: var(--brand-orange); font-size: 1rem; }
.stat-label { color: var(--text-muted); font-size: .82rem; margin-top: 6px; }

@media (max-width: 600px) {
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
  .stat-item { border-bottom: 1px solid var(--border); }
  .stat-item:nth-child(odd) { border-left: 1px solid var(--border); }
  .stat-item:nth-child(even) { border-left: none; }
  .stat-item:nth-last-child(-n+2) { border-bottom: none; }
}

/* ═══════════════════════════════════════════════════════════
   SECTIONS & CARDS
   ═══════════════════════════════════════════════════════════ */
.section { padding: 70px 0; }
.section-tag {
  display: inline-block;
  background: var(--brand-orange-glow);
  color: var(--brand-orange);
  padding: 4px 14px;
  border-radius: 30px;
  font-size: .78rem;
  font-weight: 700;
  margin-bottom: 12px;
}
.section-title {
  font-size: clamp(1.3rem, 3vw, 1.8rem);
  font-weight: 800;
  color: var(--brand-blue-dark);
  margin-bottom: 10px;
}
.section-desc {
  color: var(--text-muted);
  font-size: .95rem;
  margin-bottom: 40px;
  max-width: 600px;
}

/* Services Grid */
.services-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.service-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  border: 1px solid var(--border);
  transition: .3s;
  position: relative;
  overflow: hidden;
}
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.service-card::before {
  content: '';
  position: absolute; top: 0; right: 0;
  width: 100px; height: 100px;
  border-radius: 0 0 0 100%;
  opacity: .06; transition: .3s;
}
.service-card:nth-child(1)::before { background: var(--brand-blue); }
.service-card:nth-child(2)::before { background: var(--brand-orange); }
.service-card:nth-child(3)::before { background: #15803D; }
.service-card:nth-child(4)::before { background: #7C3AED; }
.service-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 16px;
}
.service-card:nth-child(1) .service-icon { background: #EEF4F7; }
.service-card:nth-child(2) .service-icon { background: #FFF5EB; }
.service-card:nth-child(3) .service-icon { background: #ECFDF5; }
.service-card:nth-child(4) .service-icon { background: #F3EEFF; }
.service-card h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; color: var(--brand-blue-dark); }
.service-card p  { color: var(--text-muted); font-size: .88rem; line-height: 1.7; margin-bottom: 16px; }
.service-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: .85rem; font-weight: 700;
  color: var(--brand-orange); transition: .2s;
}
.service-link:hover { gap: 10px; }
.service-link::after { content: '←'; transition: .2s; }
.chat-trigger {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--brand-blue); color: #fff;
  padding: 9px 18px; border-radius: 10px;
  font-size: .82rem; font-weight: 600;
  transition: .2s; margin-top: 4px;
}
.chat-trigger:hover { background: var(--brand-blue-dark); }

/* Tools Grid */
.tools-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.tool-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 28px 24px;
  text-align: center;
  transition: .3s;
}
.tool-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.tool-emoji { font-size: 2.2rem; margin-bottom: 12px; }
.tool-card h4 { font-size: .98rem; font-weight: 700; color: var(--brand-blue-dark); margin-bottom: 6px; }
.tool-card p  { color: var(--text-muted); font-size: .82rem; margin-bottom: 16px; }
.tool-btn {
  display: inline-block;
  background: var(--bg-soft); color: var(--brand-blue);
  padding: 8px 20px; border-radius: 10px;
  font-size: .82rem; font-weight: 700; transition: .2s;
}
.tool-btn:hover { background: var(--brand-blue); color: #fff; }

@media (max-width: 700px) {
  .services-grid,
  .tools-grid { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════════
   FAQ ACCORDION
   ═══════════════════════════════════════════════════════════ */
.faq-section { background: var(--bg-soft); }
.faq-list {
  max-width: 780px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.faq-item {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: .2s;
}
.faq-item.open { border-color: var(--brand-orange); }
.faq-q {
  width: 100%;
  padding: 18px 22px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
  font-size: .92rem; font-weight: 700;
  color: var(--text);
  text-align: right; transition: .2s;
}
.faq-q:hover { color: var(--brand-orange); }
.faq-chevron {
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--bg-soft);
  display: flex; align-items: center; justify-content: center;
  font-size: .7rem;
  flex-shrink: 0;
  transition: .3s;
  color: var(--text-muted);
}
.faq-item.open .faq-chevron { transform: rotate(180deg); background: var(--brand-orange-glow); color: var(--brand-orange); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .35s ease; }
.faq-a-inner { padding: 0 22px 18px; color: var(--text-muted); font-size: .88rem; line-height: 1.8; }

/* ═══════════════════════════════════════════════════════════
   CTA SECTION
   ═══════════════════════════════════════════════════════════ */
.cta-section {
  background: linear-gradient(145deg, var(--brand-blue-deeper), var(--brand-blue));
  padding: 70px 0;
  text-align: center;
}
.cta-section h2 { color: #fff; font-size: clamp(1.2rem, 3vw, 1.7rem); margin-bottom: 14px; }
.cta-section p  { color: rgba(255,255,255,.75); font-size: .95rem; margin-bottom: 28px; max-width: 500px; margin-inline: auto; }
.cta-wa {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--whatsapp); color: #fff;
  padding: 16px 32px; border-radius: 16px;
  font-size: 1rem; font-weight: 700;
  box-shadow: 0 8px 28px rgba(37,211,102,.35);
  transition: .25s;
}
.cta-wa:hover { transform: translateY(-3px); box-shadow: 0 12px 36px rgba(37,211,102,.45); }

/* ═══════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════ */
.site-footer {
  background: var(--brand-blue-deeper);
  color: rgba(255,255,255,.9);
  padding: 42px 0 26px;
}
.footer-grid {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.footer-brand img { height: 56px; width: auto; filter: brightness(1.3); }
.footer-links { display: flex; gap: 16px; flex-wrap: wrap; }
.footer-links a { color: rgba(255,255,255,.85); font-size: .85rem; transition: .2s; }
.footer-links a:hover { color: var(--brand-orange); }
.footer-meta { margin-top: 10px; font-size: .82rem; color: rgba(255,255,255,.55); }

/* ═══════════════════════════════════════════════════════════
   FLOATING WHATSAPP
   ═══════════════════════════════════════════════════════════ */
.wa-float {
  position: fixed;
  left: 20px; bottom: 20px;
  z-index: 80;
  width: 58px; height: 58px;
  border-radius: 50%;
  background: var(--whatsapp); color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 24px rgba(37,211,102,.4);
  transition: .25s;
}
.wa-float:hover { transform: scale(1.1); }

/* ═══════════════════════════════════════════════════════════
   CHATBOT OVERLAY
   ═══════════════════════════════════════════════════════════ */
.chat-overlay {
  position: fixed; inset: 0;
  z-index: 200;
  background: rgba(0,0,0,.6);
  backdrop-filter: blur(6px);
  display: none;
  align-items: flex-end; justify-content: center;
}
.chat-overlay.open { display: flex; }
.chat-panel {
  width: 100%; max-width: 480px;
  height: 85dvh;
  background: var(--surface);
  border-radius: 24px 24px 0 0;
  display: flex; flex-direction: column;
  overflow: hidden;
  animation: slideUp .3s cubic-bezier(.16,1,.3,1);
}
.chat-header {
  background: linear-gradient(135deg, var(--brand-blue-dark), var(--brand-blue));
  padding: 16px 20px;
  display: flex; align-items: center; gap: 12px;
  flex-shrink: 0;
}
.chat-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,.15);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
}
.chat-header-info { flex: 1; }
.chat-header-info strong { color: #fff; font-size: .9rem; display: block; }
.chat-header-info small  { color: rgba(255,255,255,.65); font-size: .72rem; }
.chat-close-btn { color: rgba(255,255,255,.6); font-size: 1.2rem; padding: 4px 8px; }
.chat-messages {
  flex: 1; overflow-y: auto;
  padding: 18px;
  display: flex; flex-direction: column; gap: 10px;
}
.chat-msg {
  max-width: 85%;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: .85rem; line-height: 1.65;
}
.chat-msg.bot  { align-self: flex-start; background: var(--bg-soft); color: var(--text); border-bottom-right-radius: 4px; }
.chat-msg.user { align-self: flex-end; background: var(--brand-blue); color: #fff; border-bottom-left-radius: 4px; }
.chat-topics { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.chat-topic-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 8px 14px;
  font-size: .78rem; font-weight: 600;
  color: var(--brand-blue); transition: .2s;
}
.chat-topic-btn:hover { background: var(--brand-blue); color: #fff; border-color: var(--brand-blue); }
.chat-input-wrap {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  display: flex; gap: 8px; flex-shrink: 0;
}
.chat-input {
  flex: 1;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px 14px;
  font-family: var(--font);
  font-size: .85rem;
  outline: none;
  direction: rtl;
}
.chat-input:focus { border-color: var(--brand-blue); box-shadow: 0 0 0 3px rgba(63,97,119,.12); }
.chat-send {
  background: var(--brand-orange); color: #fff;
  width: 42px; height: 42px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; transition: .2s;
}
.chat-send:hover { background: var(--brand-orange-dark); }

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .hero { padding: 40px 0 50px; }
  .hero-actions { flex-direction: column; }
  .btn-hero-primary, .btn-hero-secondary { width: 100%; text-align: center; }
  .section { padding: 48px 0; }
  .footer-grid { flex-direction: column; text-align: center; }
}
