/* mojtaba-alamer.com — "Kufic grid": the logo's black blocks + four green squares are the whole system.
   Plain CSS on purpose (public site; no Tailwind Play CDN in production, no build step). */

:root {
  --ink: #000000;          /* logo + headings */
  --text: #2E3433;         /* body */
  --muted: #5B6564;
  --green: #00A09D;        /* brand: actions, markers, large text only */
  --green-deep: #00706D;   /* small green text on white (AA contrast) */
  --tint: #E5F4F3;
  --line: #D3E4E2;
  --paper: #FFFFFF;

  --kufi: "Noto Kufi Arabic", "IBM Plex Sans Arabic", system-ui, sans-serif;
  --plex: "IBM Plex Sans Arabic", system-ui, sans-serif;

  --unit: 8px;             /* the grid module */
  --wrap: 1120px;
  --gutter: clamp(16px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font: 400 1.0625rem/1.85 var(--plex);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: var(--green-deep); }
h1, h2, h3 { font-family: var(--kufi); color: var(--ink); margin: 0; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }

:focus-visible { outline: 3px solid var(--green-deep); outline-offset: 3px; border-radius: 2px; }
.skip { position: absolute; inset-inline-start: 8px; top: -60px; background: var(--ink); color: #fff; padding: 8px 16px; z-index: 10; }
.skip:focus { top: 8px; }

/* ── Hero: text on the start side, the whole logo (straight, uncropped) beside it ── */
.hero { display: flex; flex-direction: column; }
.hero-main { flex: 1; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: calc(var(--unit) * 8); align-items: center; }
.hero-art { display: flex; justify-content: center; }
.hero-art img { width: 100%; max-width: 440px; height: auto; }

.topbar { position: relative; display: flex; align-items: center; justify-content: space-between; padding-block: calc(var(--unit) * 3); }
.brand img { height: 32px; width: auto; }
.nav { display: flex; gap: calc(var(--unit) * 3); }
.nav a { color: var(--ink); text-decoration: none; font-weight: 500; font-size: .95rem; }
.nav a:hover { color: var(--green-deep); }

.hero-body { padding-block: calc(var(--unit) * 10) calc(var(--unit) * 8); }
.hero-body > * { max-width: 34rem; }
.hero-body > h1 { max-width: 44rem; }
.who { font-weight: 600; color: var(--green-deep); margin-bottom: calc(var(--unit) * 2); }
h1 { font-weight: 800; font-size: clamp(2.125rem, 4.2vw, 3.5rem); line-height: 1.45; letter-spacing: 0; }
h1 span { display: block; white-space: nowrap; }   /* one line per half on wide screens */
.lead { margin-top: calc(var(--unit) * 3); font-size: 1.125rem; color: var(--text); max-width: 32rem; }

.actions { display: flex; flex-wrap: wrap; gap: calc(var(--unit) * 1.5); margin-top: calc(var(--unit) * 5); }
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  min-height: 48px; padding: 10px 22px;
  font: 600 1rem/1.4 var(--plex); text-decoration: none;
  border-radius: 12px;              /* the logo's rounded block corner */
  border: 2px solid transparent;
}
.btn-primary { background: var(--green); color: var(--ink); }
.btn-primary:hover { background: #00B5B1; }
.btn-quiet { background: var(--paper); color: var(--ink); border-color: var(--ink); }
.btn-quiet:hover { background: var(--ink); color: #fff; }

/* ── Sections ──────────────────────────────────────────────────────────── */
.section { padding-block: calc(var(--unit) * 14); }
h2 { font-weight: 800; font-size: clamp(1.75rem, 3.2vw, 2.5rem); line-height: 1.5; }
.section-lead { margin-top: calc(var(--unit) * 1.5); max-width: 36rem; color: var(--muted); }
h3 { font-weight: 600; font-size: 1.1875rem; line-height: 1.6; }

/* Services: rows on the grid, each marked with one of the logo's green squares */
.services {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: calc(var(--unit) * 8);
  margin-top: calc(var(--unit) * 7);
  border-top: 2px solid var(--ink);
}
.services li { position: relative; padding: calc(var(--unit) * 4) calc(var(--unit) * 4.5) calc(var(--unit) * 4) 0; border-bottom: 1px solid var(--line); }
.services li::before {
  content: ""; position: absolute; inset-inline-start: 0; top: calc(var(--unit) * 4 + 9px);
  width: 14px; height: 14px; border-radius: 3px; background: var(--green);
}
.services p { margin-top: var(--unit); color: var(--text); }

/* EFATORAA: the one black block on the page */
.product { background: var(--ink); color: #D9E2E1; }
.product-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: calc(var(--unit) * 8); padding-block: calc(var(--unit) * 12); align-items: center; }
.product h2 { color: #fff; font-size: clamp(2rem, 4vw, 3rem); }
.product-lead { margin-block: calc(var(--unit) * 2) calc(var(--unit) * 4); font-size: 1.125rem; max-width: 30rem; }
.product-points li { display: flex; gap: 14px; align-items: baseline; padding-block: calc(var(--unit) * 2); border-bottom: 1px solid #2A2F2F; color: #fff; }
.product-points li:last-child { border-bottom: 0; }
.product-points li::before { content: ""; flex: none; width: 10px; height: 10px; border-radius: 2px; background: var(--green); transform: translateY(-2px); }

/* Clients: logos (or names) on a quiet row */
/* One row that scrolls sideways, so many clients never take more height */
.client-list {
  display: flex; flex-wrap: nowrap; align-items: center; gap: calc(var(--unit) * 6);
  margin-top: calc(var(--unit) * 6); padding-block: calc(var(--unit) * 1.5);
  overflow-x: auto; overscroll-behavior-x: contain;
  scrollbar-width: thin; scrollbar-color: var(--line) transparent;
  /* fade both edges as a hint that the row continues */
  -webkit-mask-image: linear-gradient(to left, transparent 0, #000 40px, #000 calc(100% - 40px), transparent 100%);
          mask-image: linear-gradient(to left, transparent 0, #000 40px, #000 calc(100% - 40px), transparent 100%);
  padding-inline: 48px;
}
.client-list li { flex: none; min-height: 64px; display: flex; align-items: center; }
.clients-scroller { position: relative; }
.clients-scroller.is-scrolling .client-list { scrollbar-width: none; }  /* arrows replace the bar */
.clients-scroller.is-scrolling .client-list::-webkit-scrollbar { display: none; }
.scroll-btn {
  position: absolute; top: 50%; z-index: 2; transform: translateY(-50%);
  width: 40px; height: 40px; display: grid; place-items: center;
  border: 0; border-radius: 10px; background: var(--ink); color: #fff; cursor: pointer;
}
.scroll-btn:hover { background: var(--green); color: var(--ink); }
.scroll-btn[hidden] { display: none; }
.scroll-btn--prev { inset-inline-start: 0; }   /* right side in RTL */
.scroll-btn--next { inset-inline-end: 0; }     /* left side in RTL */
.client-list a { display: flex; align-items: center; color: inherit; text-decoration: none; }
.client-list img { height: 56px; width: auto; max-width: 180px; object-fit: contain; }
.client-list span { font: 600 1.125rem/1.5 var(--kufi); color: var(--ink); }

/* Steps: a real sequence, so it is numbered */
.steps-band { background: var(--tint); padding-block: calc(var(--unit) * 12); }
.steps { counter-reset: step; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: calc(var(--unit) * 4); margin-top: calc(var(--unit) * 6); }
.steps li { counter-increment: step; }
.steps li::before {
  content: counter(step, arabic-indic);
  display: grid; place-items: center;
  width: 44px; height: 44px; margin-bottom: calc(var(--unit) * 2);
  border-radius: 10px; background: var(--ink); color: #fff;
  font: 800 1.125rem/1 var(--kufi);
}
.steps p { margin-top: calc(var(--unit) * .75); color: var(--text); }

/* Contact */
.contact h2 { max-width: 40rem; }
.area { margin-top: calc(var(--unit) * 3); display: flex; gap: 12px; align-items: baseline; font-weight: 500; color: var(--ink); }
.area::before { content: ""; flex: none; width: 10px; height: 10px; border-radius: 2px; background: var(--green); transform: translateY(-2px); }

/* Floating WhatsApp button: phones only */
.wa-float { display: none; }

.footer { display: flex; flex-wrap: wrap; align-items: center; gap: calc(var(--unit) * 3); padding-block: calc(var(--unit) * 5); border-top: 1px solid var(--line); color: var(--muted); font-size: .9375rem; }
.footer img { height: 24px; width: auto; margin-inline-end: auto; }

/* Short-link "not available" page */
.gone { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; gap: calc(var(--unit) * 2); }
.gone img { height: 48px; width: auto; margin-bottom: calc(var(--unit) * 2); }

/* ── Small screens ─────────────────────────────────────────────────────── */
@media (max-width: 860px) {
  .nav { display: none; }
  .wa-float {
    display: inline-flex; align-items: center; gap: 8px;
    position: fixed; inset-inline-start: 16px; bottom: max(16px, env(safe-area-inset-bottom));
    z-index: 20; min-height: 48px; padding: 10px 18px; border-radius: 999px;
    background: var(--green); color: var(--ink); font: 600 1rem/1 var(--plex); text-decoration: none;
    box-shadow: 0 6px 20px rgba(0, 112, 109, .35);
  }
  body { padding-bottom: 88px; }   /* so the button never covers the footer */
  .hero { min-height: auto; }
  .hero-main { grid-template-columns: 1fr; gap: 0; }
  h1 span { white-space: normal; }
  .hero-art { display: none; }   /* the topbar logo is enough on small screens */
  .hero-body { padding-block: calc(var(--unit) * 4) calc(var(--unit) * 5); }
  .services, .product-grid { grid-template-columns: 1fr; }
  .services { column-gap: 0; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .section { padding-block: calc(var(--unit) * 9); }
}
@media (max-width: 480px) {
  .steps { grid-template-columns: 1fr; }
  .btn { width: 100%; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
