:root {
  --primary: #0b3568;
  --primary-light: #275a91;
  --mint: #75c566;
  --green: #01814e;
  --accent: #d9e74c;
  --blue-light: #e7ebf0;
  --green-light: #e6f2ed;
  --white: #ffffff;
  --black: #111827;
  --gray: #696969;
  --gray-text: #555555;
  --gray-muted: #757f8b;
  --nav: #9ca3af;
  --fil: #738dbc;
  --stroke: #f2f2f2;
  --shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  --radius: 16px;
  --radius-lg: 26px;
  --font: "IBM Plex Sans Arabic", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font); color: var(--black); background: var(--white); line-height: 1.4; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

.container { width: min(1280px, calc(100% - 2rem)); margin-inline: auto; }
.section { padding: 5rem 0; }
.text-primary { color: var(--primary); }
.text-accent { color: var(--accent); }
.text-muted { color: var(--fil); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.5rem 1rem; border-radius: 8px; font-weight: 500; font-size: 0.875rem;
  border: none; cursor: pointer; transition: opacity 0.2s;
}
.btn:hover { opacity: 0.9; }
.btn--primary { background: var(--primary); color: var(--white); }
.btn--mint { background: var(--mint); color: var(--white); padding: 0.875rem 2rem; font-size: 1rem; border-radius: 999px; }
.btn--sm { font-size: 0.875rem; }

/* Badge */
.badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px; border-radius: 999px; font-size: 0.875rem; font-weight: 600;
}
.badge::after { content: ""; width: 8px; height: 8px; border-radius: 50%; }
.badge--dark { background: var(--primary); color: var(--white); }
.badge--dark::after { background: var(--white); }
.badge--light { background: var(--white); color: var(--primary-light); }
.badge--light::after { background: var(--primary-light); }
.badge--gray { background: var(--stroke); color: var(--primary); }
.badge--gray::after { background: var(--primary); }

/* Section header */
.section-header { text-align: center; max-width: 768px; margin: 0 auto 3rem; }
.section-header h2 { font-size: clamp(1.75rem, 4vw, 3rem); font-weight: 600; color: var(--primary); margin: 1rem 0 0.75rem; line-height: 1.2; }
.section-header p { font-size: 1.125rem; color: var(--gray-text); }
.section-header--light h2, .section-header--light p { color: var(--white); }

/* Topbar */
.topbar { background: #0f172a; color: #94a3b8; font-size: 0.75rem; padding: 6px 0; }
.topbar__inner { display: flex; justify-content: space-between; align-items: center; }
.topbar__contact { display: flex; gap: 1rem; }
.ltr-value { direction: ltr; unicode-bidi: isolate; display: inline-block; }
input[type="tel"], input[type="email"] { direction: ltr; unicode-bidi: isolate; }
html[dir="rtl"] input[type="tel"], html[dir="rtl"] input[type="email"] { text-align: right; }
.topbar__lang { display: flex; gap: 0.5rem; align-items: center; }
.lang-switch { background: none; border: none; color: inherit; font: inherit; cursor: pointer; padding: 0; }
.lang-switch.active { color: var(--white); font-weight: 600; }

html[dir="ltr"] body { font-family: "IBM Plex Sans", "IBM Plex Sans Arabic", system-ui, sans-serif; }
html[dir="ltr"] .hero__overlay { background: linear-gradient(to right, rgba(11, 53, 104, 0.83), rgba(117, 197, 102, 0.6)); }
html[dir="ltr"] .vision__row { flex-direction: row-reverse; }
html[dir="ltr"] .product-block--reverse .product-block__mockup { order: 1; }
html[dir="ltr"] .product-block--reverse .product-block__content { order: 2; }

/* Header */
.header {
  position: sticky; top: 0; z-index: 100;
  background: var(--white); border-bottom: 1px solid var(--blue-light); box-shadow: var(--shadow);
}
.nav { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 1rem; }
.nav__logo img { border-radius: 8px; }
.nav__links { display: flex; align-items: center; gap: 0.25rem; flex-wrap: wrap; }
.nav__link {
  padding: 0.5rem 1rem; font-size: 0.875rem; font-weight: 500; color: var(--primary);
  border-radius: 8px; white-space: nowrap;
}
.nav__link:hover, .nav__link--active { background: var(--mint); color: var(--white); }
.nav__toggle { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 4px; }
.nav__toggle span { display: block; width: 24px; height: 2px; background: var(--primary); transition: 0.2s; }

/* Hero */
.hero { position: relative; min-height: 769px; display: flex; align-items: center; margin-top: 0; }
.hero__bg { position: absolute; inset: 0; }
.hero__bg img { width: 100%; height: 100%; object-fit: cover; }
.hero__overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to left, rgba(11, 53, 104, 0.83), rgba(117, 197, 102, 0.6));
}
.hero__content { position: relative; text-align: center; color: var(--white); padding: 6rem 1rem; }
.hero__en { font-size: clamp(1rem, 2.5vw, 2.5rem); font-weight: 700; margin-bottom: 1.5rem; letter-spacing: -0.02em; }
.hero h1 { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 600; max-width: 700px; margin: 0 auto; }

/* About */
.about__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.about__image-wrap { position: relative; }
.about__image { border-radius: var(--radius); box-shadow: 0 4px 29.5px rgba(117, 197, 102, 0.16); border: 1px solid #e5e7eb; }
.about__badge {
  position: absolute; bottom: -2rem; left: 50%; transform: translateX(-50%);
  width: 191px; height: 191px; background: var(--primary); border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  color: var(--white); box-shadow: 0 4px 2px rgba(5, 53, 102, 0.3);
}
.about__badge strong { font-size: 2.5rem; font-weight: 700; }
.about__badge-label { font-size: 1.25rem; }
.about__text h2 { font-size: 2rem; font-weight: 600; color: var(--primary); margin-bottom: 1.5rem; }
.about__text p { font-size: 1.125rem; color: var(--primary); text-align: justify; margin-bottom: 1rem; line-height: 1.6; }

/* Vision */
.vision { background: var(--blue-light); padding: 4rem 0; }
.vision__card {
  position: relative; background: var(--blue-light); border-radius: var(--radius-lg);
  overflow: hidden; padding: 3rem; display: flex; flex-direction: column; gap: 2rem;
}
.vision__eye {
  position: absolute; left: 0; top: 0; width: 512px; height: 512px; opacity: 0.48; pointer-events: none;
}
.vision__eye img { width: 100%; height: 100%; object-fit: cover; mix-blend-mode: luminosity; filter: grayscale(1); }
.vision__row { display: flex; gap: 2rem; align-items: flex-start; position: relative; z-index: 1; }
.vision__row p { flex: 1; font-size: 1.125rem; color: var(--primary); text-align: justify; line-height: 1.6; }
.vision__row h3 { font-size: 2rem; font-weight: 600; color: var(--primary); white-space: nowrap; min-width: 150px; text-align: right; }

/* Values */
.values__layout {
  position: relative; max-width: 900px; margin: 0 auto; min-height: 600px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem;
}
.values__center { grid-column: 1 / -1; display: flex; justify-content: center; margin-bottom: 1rem; }
.values__center img { width: min(400px, 80vw); }
.value-card {
  background: var(--white); border-radius: var(--radius); padding: 1.5rem;
  box-shadow: var(--shadow); border: 1px solid var(--blue-light);
}
.value-card__num {
  font-size: 2.5rem; font-weight: 600;
  background: linear-gradient(to bottom, var(--mint), var(--white));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.value-card h4 { font-size: 1.125rem; color: var(--primary); margin: 0.5rem 0; }
.value-card p { font-size: 1rem; color: var(--primary); }

/* Goals */
.goals { background: var(--primary); color: var(--white); }
.goals__grid { display: grid; grid-template-columns: 1fr auto 1fr; gap: 2rem; align-items: center; }
.goals__list { display: flex; flex-direction: column; gap: 3rem; }
.goals__list li {
  display: flex; align-items: center; gap: 14px; font-size: 1.25rem; font-weight: 500; text-align: right;
}
.goals__image img { width: min(400px, 40vw); mix-blend-mode: screen; }

/* Features */
.features__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; align-items: center; }
.features__image { max-width: 500px; margin: 0 auto; }
.features__list { display: flex; flex-direction: column; gap: 1.5rem; }
.feature-item {
  display: flex; align-items: center; gap: 1.5rem; background: var(--green-light);
  padding: 1rem 1.5rem; border-radius: 25px;
}
.feature-item__num { font-size: 3rem; font-weight: 600; color: var(--green); flex-shrink: 0; }
.feature-item h4 { font-size: 1.25rem; font-weight: 600; margin-bottom: 0.25rem; }
.feature-item p { color: var(--gray); font-size: 1.125rem; }
.features__tagline {
  text-align: center; margin-top: 3rem; font-size: 1.125rem; font-weight: 500;
  color: var(--primary); background: var(--blue-light); padding: 1rem 2rem;
  border-radius: 999px; display: block; max-width: fit-content; margin-inline: auto;
}

/* Services */
.services { background: var(--green-light); }
.services__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; align-items: start; }
.services__visual img { border-radius: var(--radius); }
.services__list { display: flex; flex-direction: column; gap: 1rem; }
.service-item {
  display: flex; align-items: center; gap: 1.5rem; padding: 1rem 1.25rem;
  background: linear-gradient(to left, rgba(255,255,255,0), white 32%);
  border-radius: 8px;
}
.service-item span { font-size: 2.5rem; font-weight: 500; color: var(--mint); flex-shrink: 0; }
.service-item h4 { font-size: 1.125rem; color: #1f4993; font-weight: 500; }
.service-item p { color: #94a3b8; font-size: 1rem; }

/* Domains */
.domains { background: var(--green-light); }
.domains__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
.domain-card {
  background: var(--white); border-radius: var(--radius); padding: 2rem;
  position: relative; overflow: hidden; min-height: 360px;
}
.domain-card__icon {
  width: 64px; height: 64px; background: var(--blue-light); border-radius: 12px;
  display: flex; align-items: center; justify-content: center; font-size: 1.75rem; margin-bottom: 1rem;
}
.domain-card h4 { font-size: 1.25rem; font-weight: 600; margin-bottom: 1rem; }
.domain-card ul { padding-right: 1.5rem; color: var(--gray-muted); font-size: 1.125rem; }
.domain-card ul li { list-style: disc; margin-bottom: 0.35rem; }
.domain-card__img {
  position: absolute; bottom: 0; left: 1rem; width: 140px; opacity: 0.9; pointer-events: none;
}

/* Partners */
.partners__logos {
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center;
  gap: 3rem; padding: 2rem 0;
}
.partners__logos img { width: 120px; height: 120px; object-fit: contain; }

/* Presence */
.presence__map { width: 100%; max-width: 900px; margin: 0 auto; border-radius: var(--radius); }

/* CTA */
.cta { background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: var(--white); text-align: center; }
.cta h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); margin-bottom: 0.75rem; }
.cta p { margin-bottom: 1.5rem; opacity: 0.85; font-size: 1.125rem; }

/* Footer */
.footer { background: var(--primary); color: var(--nav); padding: 4rem 0 0; }
.footer__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; padding-bottom: 2rem; }
.footer__col h5 { color: var(--white); margin-bottom: 1rem; font-size: 1rem; }
.footer__col p, .footer__col li { font-size: 1rem; line-height: 1.8; }
.footer__col ul li { margin-bottom: 0.5rem; }
.footer__contact-list li { display: list-item; }
.footer__contact-list .ltr-value { display: inline-block; }
.footer__col a:hover { color: var(--mint); }
.footer__bottom { border-top: 1px solid #b3c0d0; padding: 1.5rem 0; text-align: center; font-size: 1rem; }

/* Page hero (inner pages) */
.page-hero { position: relative; min-height: 360px; display: flex; align-items: center; }
.page-hero__bg { position: absolute; inset: 0; }
.page-hero__bg img { width: 100%; height: 100%; object-fit: cover; }
.page-hero__content { position: relative; text-align: center; color: var(--white); padding: 4rem 1rem; }
.page-hero__content h1 { font-size: clamp(1.75rem, 3vw, 2.5rem); font-weight: 700; margin-bottom: 0.75rem; }
.page-hero__content p { font-size: 1.125rem; opacity: 0.9; max-width: 600px; margin: 0 auto; }

.section--muted { background: var(--green-light); }

/* Product showcase (technology page) */
.product-showcase--alt { background: var(--blue-light); }
.product-block {
  display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center;
}
.product-block--reverse .product-block__mockup { order: 2; }
.product-block--reverse .product-block__content { order: 1; }
.product-block__mockup {
  background: var(--white); border-radius: var(--radius); padding: 1rem;
  box-shadow: var(--shadow); border: 1px solid var(--blue-light);
}
.product-block__mockup img { border-radius: 12px; width: 100%; max-height: 420px; object-fit: cover; }
.product-block__label { font-size: 0.875rem; font-weight: 600; color: var(--primary-light); display: block; margin-bottom: 0.5rem; }
.product-block__content h3 { font-size: 1.75rem; font-weight: 600; color: var(--primary); margin-bottom: 0.75rem; }
.product-block__lead { font-size: 1.125rem; color: var(--gray-text); margin-bottom: 1.5rem; }
.product-block__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-bottom: 1.5rem; }
.product-block__cols h4 { font-size: 1rem; font-weight: 600; color: var(--primary); margin-bottom: 0.35rem; }
.product-block__cols p { font-size: 0.95rem; color: var(--gray-muted); line-height: 1.5; }

/* Projects page */
.projects-grid { display: grid; gap: 2rem; }
.projects-grid--4 { grid-template-columns: repeat(4, 1fr); }
.projects-grid--3 { grid-template-columns: repeat(3, 1fr); }
.projects-grid--auto { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.project-card {
  background: var(--white); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); border: 1px solid var(--blue-light);
  transition: transform 0.2s;
}
.project-card:hover { transform: translateY(-4px); }
.project-card img { width: 100%; height: 180px; object-fit: cover; }
.project-card--tall img { height: 220px; }
.project-card h4 { font-size: 1.125rem; font-weight: 600; color: var(--primary); padding: 1rem 1.25rem 0.5rem; }
.project-card p { font-size: 0.95rem; color: var(--gray-muted); padding: 0 1.25rem 1.25rem; line-height: 1.5; }

.featured-project {
  display: grid; grid-template-columns: 1fr 1.2fr; gap: 2rem; align-items: center;
  background: var(--white); border-radius: var(--radius-lg); padding: 2rem;
  box-shadow: var(--shadow); border: 1px solid var(--blue-light);
}
.featured-project img { border-radius: var(--radius); max-height: 400px; object-fit: contain; margin: 0 auto; }
.featured-project__body h3 { font-size: 1.5rem; color: var(--primary); margin-bottom: 1rem; }
.featured-project__body p { color: var(--gray-text); margin-bottom: 1rem; line-height: 1.6; }
.featured-project__body ul { padding-right: 1.25rem; margin-bottom: 1.5rem; color: var(--gray-muted); }
.featured-project__body li { list-style: disc; margin-bottom: 0.35rem; }

/* Contact form */
.contact-section { background: var(--green-light); }
.contact-form {
  max-width: 768px; margin: 0 auto; background: var(--white);
  border-radius: var(--radius-lg); padding: 3rem; box-shadow: var(--shadow);
}
.contact-form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.form-field { margin-bottom: 1.5rem; }
.form-field label { display: block; font-size: 0.875rem; font-weight: 500; color: var(--primary); margin-bottom: 0.5rem; }
.form-field input,
.form-field textarea {
  width: 100%; padding: 1rem 1.25rem; border: 1px solid var(--blue-light);
  border-radius: 12px; font-family: var(--font); font-size: 1rem; color: var(--black);
  background: var(--white); transition: border-color 0.2s;
}
.form-field input:focus,
.form-field textarea:focus { outline: none; border-color: var(--mint); }
.form-field textarea { resize: vertical; min-height: 140px; }
.form-field__count { display: block; text-align: left; font-size: 0.875rem; color: var(--nav); margin-top: 0.35rem; }
.btn--submit { width: 100%; padding: 1.25rem; font-size: 1.125rem; border-radius: 12px; margin-top: 0.5rem; }
.btn--submit:disabled { opacity: 0.7; cursor: wait; }
.form-honey { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-note { margin-top: 1rem; font-size: 0.875rem; color: var(--gray-muted); text-align: center; line-height: 1.5; }
.form-notice {
  max-width: 768px; margin: 0 auto 1.5rem; padding: 1rem 1.25rem;
  border-radius: 12px; font-weight: 500; text-align: center;
}
.form-notice--success { background: var(--green-light); color: var(--green); border: 1px solid var(--mint); }

.features__tagline {
  text-align: center; margin-top: 3rem; font-size: 1.125rem; font-weight: 500;
  color: var(--primary); background: var(--blue-light); padding: 1rem 2rem;
  border-radius: 999px; display: block; max-width: fit-content; margin-inline: auto;
}

/* Mobile */
@media (max-width: 1024px) {
  .about__grid, .features__grid, .services__grid, .vision__row,
  .product-block, .featured-project { grid-template-columns: 1fr; }
  .product-block--reverse .product-block__mockup,
  .product-block--reverse .product-block__content { order: unset; }
  .product-block__cols { grid-template-columns: 1fr; }
  .projects-grid--4 { grid-template-columns: repeat(2, 1fr); }
  .projects-grid--3 { grid-template-columns: 1fr; }
  .vision__row { flex-direction: column; }
  .goals__grid { grid-template-columns: 1fr; text-align: center; }
  .goals__list li { justify-content: center; }
  .goals__image { order: -1; }
  .domains__grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; text-align: center; }
  .values__layout { min-height: auto; }
  .contact-form__row { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .topbar__contact { display: none; }
  .nav__toggle { display: flex; }
  .nav__links {
    position: fixed; top: 96px; right: 0; left: 0;
    flex-direction: column; background: var(--white);
    border-bottom: 1px solid var(--blue-light); padding: 1rem;
    transform: translateY(-120%); opacity: 0; pointer-events: none; transition: 0.2s;
  }
  .nav__links.is-open { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .nav__link { display: block; width: 100%; text-align: center; }
  .nav__toggle.is-open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
  .nav__toggle.is-open span:nth-child(2) { opacity: 0; }
  .nav__toggle.is-open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
  .hero { min-height: 500px; }
  .about__badge { width: 140px; height: 140px; }
  .about__badge strong { font-size: 1.75rem; }
  .projects-grid--4 { grid-template-columns: 1fr; }
  .partners__logos img { width: 80px; height: 80px; }
  .contact-form { padding: 1.5rem; }
}
