/* 3atariq marketing site — design system. Plain CSS, no build step.
   Brand: teal #0F9B8E primary, gold #E8B23A accent. RTL-aware via logical properties. */

:root {
  --teal: #0f9b8e;
  --teal-dark: #0c7d72;
  --teal-darker: #095f57;
  --teal-tint: #e7f4f2;
  --teal-tint-2: #f2faf9;
  --gold: #e8b23a;
  --gold-dark: #c9952a;

  --ink: #142b29;
  --body: #3a4f4c;
  --muted: #6b807d;
  --line: #e2e9e7;
  --bg: #ffffff;
  --bg-soft: #f6faf9;
  --card: #ffffff;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(20, 43, 41, 0.06), 0 8px 24px rgba(20, 43, 41, 0.06);
  --shadow-lg: 0 12px 40px rgba(12, 125, 114, 0.16);
  --maxw: 1080px;

  /* Cairo is the app's typeface (covers Latin + Arabic). Loaded via Google Fonts in each
     page <head>; the system stack is only a fallback while the webfont loads / if it fails. */
  --font-sans: "Cairo", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue",
    Arial, "Noto Sans Arabic", "Geeza Pro", Tahoma, sans-serif;
  --font-serif: Georgia, "Times New Roman", "Amiri", serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--body);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { color: var(--ink); line-height: 1.2; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); margin: 0 0 0.4em; letter-spacing: -0.02em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin: 0 0 0.6em; letter-spacing: -0.01em; }
h3 { font-size: 1.15rem; margin: 0 0 0.4em; }
p { margin: 0 0 1em; }
a { color: var(--teal-dark); }

img, svg { max-width: 100%; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 20px;
}

/* Accessibility: skip link + focus */
.skip-link {
  position: absolute;
  inset-inline-start: 12px;
  top: -48px;
  z-index: 100;
  background: var(--ink);
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  transition: top 0.15s ease;
}
.skip-link:focus { top: 12px; }

:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(150%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex;
  align-items: center;
  gap: 18px;
  height: 68px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--ink);
  text-decoration: none;
}
.brand img { width: 34px; height: 34px; display: block; border-radius: 9px; }
.nav-links {
  display: flex;
  gap: 6px;
  margin-inline-start: auto;
  align-items: center;
  list-style: none;
  margin-block: 0;
  padding: 0;
}
.nav-links a {
  color: var(--body);
  text-decoration: none;
  padding: 8px 12px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
}
.nav-links a:hover { background: var(--teal-tint); color: var(--teal-dark); }

.lang-toggle {
  font: inherit;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  padding: 8px 12px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.lang-toggle:hover { border-color: var(--teal); color: var(--teal-dark); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  padding: 12px 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.08s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--teal); color: #fff; box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--teal-dark); }
.btn-ghost { background: #fff; color: var(--teal-dark); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--teal); }
.btn-sm { padding: 9px 16px; font-size: 0.9rem; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(1100px 480px at 80% -10%, var(--teal-tint) 0%, transparent 60%),
    linear-gradient(180deg, var(--teal-tint-2), #fff 70%);
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 40px;
  align-items: center;
  padding-block: clamp(48px, 8vw, 96px);
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--teal-dark);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 18px;
}
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); }
.hero p.lead { font-size: 1.2rem; color: var(--body); max-width: 34ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 26px; align-items: center; }
.hero-note { font-size: 0.9rem; color: var(--muted); margin-top: 16px; }

/* phone mock */
.hero-art { display: flex; justify-content: center; }
.phone {
  width: 260px;
  max-width: 70vw;
  aspect-ratio: 9 / 18.5;
  background: #fff;
  border: 10px solid #11302d;
  border-radius: 36px;
  box-shadow: var(--shadow-lg);
  padding: 16px 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.phone .p-head { display: flex; align-items: center; gap: 8px; font-weight: 800; color: var(--ink); }
.phone .p-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px;
  background: var(--bg-soft);
}
.phone .p-route { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--ink); font-size: 0.95rem; }
.phone .p-route .arrow { color: var(--teal); }
.phone .p-tag {
  display: inline-block; margin-top: 8px; font-size: 0.72rem; font-weight: 700;
  color: var(--teal-dark); background: var(--teal-tint); padding: 3px 9px; border-radius: 999px;
}
.phone .p-muted { font-size: 0.8rem; color: var(--muted); margin-top: 6px; }

/* ---------- Sections ---------- */
section { padding-block: clamp(48px, 7vw, 84px); }
.section-soft { background: var(--bg-soft); border-block: 1px solid var(--line); }
.section-head { max-width: 60ch; margin-bottom: 36px; }
.section-head .kicker { color: var(--teal); font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; font-size: 0.8rem; }

.grid { display: grid; gap: 20px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  height: 100%;
}
.card .ic {
  width: 46px; height: 46px; border-radius: 12px;
  display: grid; place-items: center; margin-bottom: 14px;
  background: var(--teal-tint); color: var(--teal-dark);
}
.card p { margin: 0; color: var(--body); }

/* steps */
.steps { counter-reset: step; display: grid; gap: 18px; grid-template-columns: repeat(4, 1fr); }
.step { position: relative; padding: 24px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.step .num {
  counter-increment: step;
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--teal); color: #fff; font-weight: 800;
  display: grid; place-items: center; margin-bottom: 14px;
}
.step .num::before { content: counter(step); }

/* highlight band */
.band {
  background: linear-gradient(135deg, var(--teal), var(--teal-darker));
  color: #fff;
  border-radius: 22px;
  padding: clamp(28px, 5vw, 48px);
  text-align: center;
}
.band h2 { color: #fff; }
.band p { color: rgba(255, 255, 255, 0.9); max-width: 56ch; margin-inline: auto; }

/* ---------- Download ---------- */
.coming-soon {
  display: inline-block; font-weight: 800; font-size: 0.78rem; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--gold-dark); background: #fbf2d8;
  padding: 5px 12px; border-radius: 999px; margin-bottom: 16px;
}
.badges { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }
.store-badge {
  display: inline-flex; align-items: center; gap: 12px;
  background: #11302d; color: #fff; text-decoration: none;
  padding: 12px 20px; border-radius: 14px; min-width: 210px;
  border: 1px solid #11302d; transition: transform 0.08s ease, opacity 0.15s ease;
}
.store-badge:hover { transform: translateY(-1px); }
.store-badge svg { width: 26px; height: 26px; flex: none; }
.store-badge .s-small { font-size: 0.7rem; opacity: 0.85; line-height: 1.1; }
.store-badge .s-big { font-size: 1.05rem; font-weight: 700; line-height: 1.15; }
.store-badge[aria-disabled="true"] { opacity: 0.92; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #cdd9d6; padding-block: 44px; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid { display: flex; flex-wrap: wrap; gap: 24px 48px; align-items: flex-start; justify-content: space-between; }
.footer-brand { display: flex; align-items: center; gap: 10px; font-weight: 800; color: #fff; font-size: 1.1rem; }
.footer-brand img { width: 30px; height: 30px; border-radius: 8px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 22px; list-style: none; padding: 0; margin: 0; }
.footer-bottom { margin-top: 26px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,0.12); font-size: 0.85rem; color: #9fb2ae; display: flex; flex-wrap: wrap; gap: 8px 16px; justify-content: space-between; }

/* ---------- Legal pages ---------- */
.legal { padding-block: clamp(36px, 6vw, 64px); }
.legal .container { max-width: 820px; }
.legal article { background: #fff; }
.legal h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.legal h2 { font-size: 1.25rem; margin-top: 1.8em; padding-top: 0.2em; }
.legal p, .legal li { color: var(--body); }
.legal ul { padding-inline-start: 1.3em; }
.legal li { margin-bottom: 0.5em; }
.legal .updated { color: var(--muted); font-weight: 700; }
.legal .back { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; text-decoration: none; margin-bottom: 22px; }

/* ---------- Language visibility helper (no-JS friendly) ---------- */
/* The legal body is English-only (as provided); marketing text swaps via data-en/data-ar. */

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-art { order: -1; }
}
@media (max-width: 560px) {
  .grid-4, .grid-2, .steps { grid-template-columns: 1fr; }
  .nav-links .nav-only-wide { display: none; }
  .nav { gap: 10px; }
  .store-badge { min-width: 0; flex: 1 1 100%; }
}

/* ---------- RTL fine-tuning ---------- */
[dir="rtl"] body { font-family: var(--font-sans); }
[dir="rtl"] .phone .p-route .arrow { transform: scaleX(-1); }
[dir="rtl"] .legal .back svg,
[dir="rtl"] .hero-cta svg.arrow { transform: scaleX(-1); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
