/* Mediqon landing — design system.
   Identity: clinical calm. Deep ink + the logo's navy→sky line, generous space,
   rounded "circuit" strokes with node dots as the only ornament. */

:root {
  --ink: #0b1a2b;
  --ink-2: #12263c;
  --navy: #0f5c8c;
  --blue: #1a73a8;
  --sky: #38bdf0;
  --mint: #2fd3a6;
  --paper: #f6f9fc;
  --surface: #ffffff;
  --line: #e2eaf2;
  --text: #0b1a2b;
  --muted: #5b6b7c;
  --on-dark: #e9f2fa;
  --on-dark-muted: #9db3c8;
  --danger: #d64545;
  --success: #14946b;
  --warn: #c98a00;

  --grad: linear-gradient(120deg, var(--navy), var(--sky));
  --radius-sm: 10px;
  --radius: 18px;
  --radius-lg: 28px;
  --shadow-sm: 0 1px 2px rgba(11, 26, 43, 0.06), 0 2px 8px rgba(11, 26, 43, 0.04);
  --shadow: 0 10px 30px rgba(11, 26, 43, 0.08), 0 2px 6px rgba(11, 26, 43, 0.05);
  --shadow-lg: 0 30px 80px rgba(11, 26, 43, 0.18);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --wrap: 1180px;
  --gutter: clamp(18px, 4vw, 40px);
  --section: clamp(72px, 10vw, 140px);
  --font: "Inter", "Cairo", system-ui, -apple-system, "Segoe UI", sans-serif;
}
html[lang="ar"] { --font: "Cairo", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif; }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--paper);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
[hidden] { display: none !important; }

:focus-visible { outline: 3px solid var(--sky); outline-offset: 3px; border-radius: 6px; }
.skip-link {
  position: absolute; inset-inline-start: 12px; top: -60px; z-index: 200;
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px; transition: top 0.2s;
}
.skip-link:focus { top: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.wrap { width: min(var(--wrap), 100% - var(--gutter) * 2); margin-inline: auto; }
.section { padding-block: var(--section); position: relative; }
.section--tight { padding-block: clamp(48px, 7vw, 88px); }
.section--dark { background: var(--ink); color: var(--on-dark); }
.section--surface { background: var(--surface); }

/* ---------- Type ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--blue);
}
html[lang="ar"] .eyebrow { letter-spacing: 0; font-size: 0.92rem; }
.eyebrow::before { content: ""; width: 28px; height: 2px; border-radius: 2px; background: var(--grad); }
.section--dark .eyebrow { color: var(--sky); }
.display { font-size: clamp(2.4rem, 5.6vw, 4.6rem); line-height: 1.04; letter-spacing: -0.035em; font-weight: 800; }
.h2 { font-size: clamp(1.9rem, 4.2vw, 3.2rem); line-height: 1.1; letter-spacing: -0.03em; font-weight: 800; }
.h3 { font-size: clamp(1.2rem, 2vw, 1.5rem); line-height: 1.25; letter-spacing: -0.015em; font-weight: 700; }
html[lang="ar"] .display, html[lang="ar"] .h2, html[lang="ar"] .h3 { letter-spacing: 0; line-height: 1.3; }
html[lang="ar"] .display { font-size: clamp(2.2rem, 5vw, 4rem); line-height: 1.22; }
.lead { font-size: clamp(1.05rem, 1.5vw, 1.28rem); color: var(--muted); max-width: 62ch; }
.section--dark .lead { color: var(--on-dark-muted); }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.section-head { display: grid; gap: 18px; margin-bottom: clamp(36px, 5vw, 64px); max-width: 780px; }
.section-head--center { margin-inline: auto; text-align: center; justify-items: center; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 0 24px; border-radius: 999px; border: 1px solid transparent;
  font-weight: 700; font-size: 1rem; cursor: pointer; white-space: nowrap;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.2s, border-color 0.2s, color 0.2s;
}
.btn:active { transform: scale(0.98); }
.btn--primary { background: var(--grad); color: #fff; box-shadow: 0 10px 26px rgba(26, 115, 168, 0.32); }
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 16px 34px rgba(26, 115, 168, 0.42); }
.btn--ghost { background: transparent; border-color: var(--line); color: var(--text); }
.btn--ghost:hover { border-color: var(--blue); color: var(--blue); }
.section--dark .btn--ghost, .hero .btn--ghost { border-color: rgba(255, 255, 255, 0.22); color: #fff; }
.section--dark .btn--ghost:hover, .hero .btn--ghost:hover { border-color: var(--sky); color: var(--sky); }
.btn--sm { min-height: 40px; padding: 0 16px; font-size: 0.92rem; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; transform: none; box-shadow: none; }
.btn .icon { width: 20px; height: 20px; flex: none; }

.store {
  display: inline-flex; align-items: center; gap: 12px; min-height: 54px; padding: 8px 18px;
  border-radius: 14px; background: #fff; color: var(--ink); border: 1px solid var(--line);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.2s;
}
.store:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--blue); }
.store svg { width: 24px; height: 24px; flex: none; }
.store small { display: block; font-size: 0.68rem; line-height: 1.1; color: var(--muted); font-weight: 600; }
.store strong { display: block; font-size: 0.98rem; line-height: 1.2; }
.store--dark { background: rgba(255, 255, 255, 0.06); color: #fff; border-color: rgba(255, 255, 255, 0.16); backdrop-filter: blur(8px); }
.store--dark small { color: var(--on-dark-muted); }
.store--dark:hover { border-color: var(--sky); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3); }
.store[aria-disabled="true"] { opacity: 0.6; pointer-events: none; }
.store-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  transition: background 0.3s, box-shadow 0.3s, backdrop-filter 0.3s;
}
.site-header.is-solid { background: rgba(246, 249, 252, 0.86); backdrop-filter: saturate(180%) blur(16px); box-shadow: 0 1px 0 var(--line); }
.nav { display: flex; align-items: center; gap: 20px; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; color: #fff; }
.brand img { width: 38px; height: 38px; border-radius: 11px; background: #fff; }
.site-header.is-solid .brand, .site-header--light .brand { color: var(--ink); }
.nav-links { display: flex; align-items: center; gap: 4px; margin-inline-start: auto; }
.nav-links a { padding: 8px 14px; border-radius: 999px; font-weight: 600; font-size: 0.95rem; color: rgba(255, 255, 255, 0.82); transition: color 0.2s, background 0.2s; }
.nav-links a:hover, .nav-links a[aria-current="true"] { color: #fff; background: rgba(255, 255, 255, 0.1); }
.site-header.is-solid .nav-links a, .site-header--light .nav-links a { color: var(--muted); }
.site-header.is-solid .nav-links a:hover, .site-header.is-solid .nav-links a[aria-current="true"],
.site-header--light .nav-links a:hover { color: var(--ink); background: rgba(11, 26, 43, 0.06); }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.lang-toggle {
  min-height: 40px; padding: 0 14px; border-radius: 999px; background: transparent; cursor: pointer; font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.22); color: #fff;
}
.site-header.is-solid .lang-toggle, .site-header--light .lang-toggle { border-color: var(--line); color: var(--ink); }
.menu-toggle { display: none; width: 44px; height: 44px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, 0.22); background: transparent; cursor: pointer; position: relative; }
.site-header.is-solid .menu-toggle, .site-header--light .menu-toggle { border-color: var(--line); }
.menu-toggle span { position: absolute; inset-inline: 12px; height: 2px; border-radius: 2px; background: #fff; transition: transform 0.3s var(--ease), opacity 0.2s, top 0.3s var(--ease); }
.site-header.is-solid .menu-toggle span, .site-header--light .menu-toggle span { background: var(--ink); }
.menu-toggle span:nth-child(1) { top: 15px; }
.menu-toggle span:nth-child(2) { top: 21px; }
.menu-toggle span:nth-child(3) { top: 27px; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { top: 21px; transform: rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 72px 0 0 0; z-index: 99; background: var(--ink); color: #fff;
  padding: 24px var(--gutter) 40px; display: grid; align-content: start; gap: 6px;
  opacity: 0; visibility: hidden; transform: translateY(-12px);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
  overflow-y: auto;
}
.mobile-menu.is-open { opacity: 1; visibility: visible; transform: none; }
.mobile-menu a { display: block; padding: 14px 4px; font-size: 1.35rem; font-weight: 700; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.mobile-menu .btn { margin-top: 20px; }

/* ---------- Hero ---------- */
.hero { position: relative; background: var(--ink); color: #fff; overflow: hidden; padding-top: clamp(108px, 12vw, 150px); padding-bottom: clamp(56px, 8vw, 104px); isolation: isolate; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto -10%; height: 90%; z-index: -2;
  background:
    radial-gradient(48% 55% at 78% 22%, rgba(56, 189, 240, 0.34), transparent 70%),
    radial-gradient(42% 48% at 12% 8%, rgba(15, 92, 140, 0.55), transparent 72%),
    radial-gradient(30% 40% at 55% 85%, rgba(47, 211, 166, 0.14), transparent 70%);
  animation: aurora 16s ease-in-out infinite alternate;
}
@keyframes aurora { to { transform: translate3d(-3%, 4%, 0) scale(1.08); } }
.hero-circuit { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; opacity: 0.32; pointer-events: none; }
.hero-circuit path { fill: none; stroke: url(#circuitGrad); stroke-width: 1.6; stroke-linecap: round; stroke-dasharray: 1400; stroke-dashoffset: 1400; animation: draw 3.4s var(--ease) 0.3s forwards; }
.hero-circuit circle { fill: var(--ink); stroke: var(--sky); stroke-width: 1.6; opacity: 0; animation: pop 0.6s var(--ease) 2.2s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes pop { to { opacity: 1; } }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero-copy { display: grid; gap: 22px; justify-items: start; }
.hero .lead { color: var(--on-dark-muted); }
.pill { display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px 7px 8px; border-radius: 999px; background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.14); font-size: 0.88rem; font-weight: 600; color: var(--on-dark); }
html[dir="rtl"] .pill { padding: 7px 8px 7px 14px; }
.pill b { background: var(--grad); color: #fff; border-radius: 999px; padding: 2px 10px; font-size: 0.78rem; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-trust { display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--on-dark-muted); font-size: 0.92rem; }
.hero-trust li { display: inline-flex; align-items: center; gap: 8px; }
.hero-trust li::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 0 4px rgba(47, 211, 166, 0.16); }

/* Device stage */
.stage { position: relative; height: clamp(440px, 52vw, 620px); perspective: 1400px; }
.device { position: absolute; border-radius: 34px; background: #0d1f33; border: 1px solid rgba(255, 255, 255, 0.14); box-shadow: var(--shadow-lg), inset 0 0 0 6px #0a1626; overflow: hidden; }
.device--phone { width: clamp(210px, 23vw, 270px); aspect-ratio: 9 / 18.6; inset-inline-end: 8%; top: 4%; transform: rotate(4deg); animation: floatA 7s ease-in-out infinite; }
html[dir="rtl"] .device--phone { transform: rotate(-4deg); }
.device--card { border-radius: 22px; width: clamp(240px, 27vw, 330px); inset-inline-start: 0; bottom: 6%; animation: floatB 8s ease-in-out infinite; box-shadow: var(--shadow-lg); background: rgba(18, 38, 60, 0.92); backdrop-filter: blur(10px); }
@keyframes floatA { 50% { translate: 0 -14px; } }
@keyframes floatB { 50% { translate: 0 12px; } }
.screen { position: absolute; inset: 6px; border-radius: 28px; background: linear-gradient(180deg, #0f2238, #0b1a2b); padding: 30px 14px 14px; display: grid; align-content: start; gap: 10px; font-size: 11px; color: var(--on-dark); }
.screen::before { content: ""; position: absolute; top: 9px; left: 50%; translate: -50% 0; width: 34%; height: 16px; border-radius: 999px; background: #060e18; }
.ui-title { font-weight: 800; font-size: 14px; }
.ui-sub { color: var(--on-dark-muted); font-size: 10px; margin-top: -6px; }
.ui-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ui-tile { border-radius: 14px; padding: 10px; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.08); display: grid; gap: 6px; }
.ui-tile i { width: 26px; height: 26px; border-radius: 9px; display: block; }
.ui-tile b { font-size: 10.5px; line-height: 1.25; }
.ui-tile small { color: var(--on-dark-muted); font-size: 9px; }
.t1 i { background: rgba(56, 189, 240, 0.25); } .t2 i { background: rgba(224, 138, 0, 0.3); }
.t3 i { background: rgba(194, 65, 140, 0.3); } .t4 i { background: rgba(47, 211, 166, 0.28); }
.ui-row { display: flex; align-items: center; gap: 8px; padding: 9px 10px; border-radius: 12px; background: rgba(255, 255, 255, 0.05); }
.ui-row i { width: 22px; height: 22px; border-radius: 8px; background: rgba(56, 189, 240, 0.25); flex: none; }
.ui-row span { flex: 1; height: 6px; border-radius: 6px; background: rgba(255, 255, 255, 0.16); }
.ui-row em { font-style: normal; font-weight: 800; color: var(--sky); font-size: 10px; }
.card-pad { padding: 18px; display: grid; gap: 12px; color: var(--on-dark); }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 0.85rem; font-weight: 700; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: 0.72rem; font-weight: 700; background: rgba(47, 211, 166, 0.16); color: var(--mint); }
.offer { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 10px 12px; border-radius: 12px; background: rgba(255, 255, 255, 0.05); font-size: 0.8rem; }
.offer small { color: var(--on-dark-muted); }
.offer strong { color: var(--sky); }
.bar { height: 6px; border-radius: 6px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; background: var(--grad); border-radius: 6px; transition: width 1.6s var(--ease) 0.6s; }
.is-in .bar i { width: var(--w, 70%); }
.chip-float { position: absolute; inset-inline-end: 0; bottom: 20%; padding: 10px 14px; border-radius: 14px; background: #fff; color: var(--ink); font-size: 0.82rem; font-weight: 700; box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 10px; animation: floatA 6s ease-in-out 1s infinite; }
.chip-float i { width: 28px; height: 28px; border-radius: 9px; background: var(--grad); display: block; }

/* ---------- Cards / grids ---------- */
.grid { display: grid; gap: clamp(16px, 2vw, 24px); }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 2.6vw, 32px);
  box-shadow: var(--shadow-sm); transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease), border-color 0.3s;
  display: grid; gap: 12px; align-content: start; position: relative; overflow: hidden;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #cfe0ee; }
.card p { color: var(--muted); }
.card .ic { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: rgba(26, 115, 168, 0.1); color: var(--blue); }
.card .ic svg { width: 24px; height: 24px; }
.section--dark .card { background: rgba(255, 255, 255, 0.04); border-color: rgba(255, 255, 255, 0.1); box-shadow: none; }
.section--dark .card:hover { border-color: rgba(56, 189, 240, 0.5); }
.section--dark .card p { color: var(--on-dark-muted); }
.section--dark .card .ic { background: rgba(56, 189, 240, 0.14); color: var(--sky); }

/* About */
.about-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.statement { font-size: clamp(1.5rem, 3vw, 2.4rem); line-height: 1.3; font-weight: 700; letter-spacing: -0.02em; }
html[lang="ar"] .statement { letter-spacing: 0; line-height: 1.5; }
.statement span { color: var(--muted); }
.vm { display: grid; gap: 16px; }
.vm .card h3 { display: flex; align-items: center; gap: 10px; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-top: clamp(36px, 5vw, 64px); }
.stat { background: var(--surface); padding: clamp(22px, 3vw, 36px); display: grid; gap: 6px; }
.stat b { font-size: clamp(2rem, 4.2vw, 3.2rem); line-height: 1; font-weight: 800; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.stat span { color: var(--muted); font-size: 0.95rem; }

/* Apps */
.app {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr); gap: clamp(24px, 4vw, 56px); align-items: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(24px, 4vw, 56px); box-shadow: var(--shadow-sm);
}
.app + .app { margin-top: clamp(18px, 2.4vw, 28px); }
.app:nth-child(even) .app-visual { order: -1; }
.app-body { display: grid; gap: 18px; justify-items: start; }
.app-id { display: flex; align-items: center; gap: 14px; }
.app-id img, .app-icon { width: 60px; height: 60px; border-radius: 17px; box-shadow: var(--shadow-sm); background: #fff; border: 1px solid var(--line); }
.app-id small { display: block; color: var(--muted); font-weight: 600; }
.app-features { display: grid; gap: 10px; }
.app-features li { display: flex; gap: 12px; align-items: flex-start; }
.app-features li::before { content: ""; flex: none; width: 22px; height: 22px; margin-top: 3px; border-radius: 50%; background: rgba(20, 148, 107, 0.12) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2314946b' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 13px no-repeat; }
.platforms { display: flex; flex-wrap: wrap; gap: 8px; }
.tag { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; font-size: 0.8rem; font-weight: 700; background: var(--paper); border: 1px solid var(--line); color: var(--muted); }
.app-visual { position: relative; min-height: 340px; border-radius: var(--radius); overflow: hidden; background: linear-gradient(150deg, var(--ink), var(--ink-2)); display: grid; place-items: center; padding: 28px; isolation: isolate; }
.app-visual::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(60% 60% at 70% 20%, color-mix(in srgb, var(--accent, #38bdf0) 45%, transparent), transparent 70%); }
.mock { width: min(100%, 300px); border-radius: 22px; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.12); padding: 16px; display: grid; gap: 10px; color: var(--on-dark); font-size: 0.82rem; transition: transform 0.6s var(--ease); }
.app:hover .mock { transform: translateY(-6px) scale(1.02); }
.coming { font-size: 0.86rem; color: var(--muted); }

/* Steps */
.steps { counter-reset: step; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(16px, 2vw, 24px); }
.step { position: relative; padding-top: 58px; display: grid; gap: 8px; }
.step::before { counter-increment: step; content: counter(step, decimal-leading-zero); position: absolute; top: 0; inset-inline-start: 0; font-weight: 800; font-size: 0.9rem; color: var(--sky); width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; border: 1.5px solid rgba(56, 189, 240, 0.5); background: var(--ink); z-index: 1; }
.step::after { content: ""; position: absolute; top: 20px; inset-inline-start: 46px; inset-inline-end: -18px; height: 1.5px; background: linear-gradient(90deg, rgba(56, 189, 240, 0.5), transparent); }
html[dir="rtl"] .step::after { background: linear-gradient(270deg, rgba(56, 189, 240, 0.5), transparent); }
.step:last-child::after { display: none; }
.step p { color: var(--on-dark-muted); font-size: 0.97rem; }

/* Download / QR */
.download { display: grid; grid-template-columns: minmax(0, 1.1fr) auto; gap: clamp(28px, 5vw, 72px); align-items: center; background: linear-gradient(135deg, var(--ink), #10304c 60%, var(--navy)); color: #fff; border-radius: var(--radius-lg); padding: clamp(28px, 5vw, 64px); position: relative; overflow: hidden; }
.download .lead { color: var(--on-dark-muted); }
.download-copy { display: grid; gap: 20px; justify-items: start; }
.app-switch { display: inline-flex; padding: 4px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); gap: 4px; flex-wrap: wrap; }
.app-switch button { border: 0; background: transparent; color: var(--on-dark-muted); font-weight: 700; padding: 8px 16px; border-radius: 999px; cursor: pointer; transition: background 0.25s, color 0.25s; }
.app-switch button[aria-pressed="true"] { background: #fff; color: var(--ink); }
.qr { display: grid; gap: 14px; justify-items: center; text-align: center; }
.qr-frame { position: relative; padding: 18px; border-radius: 26px; background: #fff; box-shadow: var(--shadow-lg); transition: transform 0.5s var(--ease); }
.qr-frame:hover { transform: scale(1.03) rotate(-1deg); }
.qr-frame svg, .qr-frame img { width: clamp(170px, 20vw, 220px); height: auto; display: block; }
.qr-frame::after { content: ""; position: absolute; inset-inline: 18px; top: 18px; height: 3px; border-radius: 3px; background: var(--grad); box-shadow: 0 0 18px var(--sky); animation: scan 3.2s ease-in-out infinite; opacity: 0.85; }
@keyframes scan { 0%, 100% { translate: 0 0; } 50% { translate: 0 calc(clamp(170px, 20vw, 220px) - 3px); } }
.qr small { color: var(--on-dark-muted); max-width: 26ch; }

/* Reviews */
.reviews { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2vw, 24px); }
.review { display: grid; gap: 14px; align-content: start; }
.stars { display: inline-flex; gap: 3px; color: #f5a623; }
.stars svg { width: 18px; height: 18px; }
.stars .off { color: #d8e1ea; }
.review blockquote { margin: 0; font-size: 1.02rem; color: var(--text); }
.review footer { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 0.9rem; }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--grad); color: #fff; display: grid; place-items: center; font-weight: 800; flex: none; }
.empty { border: 1.5px dashed var(--line); border-radius: var(--radius); padding: clamp(28px, 4vw, 48px); text-align: center; color: var(--muted); display: grid; gap: 14px; justify-items: center; grid-column: 1 / -1; }
.skeleton { border-radius: var(--radius); min-height: 180px; background: linear-gradient(100deg, #edf2f7 30%, #f7fafc 50%, #edf2f7 70%); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* Forms */
.form { display: grid; gap: 16px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 700; font-size: 0.92rem; }
.field .hint { color: var(--muted); font-size: 0.82rem; }
.input, .select, .textarea {
  width: 100%; min-height: 50px; padding: 12px 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.textarea { min-height: 130px; resize: vertical; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(26, 115, 168, 0.14); }
.input[aria-invalid="true"], .textarea[aria-invalid="true"], .select[aria-invalid="true"] { border-color: var(--danger); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.rating { display: inline-flex; flex-direction: row-reverse; gap: 4px; }
.rating input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.rating label { cursor: pointer; color: #d8e1ea; transition: color 0.15s, transform 0.15s; padding: 2px; }
.rating label svg { width: 32px; height: 32px; }
.rating label:hover, .rating label:hover ~ label, .rating input:checked ~ label { color: #f5a623; }
.rating label:hover { transform: scale(1.12); }
.rating input:focus-visible + label { outline: 3px solid var(--sky); outline-offset: 2px; border-radius: 6px; }
.form-note { font-size: 0.85rem; color: var(--muted); }
.form-note a { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.form-status { min-height: 24px; font-weight: 600; font-size: 0.95rem; }
.form-status.ok { color: var(--success); }
.form-status.err { color: var(--danger); }
.hp { position: absolute; inset-inline-start: -9999px; }

.contact-grid { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(24px, 4vw, 64px); align-items: start; }
.channels { display: grid; gap: 12px; }
.channel { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); transition: border-color 0.2s, transform 0.3s var(--ease); }
.channel:hover { border-color: var(--blue); transform: translateX(4px); }
html[dir="rtl"] .channel:hover { transform: translateX(-4px); }
.channel .ic { width: 44px; height: 44px; border-radius: 13px; background: rgba(26, 115, 168, 0.1); color: var(--blue); display: grid; place-items: center; flex: none; }
.channel .ic svg { width: 22px; height: 22px; }
.channel small { display: block; color: var(--muted); font-size: 0.82rem; }
.channel strong { direction: ltr; unicode-bidi: plaintext; }
.socials { display: flex; flex-wrap: wrap; gap: 10px; }
.social { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--surface); color: var(--muted); transition: color 0.2s, border-color 0.2s, transform 0.3s var(--ease); }
.social:hover { color: var(--blue); border-color: var(--blue); transform: translateY(-3px); }
.social svg { width: 20px; height: 20px; }
.site-footer .social { background: transparent; border-color: rgba(255, 255, 255, 0.14); color: var(--on-dark-muted); }
.site-footer .social:hover { color: #fff; border-color: var(--sky); }

/* FAQ */
.faq { display: grid; gap: 10px; max-width: 860px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 0 22px; transition: border-color 0.2s; }
.faq details[open] { border-color: #cfe0ee; box-shadow: var(--shadow-sm); }
.faq summary { cursor: pointer; list-style: none; padding: 20px 0; font-weight: 700; font-size: 1.05rem; display: flex; justify-content: space-between; gap: 16px; align-items: center; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; width: 12px; height: 12px; border-inline-end: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform 0.3s var(--ease); flex: none; margin-top: -6px; }
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: 6px; }
.faq details p { padding-bottom: 22px; color: var(--muted); }

/* Footer */
.site-footer { background: var(--ink); color: var(--on-dark-muted); padding-top: clamp(56px, 7vw, 96px); padding-bottom: 28px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); gap: clamp(24px, 4vw, 56px); }
.site-footer h3 { color: #fff; font-size: 0.95rem; margin-bottom: 14px; }
.site-footer li + li { margin-top: 10px; }
.site-footer a:hover { color: #fff; }
.footer-brand { display: grid; gap: 16px; align-content: start; max-width: 36ch; }
.footer-bottom { margin-top: clamp(36px, 5vw, 64px); padding-top: 22px; border-top: 1px solid rgba(255, 255, 255, 0.1); display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; font-size: 0.88rem; }
.footer-bottom nav { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.ltr { direction: ltr; unicode-bidi: plaintext; }

/* Legal / inner pages */
.page-hero { background: var(--ink); color: #fff; padding: clamp(120px, 14vw, 170px) 0 clamp(48px, 6vw, 80px); position: relative; overflow: hidden; }
.page-hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(50% 80% at 85% 0%, rgba(56, 189, 240, 0.28), transparent 70%), radial-gradient(40% 70% at 5% 0%, rgba(15, 92, 140, 0.5), transparent 70%); }
.page-hero .wrap { position: relative; display: grid; gap: 16px; }
.prose { max-width: 800px; display: grid; gap: 18px; }
.prose h2 { font-size: 1.5rem; margin-top: 22px; letter-spacing: -0.01em; }
.prose p, .prose li { color: #33455a; }
.prose ul { list-style: disc; padding-inline-start: 22px; display: grid; gap: 8px; }
.prose a { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.toc { position: sticky; top: 96px; display: grid; gap: 8px; font-size: 0.92rem; color: var(--muted); align-content: start; }
.toc a:hover { color: var(--blue); }
.legal-grid { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: clamp(24px, 5vw, 72px); }

/* Chat */
.chat-fab { position: fixed; inset-inline-end: 22px; bottom: 22px; z-index: 90; width: 60px; height: 60px; border-radius: 50%; border: 0; cursor: pointer; background: var(--grad); color: #fff; box-shadow: 0 14px 34px rgba(26, 115, 168, 0.45); display: grid; place-items: center; transition: transform 0.3s var(--ease); }
.chat-fab:hover { transform: scale(1.07); }
.chat-fab svg { width: 26px; height: 26px; }
.chat-fab .dot { position: absolute; top: 4px; inset-inline-end: 4px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; background: var(--danger); color: #fff; font-size: 0.72rem; font-weight: 800; display: grid; place-items: center; border: 2px solid #fff; }
.chat-panel { position: fixed; inset-inline-end: 22px; bottom: 96px; z-index: 91; width: min(380px, calc(100vw - 28px)); height: min(560px, calc(100dvh - 130px)); background: var(--surface); border-radius: 22px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); display: grid; grid-template-rows: auto 1fr auto; overflow: hidden; opacity: 0; visibility: hidden; transform: translateY(16px) scale(0.98); transform-origin: bottom right; transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s; }
html[dir="rtl"] .chat-panel { transform-origin: bottom left; }
.chat-panel.is-open { opacity: 1; visibility: visible; transform: none; }
.chat-head { background: var(--ink); color: #fff; padding: 16px 18px; display: flex; align-items: center; gap: 12px; }
.chat-head img { width: 36px; height: 36px; border-radius: 10px; background: #fff; }
.chat-head small { display: block; color: var(--on-dark-muted); font-size: 0.8rem; }
.chat-head button { margin-inline-start: auto; width: 36px; height: 36px; border-radius: 10px; border: 0; background: rgba(255, 255, 255, 0.1); color: #fff; cursor: pointer; font-size: 1.2rem; line-height: 1; }
.chat-body { overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 8px; background: var(--paper); }
.msg { max-width: 82%; padding: 10px 14px; border-radius: 16px; font-size: 0.95rem; line-height: 1.5; word-break: break-word; white-space: pre-wrap; animation: msgIn 0.3s var(--ease); }
@keyframes msgIn { from { opacity: 0; transform: translateY(6px); } }
.msg time { display: block; font-size: 0.7rem; opacity: 0.7; margin-top: 3px; }
.msg--me { align-self: flex-end; background: var(--blue); color: #fff; border-end-end-radius: 4px; }
.msg--them { align-self: flex-start; background: var(--surface); border: 1px solid var(--line); border-end-start-radius: 4px; }
.chat-note { text-align: center; color: var(--muted); font-size: 0.85rem; padding: 6px 12px; }
.chat-form { display: grid; gap: 10px; padding: 12px; border-top: 1px solid var(--line); background: var(--surface); }
.chat-send { display: flex; gap: 8px; align-items: flex-end; }
.chat-send textarea { min-height: 46px; max-height: 120px; resize: none; }
.chat-send button { width: 46px; height: 46px; border-radius: 14px; border: 0; background: var(--grad); color: #fff; cursor: pointer; flex: none; display: grid; place-items: center; }
.chat-send button svg { width: 20px; height: 20px; }
html[dir="rtl"] .chat-send button svg { transform: scaleX(-1); }

/* Smart download page */
.get { min-height: 100dvh; display: grid; place-items: center; background: var(--ink); color: #fff; padding: 32px var(--gutter); position: relative; overflow: hidden; }
.get::before { content: ""; position: absolute; inset: 0; background: radial-gradient(50% 50% at 80% 10%, rgba(56, 189, 240, 0.3), transparent 70%), radial-gradient(45% 45% at 10% 0%, rgba(15, 92, 140, 0.55), transparent 70%); }
.get-card { position: relative; width: min(460px, 100%); display: grid; gap: 22px; justify-items: center; text-align: center; }
.get-card img { width: 84px; height: 84px; border-radius: 24px; background: #fff; box-shadow: var(--shadow-lg); }
.get-card .store { width: 100%; justify-content: flex-start; }
.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, 0.18); border-top-color: var(--sky); animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); transition-delay: var(--d, 0ms); }
.reveal.is-in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .nav-links { display: none; }
  .menu-toggle { display: block; }
  .nav-actions { margin-inline-start: auto; }
  .nav-actions .btn { display: none; }
  .grid--4, .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .step:nth-child(2n)::after { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .legal-grid { grid-template-columns: 1fr; }
  .toc { position: static; grid-auto-flow: column; overflow-x: auto; white-space: nowrap; padding-bottom: 8px; }
}
@media (max-width: 900px) {
  .hero-grid, .about-grid, .app, .contact-grid, .download { grid-template-columns: 1fr; }
  .hero-copy { justify-items: start; }
  .stage { height: 440px; max-width: 520px; margin-inline: auto; width: 100%; }
  .app:nth-child(even) .app-visual { order: 0; }
  .grid--3, .reviews { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .download { text-align: start; }
  .qr { justify-self: center; }
}
@media (max-width: 600px) {
  .grid--2, .grid--3, .grid--4, .reviews, .steps, .field-row { grid-template-columns: 1fr; }
  .step::after { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .cta-row .btn, .store-row .store { flex: 1 1 100%; }
  .stage { height: 400px; }
  .device--phone { inset-inline-end: 2%; width: 200px; }
  .device--card { width: 230px; }
  .chip-float { display: none; }
  .chat-panel { inset-inline-end: 14px; bottom: 88px; }
  .chat-fab { inset-inline-end: 14px; bottom: 14px; }
  .app-visual { min-height: 280px; }
}
@media (min-width: 1600px) { :root { --wrap: 1320px; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  .reveal { opacity: 1; transform: none; }
  .hero-circuit path { stroke-dashoffset: 0; }
  .hero-circuit circle { opacity: 1; }
  .bar i { width: var(--w, 70%); }
}
@media print { .site-header, .chat-fab, .chat-panel, .site-footer { display: none; } .page-hero { background: none; color: #000; padding: 0; } }

/* Bilingual long-form content: both languages are in the HTML, one is shown. */
html[lang="ar"] [data-lang="en"], html[lang="en"] [data-lang="ar"] { display: none; }

/* ---------- Delete account ---------- */
.danger-zone { max-width: 560px; margin-inline: auto; display: grid; gap: 22px; }
.warning-box { display: flex; gap: 14px; padding: 18px 20px; border-radius: var(--radius); background: #fdeeee; border: 1px solid #f3c5c5; color: #8f1f1f; }
.warning-box svg { width: 26px; height: 26px; flex: none; margin-top: 2px; }
.warning-box strong { display: block; margin-bottom: 4px; }
.warning-box ul { list-style: disc; padding-inline-start: 18px; margin-top: 8px; display: grid; gap: 4px; font-size: 0.94rem; }
.btn--danger { background: var(--danger); color: #fff; box-shadow: 0 10px 24px rgba(214, 69, 69, 0.28); }
.btn--danger:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(214, 69, 69, 0.38); }
.btn--plain { background: var(--ink); color: #fff; }
.btn--plain:hover { transform: translateY(-2px); }
.modal { border: 0; padding: 0; border-radius: 22px; width: min(460px, calc(100vw - 32px)); box-shadow: var(--shadow-lg); color: var(--text); background: var(--surface); }
.modal::backdrop { background: rgba(11, 26, 43, 0.6); backdrop-filter: blur(3px); }
.modal-body { padding: 28px; display: grid; gap: 14px; text-align: center; justify-items: center; }
.modal-icon { width: 60px; height: 60px; border-radius: 50%; background: #fdeeee; color: var(--danger); display: grid; place-items: center; }
.modal-icon svg { width: 30px; height: 30px; }
.modal-name { font-size: 1.3rem; font-weight: 800; letter-spacing: -0.01em; }
.modal-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; width: 100%; margin-top: 8px; }
.overlay { position: fixed; inset: 0; z-index: 300; background: rgba(11, 26, 43, 0.82); display: grid; place-items: center; color: #fff; text-align: center; }
.overlay > div { display: grid; gap: 16px; justify-items: center; padding: 24px; }
@media (max-width: 420px) { .modal-actions { grid-template-columns: 1fr; } }
