:root {
  --navy: #282735;
  --ink: #1d1c28;
  --panel: #2f2e3e;
  --line-dark: rgba(255, 255, 255, .13);
  --teal: #36adaf;
  --teal-dark: #1f7f81;
  --teal-deep: #14666f;
  --white: #f4fafc;
  --muted: #5f5e70;
  --soft: #c9ced8;
  --line: #dce6ea;
  --tint: #e3f3f4;
  --radius: 14px;
  --leaf: 44px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  margin: 0;
  font-family: "Tajawal", "Dubai", "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 1.75;
  color: var(--navy);
  background: var(--ink);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.ic { width: 24px; height: 24px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.wrap { width: min(1240px, 100% - 48px); margin-inline: auto; }
.skip { position: absolute; inset-inline-start: 16px; top: -60px; z-index: 100; padding: 8px 16px; color: var(--ink); background: var(--white); border-radius: 8px; }
.skip:focus { top: 12px; }

.eyebrow { margin-bottom: 14px; font-size: 16px; font-weight: 700; color: var(--teal); }
h1 { font-size: clamp(2.4rem, 4.1vw, 3.9rem); font-weight: 800; line-height: 1.16; letter-spacing: -.01em; color: #fff; }
h2 { font-size: clamp(1.9rem, 3.4vw, 3rem); font-weight: 800; line-height: 1.25; text-wrap: balance; }
h3 { font-size: 1.15rem; font-weight: 700; line-height: 1.4; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 10px 26px;
  font-weight: 700; color: var(--ink); background: var(--teal);
  border: 1px solid var(--teal); border-radius: 10px 10px 10px 24px;
  cursor: pointer; transition: background .2s, color .2s, transform .2s;
}
.btn:hover { background: #fff; border-color: #fff; transform: translateY(-2px); }
.btn:disabled { opacity: .6; cursor: progress; transform: none; }
.btn-small { min-height: 42px; padding: 6px 20px; font-size: 16px; }
.btn-ghost { color: #fff; background: transparent; border-color: var(--line-dark); }
.btn-ghost:hover { color: var(--ink); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--ink);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.site-header.scrolled { border-color: var(--line-dark); }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 76px; }
.logo img { width: auto; height: 48px; }
.main-nav { display: flex; align-items: center; gap: 32px; }
.main-nav ul { display: flex; gap: 28px; }
.main-nav ul a { position: relative; padding: 6px 0; font-size: 16px; font-weight: 500; color: var(--soft); transition: color .2s; }
.main-nav ul a:hover, .main-nav ul a.active { color: #fff; }
.main-nav ul a.active::after { content: ""; position: absolute; inset-inline: 0; bottom: 0; height: 2px; background: var(--teal); }
.nav-toggle { display: none; width: 44px; height: 44px; padding: 11px; background: none; border: 1px solid var(--line-dark); border-radius: 10px; cursor: pointer; }
.nav-toggle span { display: block; height: 2px; margin-block: 3px; background: #fff; }

/* Hero */
.hero {
  position: relative; overflow: hidden; color: var(--soft);
  background-color: var(--ink);
  background-image:
    linear-gradient(var(--line-dark) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-dark) 1px, transparent 1px);
  background-size: 56px 56px;
  background-position: center top;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(ellipse 75% 85% at 50% 45%, rgba(29, 28, 40, .35), var(--ink) 95%);
}
.hero-grid {
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr);
  gap: 56px; align-items: center; min-height: min(calc(100vh - 76px), 800px); padding-block: 48px 64px;
}
.lead { max-width: 33em; margin-top: 22px; font-size: 1.2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }

.flow figcaption { margin-top: 10px; font-size: 14px; color: #9a9dac; text-align: center; }
.flow svg { width: 100%; height: auto; overflow: visible; }
.wires path { fill: none; stroke: rgba(54, 173, 175, .42); stroke-width: 1.5; }
.packets circle { fill: #fff; }
.packets.out circle { fill: var(--teal); }
.node rect { fill: var(--panel); stroke: var(--line-dark); rx: 12px; }
.node use { fill: none; stroke: var(--teal); stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.node text { font-size: 17px; font-weight: 700; fill: #fff; text-anchor: middle; }
.node-out text { font-size: 16px; }
.node-out rect { fill: var(--teal-deep); stroke: rgba(54, 173, 175, .6); }
.node-out use { stroke: #fff; }
.hub rect { fill: var(--navy); stroke: var(--teal); stroke-width: 2; }
.hub-label { font-size: 20px; font-weight: 800; fill: var(--teal); text-anchor: middle; }
.ring { fill: none; stroke: var(--teal); stroke-width: 1.5; transform-box: fill-box; transform-origin: center; animation: pulse 3.6s ease-out infinite; }
.ring-2 { animation-delay: 1.8s; }
@keyframes pulse { from { opacity: .55; transform: scale(.82); } to { opacity: 0; transform: scale(1.3); } }

/* Shared section head */
.head { max-width: 780px; margin-bottom: 44px; }
.head p:not(.eyebrow) { margin-top: 14px; font-size: 1.1rem; }

/* About */
.about { padding-block: 96px; background: var(--white); }
.about .eyebrow, .services .eyebrow { color: var(--teal-deep); }
.about-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.about-copy > p:not(.eyebrow) { max-width: 40em; margin-top: 18px; color: var(--muted); }
.about-photo img { width: 100%; aspect-ratio: 5 / 4; object-fit: cover; border-radius: var(--radius) var(--radius) var(--radius) 120px; }
.equation { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 30px; }
.equation span { display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 8px 18px; font-size: 16px; font-weight: 700; background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.equation span .ic { color: var(--teal-deep); }
.equation b { font-size: 1.4rem; color: var(--teal-deep); }
.eq-end { display: flex; align-items: center; gap: 12px; }
.equation .result { color: #fff; background: var(--navy); border-color: var(--navy); }
.equation .result .ic { color: var(--teal); }

/* Tech */
.tech { padding-block: 96px; color: var(--soft); background: var(--navy); }
.tech h2 { color: #fff; }
.console-grid { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 28px; align-items: stretch; }
.cap-tabs { display: flex; flex-direction: column; gap: 12px; }
.cap-tab {
  flex: 1; display: flex; align-items: flex-start; gap: 16px; padding: 22px;
  text-align: start; color: var(--soft); background: transparent;
  border: 1px solid var(--line-dark); border-radius: var(--radius);
  cursor: pointer; transition: background .2s, border-color .2s;
}
.cap-tab .ic { margin-top: 3px; color: var(--teal); }
.cap-tab strong { display: block; font-size: 1.2rem; color: #fff; }
.cap-tab small { display: block; margin-top: 4px; font-size: 16px; line-height: 1.55; }
.cap-tab:hover { background: rgba(255, 255, 255, .04); }
.cap-tab[aria-selected="true"] { background: var(--teal-deep); border-color: var(--teal); color: #fff; border-end-end-radius: var(--leaf); }
.cap-tab[aria-selected="true"] .ic { color: #fff; }

.console { min-height: 440px; padding: 28px; background: var(--ink); border: 1px solid var(--line-dark); border-radius: var(--radius) var(--radius) var(--radius) var(--leaf); }
.panel[hidden] { display: none; }
.panel:focus-visible { outline-offset: 12px; }
.console-title { display: flex; align-items: center; gap: 10px; padding-bottom: 16px; margin-bottom: 22px; font-weight: 700; color: #fff; border-bottom: 1px solid var(--line-dark); }
.console-title .ic { color: var(--teal); }
.console-title em { margin-inline-start: auto; padding: 1px 12px; font-size: 13px; font-style: normal; font-weight: 500; color: var(--soft); border: 1px solid var(--line-dark); border-radius: 99px; }

.journey { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.journey li {
  display: flex; flex-direction: column; gap: 12px; min-height: 118px; padding: 16px;
  font-size: 16px; font-weight: 700; line-height: 1.4; color: #fff;
  background: var(--panel); border: 1px solid var(--line-dark); border-radius: 12px;
  animation: step 9s infinite;
}
.journey i { display: grid; place-items: center; width: 30px; height: 30px; font-size: 15px; font-style: normal; color: var(--teal); border: 1px solid var(--teal); border-radius: 50%; }
.journey li:nth-child(2) { animation-delay: 1.5s; }
.journey li:nth-child(3) { animation-delay: 3s; }
.journey li:nth-child(4) { animation-delay: 4.5s; }
.journey li:nth-child(5) { animation-delay: 6s; }
.journey li:nth-child(6) { animation-delay: 7.5s; }
@keyframes step { 0%, 16% { border-color: var(--teal); background: var(--teal-deep); } 24%, 100% { border-color: var(--line-dark); background: var(--panel); } }
.modules { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.modules span { padding: 4px 16px; font-size: 15px; color: var(--soft); border: 1px dashed rgba(54, 173, 175, .6); border-radius: 8px; }

.run { display: grid; gap: 10px; }
.run li { display: flex; align-items: center; gap: 14px; min-height: 58px; padding: 8px 16px; font-weight: 500; color: #fff; background: var(--panel); border-radius: 12px; }
.run li > .ic { color: var(--teal); }
.run b { display: grid; place-items: center; width: 28px; height: 28px; margin-inline-start: auto; color: var(--ink); background: var(--teal); border-radius: 50%; animation: tick 8s infinite both; }
.run b .ic { width: 16px; height: 16px; stroke-width: 3; }
.run li:nth-child(2) b { animation-delay: .8s; }
.run li:nth-child(3) b { animation-delay: 1.6s; }
.run li:nth-child(4) b { animation-delay: 2.4s; }
.run li:nth-child(5) b { animation-delay: 3.2s; }
@keyframes tick { 0% { opacity: 0; transform: scale(.4); } 5%, 92% { opacity: 1; transform: scale(1); } 100% { opacity: 0; } }

.kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.kpis div { padding: 12px 14px; background: var(--panel); border-radius: 12px; }
.kpis span { display: block; font-size: 15px; font-weight: 700; color: #fff; line-height: 1.3; }
.kpis svg { width: 100%; height: 38px; margin-top: 8px; }
.kpis path { fill: none; stroke: var(--teal); stroke-width: 2; stroke-linecap: round; vector-effect: non-scaling-stroke; stroke-dasharray: 1; animation: draw 1.4s ease-out both; }
@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
.bars { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; height: 170px; margin-top: 20px; padding-bottom: 1px; border-bottom: 1px solid var(--line-dark); }
.bars div { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 4px; height: 100%; }
.bars i, .bars u { width: 42%; max-width: 22px; border-radius: 4px 4px 0 0; transform-origin: bottom; animation: rise .9s cubic-bezier(.2, .7, .2, 1) both; }
.bars i { background: #5f5e70; }
.bars u { background: var(--teal); }
.bars div:nth-child(1) i { height: 48%; } .bars div:nth-child(1) u { height: 42%; }
.bars div:nth-child(2) i { height: 56%; } .bars div:nth-child(2) u { height: 60%; }
.bars div:nth-child(3) i { height: 64%; } .bars div:nth-child(3) u { height: 58%; }
.bars div:nth-child(4) i { height: 60%; } .bars div:nth-child(4) u { height: 72%; }
.bars div:nth-child(5) i { height: 74%; } .bars div:nth-child(5) u { height: 70%; }
.bars div:nth-child(6) i { height: 80%; } .bars div:nth-child(6) u { height: 88%; }
.bars div:nth-child(7) i { height: 86%; } .bars div:nth-child(7) u { height: 96%; }
@keyframes rise { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.legend { display: flex; gap: 20px; margin-top: 10px; font-size: 14px; }
.legend span::before { content: ""; display: inline-block; width: 10px; height: 10px; margin-inline-end: 7px; border-radius: 2px; }
.k-a::before { background: #5f5e70; }
.k-b::before { background: var(--teal); }

/* Services */
.services { padding-block: 96px; background: var(--white); }
.service-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-block: 1px solid var(--line); }
.service-list li { padding: 32px 26px; border-inline-start: 1px solid var(--line); }
.service-list li:first-child { padding-inline-start: 0; border-inline-start: 0; }
.service-list .ic { width: 32px; height: 32px; margin-bottom: 18px; color: var(--teal-deep); }
.service-list p { margin-top: 8px; font-size: 16.5px; line-height: 1.65; color: var(--muted); }

/* Partners */
.partners { padding-block: 96px; color: var(--soft); background: var(--ink); }
.partners h2 { color: #fff; }
.chain { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1.25fr) auto minmax(0, 1fr); align-items: stretch; gap: 18px; }
.link-card { padding: 28px; background: var(--panel); border: 1px solid var(--line-dark); border-radius: var(--radius); }
.link-card .ic, .link-card img { width: 36px; height: 36px; margin-bottom: 18px; color: var(--teal); }
.link-card h3 { font-size: 1.3rem; color: #fff; }
.link-card p { margin-top: 8px; font-size: 16.5px; line-height: 1.65; }
.link-card.is-us { color: #e6f4f5; background: var(--teal-deep); border-color: var(--teal); border-end-end-radius: var(--leaf); }
.joint { align-self: center; font-size: 2rem; font-weight: 800; color: var(--teal); }
.partner-logos { display: flex; flex-wrap: wrap; align-items: center; gap: 40px; margin-top: 44px; padding-block: 28px; border-block: 1px solid var(--line-dark); }
.partner-logos:empty { display: none; }
.partner-logos img { width: auto; max-width: 160px; height: 44px; object-fit: contain; }
.partner-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 32px; margin-top: 44px; }
.partner-cta p { font-size: 1.3rem; font-weight: 700; color: #fff; }

/* Contact */
.contact { padding-block: 96px; color: var(--navy); background: var(--tint); }
.contact .eyebrow { color: var(--teal-deep); }
.contact-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 64px; align-items: start; }
.contact-copy > p:not(.eyebrow) { margin-top: 16px; color: var(--muted); }
.contact-copy .place { display: flex; align-items: center; gap: 10px; margin-top: 26px; color: var(--navy); font-weight: 500; }
.place .ic { color: var(--teal-deep); }
.contact-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; padding: 32px; background: #fff; border-radius: var(--radius) var(--radius) var(--radius) var(--leaf); }
.wide { grid-column: 1 / -1; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.field label { display: block; margin-bottom: 6px; font-size: 16px; font-weight: 700; }
.field input, .field select, .field textarea { width: 100%; min-height: 48px; padding: 10px 14px; background: var(--white); border: 1px solid var(--line); border-radius: 10px; }
.field input[dir="ltr"] { text-align: right; }
.field textarea { display: block; resize: vertical; }
.field :is(input, select, textarea):focus { outline: 2px solid var(--teal-dark); outline-offset: 0; border-color: var(--teal-dark); }
.err { display: none; margin-top: 4px; font-size: 14px; color: #b3261e; }
.field.invalid .err { display: block; }
.field.invalid :is(input, textarea) { border-color: #b3261e; }
.contact-form .btn:hover { color: #fff; background: var(--navy); border-color: var(--navy); }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.form-status { font-weight: 500; }
.form-status.ok { color: var(--teal-deep); }
.form-status.bad { color: #b3261e; }

/* Footer */
.site-footer { padding-block: 32px; color: var(--soft); background: var(--ink); }
.footer-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 32px; }
.footer-row img { width: auto; height: 42px; }
.footer-row p { font-size: 15px; }

/* 404 */
.not-found { display: grid; place-content: center; justify-items: start; gap: 20px; min-height: 100vh; padding: 24px; color: var(--soft); }
.not-found h1 { font-size: clamp(2rem, 5vw, 3.2rem); }

/* Reveal */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .4s, transform .4s; }
.js .reveal.in { opacity: 1; transform: none; }

@media (max-width: 1100px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); min-height: 0; gap: 40px; }
  .about-grid, .console-grid, .contact-grid { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .about-photo img { aspect-ratio: 16 / 8; }
  .service-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .service-list li:nth-child(odd) { padding-inline-start: 0; border-inline-start: 0; }
  .service-list li:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .console { min-height: 0; }
}

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .main-nav {
    display: none; position: absolute; inset-inline: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 16px; padding: 16px 24px 24px;
    background: var(--ink); border-bottom: 1px solid var(--line-dark);
  }
  .main-nav.open { display: flex; }
  .main-nav ul { flex-direction: column; gap: 4px; }
  .main-nav ul a { display: block; padding: 10px 0; font-size: 18px; }
  .main-nav ul a.active::after { display: none; }
  .chain { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .joint { justify-self: center; line-height: 1.2; }
}

@media (max-width: 600px) {
  body { font-size: 17px; }
  .wrap { width: calc(100% - 32px); }
  .about, .tech, .services, .partners, .contact { padding-block: 64px; }
  .head { margin-bottom: 32px; }
  .hero-actions .btn { flex: 1; white-space: nowrap; }
  .node use { display: none; }
  .node text, .node-out text { font-size: 21px; transform: translateX(13px); }
  .equation { flex-direction: column; align-items: stretch; }
  .equation b { text-align: center; line-height: 1; }
  .eq-end { flex-direction: column; align-items: stretch; }
  .console { padding: 18px; }
  .journey { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .journey li { min-height: 104px; padding: 14px; }
  .kpis { grid-template-columns: minmax(0, 1fr); }
  .kpis div { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 12px; }
  .kpis svg { margin-top: 0; }
  .service-list { grid-template-columns: minmax(0, 1fr); }
  .service-list li, .service-list li:nth-child(odd) { padding: 24px 0; border-inline-start: 0; }
  .service-list li + li { border-top: 1px solid var(--line); }
  .contact-form { grid-template-columns: minmax(0, 1fr); padding: 22px; }
  .partner-cta .btn { width: 100%; }
  .form-foot .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .packets, .ring { display: none; }
  .js .reveal { opacity: 1; transform: none; }
}
