:root {
  --bg: #f5f9ff;
  --surface: #ffffff;
  --text: #0a1a33;
  --muted: #47607d;
  --primary: #0d5db8;
  --primary-2: #3b82f6;
  --border: #d8e7fb;
}

body.dark {
  --bg: #071325;
  --surface: #0d1d35;
  --text: #e8f1ff;
  --muted: #a9bed9;
  --primary: #4ea1ff;
  --primary-2: #7cb8ff;
  --border: #1d3558;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; font-family: Inter, system-ui, sans-serif; color: var(--text); background: var(--bg); }
.container { width: min(1120px, 92%); margin: 0 auto; }

.site-header {
  position: sticky; top: 0; z-index: 20;
  backdrop-filter: blur(10px);
  background: rgba(245,249,255,.92);
  border-bottom: 1px solid var(--border);
}
body.dark .site-header { background: rgba(7,19,37,.92); }
.nav-wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .75rem 0; }
.brand { display: inline-flex; align-items: center; }
.logo { height: 118px; width: auto; object-fit: contain; filter: drop-shadow(0 10px 22px rgba(13,93,184,.18)); }
.header-actions { position: relative; display: flex; align-items: center; gap: .55rem; }
.icon-btn { min-width: 44px; text-align: center; }
.lang-options { display: flex; gap: .45rem; }
.lang-option-btn { min-width: 56px; }
.nav-links { list-style: none; display: flex; gap: 1rem; margin: 0; padding: 0; }
.nav-links a { color: var(--muted); text-decoration: none; font-weight: 600; transition: color .2s ease; }
.nav-links a:hover { color: var(--primary); }

.section { padding: 5rem 0; }
.section-muted { background: #eef5ff; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
body.dark .section-muted { background: #0a1a31; }

.hero { position: relative; overflow: hidden; padding-top: 6.2rem; }
.hero-bg {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(circle at 92% 16%, rgba(59,130,246,.22), transparent 35%),
    radial-gradient(circle at 18% 90%, rgba(13,93,184,.12), transparent 30%);
}
.hero-grid { position: relative; display: grid; grid-template-columns: 1.4fr 1fr; gap: 2rem; align-items: center; }
.kicker { color: var(--primary); font-weight: 800; margin-bottom: .5rem; letter-spacing: .02em; }
h1 { font-size: clamp(2rem, 4vw, 3.45rem); line-height: 1.05; margin: 0 0 1rem; }
.lead { font-size: 1.1rem; color: var(--muted); max-width: 62ch; }

.actions { display: flex; gap: .8rem; margin-top: 1.4rem; flex-wrap: wrap; }
.btn {
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  color: #fff; border: none; text-decoration: none; padding: .76rem 1.15rem;
  border-radius: .75rem; font-weight: 700; display: inline-block;
  box-shadow: 0 10px 22px rgba(13,93,184,.2);
  transition: transform .2s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 14px 28px rgba(13,93,184,.25); }
.btn-secondary { background: #fff; color: var(--primary); border: 1px solid var(--border); box-shadow: none; }

.hero-panel,
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 1.2rem;
  box-shadow: 0 14px 40px rgba(13,93,184,.08);
}
.hero-logo {
  width: min(100%, 340px);
  display: block;
  margin: .25rem auto 1rem;
  filter: drop-shadow(0 18px 30px rgba(13,93,184,.2));
}
.hero-panel ul { margin: .5rem 0 0; padding-left: 1.1rem; color: var(--muted); line-height: 1.8; }

.grid { display: grid; gap: 1rem; }
.cards-3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.card { transition: transform .24s ease, box-shadow .24s ease, border-color .24s ease; }
.card:hover { transform: translateY(-5px); box-shadow: 0 22px 42px rgba(13,93,184,.12); border-color: #c8ddfb; }
.service-card { text-decoration: none; color: inherit; display: block; }
.service-link { display: inline-block; margin-top: .65rem; color: var(--primary); font-weight: 700; font-size: .95rem; }
h2 { font-size: clamp(1.5rem, 3vw, 2.3rem); margin: 0 0 1rem; }
.max { max-width: 75ch; color: var(--muted); }
.about-grid { margin-top: 1.15rem; display: grid; gap: 1rem; grid-template-columns: repeat(3, minmax(0,1fr)); }

.contact-pro { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.contact-pro p { color: var(--muted); margin: 0; }
.contact-meta { margin-top: .55rem !important; font-size: .95rem; }
.contact-meta a { color: var(--primary); text-decoration: none; font-weight: 600; }

.site-footer {
  border-top: 1px solid var(--border);
  background:
    radial-gradient(circle at 12% 0%, rgba(59,130,246,.08), transparent 35%),
    var(--surface);
}
.foot-pro { display: grid; grid-template-columns: 1.4fr 1fr .8fr; gap: .9rem; padding: 1.25rem 0 .9rem; }
.foot-block {
  background: color-mix(in oklab, var(--surface) 88%, #fff 12%);
  border: 1px solid var(--border);
  border-radius: .9rem;
  padding: .9rem 1rem;
}
body.dark .foot-block { background: color-mix(in oklab, var(--surface) 94%, #000 6%); }
.foot-brand { display: flex; align-items: center; gap: .9rem; }
.foot-logo { height: 44px; width: auto; object-fit: contain; }
.foot-brand p { margin: 0; color: var(--muted); font-size: .94rem; }
.foot-contact { color: var(--muted); font-size: .94rem; line-height: 1.4; }
.foot-contact p { margin: 0; }
.foot-contact-title { color: var(--text); font-weight: 700; margin-bottom: .3rem !important; }
.foot-contact a { color: var(--primary); text-decoration: none; font-weight: 700; }
.foot-contact a:hover { text-decoration: underline; }
.foot-links { display: flex; flex-direction: column; gap: .45rem; }
.foot-links a { color: var(--muted); text-decoration: none; font-weight: 600; }
.foot-links a:hover { color: var(--primary); }
.foot-bottom { color: var(--muted); text-align: center; font-size: .92rem; padding: .25rem 0 1.1rem; }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .55s ease, transform .55s ease; }
.reveal.show { opacity: 1; transform: translateY(0); }
.reveal-delay { animation: floatIn .7s ease .12s both; }
@keyframes floatIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

.service-hero { margin-top: .5rem; }
.detail-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 1rem; margin-top: 1rem; }
.kpi-strip { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: .8rem; margin-top: 1rem; }
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: .8rem; padding: .8rem; }
.kpi strong { display: block; font-size: 1.2rem; color: var(--primary); }
.checklist { margin: .4rem 0 0; padding-left: 1.1rem; color: var(--muted); line-height: 1.7; }
.faq-item + .faq-item { margin-top: .65rem; }
.back-link {
  display: inline-block;
  margin-bottom: .4rem;
  color: var(--primary);
  text-decoration: none;
  font-weight: 700;
  font-size: .95rem;
}
.back-link:hover { text-decoration: underline; }

/* RTL support (Arabic) */
html[dir="rtl"] body { text-align: right; }
html[dir="rtl"] .nav-wrap,
html[dir="rtl"] .header-actions,
html[dir="rtl"] .foot-brand,
html[dir="rtl"] .foot-links { direction: rtl; }
html[dir="rtl"] .checklist { padding-right: 1.1rem; padding-left: 0; }
html[dir="rtl"] .back-link { direction: rtl; }
/* Keep technical/contact strings readable in RTL */
html[dir="rtl"] a[href^="mailto:"],
html[dir="rtl"] .contact-meta {
  direction: ltr;
  unicode-bidi: isolate;
  display: inline-block;
}
html[dir="rtl"] .phone-ltr {
  direction: ltr !important;
  unicode-bidi: plaintext;
  display: inline-block;
  text-align: left;
}

@media (max-width: 920px) {
  .hero-grid, .cards-3, .about-grid, .contact-pro, .foot-pro, .detail-grid, .kpi-strip { grid-template-columns: 1fr; display: grid; }
  .nav-links { display: none; }
  .logo { height: 92px; }
  .hero-logo { width: min(100%, 280px); }

  /* Compact language dropdown on mobile */
  .lang-options {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + .45rem);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: .8rem;
    padding: .35rem;
    box-shadow: 0 12px 28px rgba(13,93,184,.16);
    z-index: 30;
  }
  .header-actions.lang-open .lang-options { display: flex; flex-direction: column; }
  .lang-option-btn { min-width: 64px; }
}
