:root {
  --bg: #fbfaff; --surface: #ffffff; --tint: #f3f0fe; --text: #15112a; --muted: #55506e;
  --line: #e5dffa; --brand: #5b3fd9; --brand-strong: #4527c4; --on-brand: #ffffff; --accent: #0f9f97;
  --glow-a: rgba(139, 108, 255, .38); --glow-b: rgba(79, 224, 201, .30); --glow-c: rgba(255, 176, 110, .28);
  --shadow: 0 24px 60px -30px rgba(69, 39, 196, .45);
  --lift: 0 28px 60px -28px rgba(69, 39, 196, .55);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c0919; --surface: #17132c; --tint: #120e24; --text: #f2effd; --muted: #b5aed1;
    --line: #2d2653; --brand: #8f74ff; --brand-strong: #ab97ff; --on-brand: #110c25; --accent: #4fe0c9;
    --glow-a: rgba(139, 108, 255, .34); --glow-b: rgba(79, 224, 201, .18); --glow-c: rgba(255, 154, 77, .14);
    --shadow: 0 24px 60px -30px rgba(0, 0, 0, .85);
    --lift: 0 28px 60px -24px rgba(0, 0, 0, .9);
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5.5rem; }
body { margin: 0; background: var(--bg); color: var(--text); font: 1.0625rem/1.65 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; overflow-x: hidden; }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .6em; text-wrap: balance; overflow-wrap: break-word; hyphens: auto; }
h1 { font-size: clamp(2.25rem, 5.6vw, 4rem); letter-spacing: -.03em; font-weight: 800; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); letter-spacing: -.02em; font-weight: 750; }
h3 { font-size: 1.2rem; }
a { color: var(--brand-strong); }
a:focus-visible, summary:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; border-radius: 8px; }
ul, ol { padding: 0; margin: 0; list-style: none; }
img { max-width: 100%; height: auto; }
.wrap { width: min(72rem, 100% - 2.5rem); margin-inline: auto; }
.narrow { width: min(46rem, 100% - 2.5rem); }
.center { text-align: center; }
.center .buttons { justify-content: center; }
section { padding: 5.5rem 0; position: relative; }
.tint { background: var(--tint); }
.muted, .lead { color: var(--muted); }
.lead { font-size: 1.22rem; max-width: 36rem; }
.heading { text-align: center; max-width: 44rem; margin: 0 auto 3rem; }
.heading .lead { margin-inline: auto; }
.statement { font-size: clamp(1.2rem, 2.2vw, 1.5rem); line-height: 1.6; color: var(--muted); }
.skip { position: absolute; inset-inline-start: -999rem; }
.skip:focus { inset-inline-start: 1rem; top: 1rem; z-index: 20; background: var(--surface); padding: .5rem 1rem; border-radius: 8px; }

/* header */
.top { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 82%, transparent); border-bottom: 1px solid var(--line); backdrop-filter: blur(16px) saturate(1.4); }
.bar { display: flex; align-items: center; gap: 1rem; min-height: 4.5rem; flex-wrap: wrap; padding-block: .6rem; }
.logo { display: flex; align-items: center; gap: .6rem; font-weight: 800; font-size: 1.25rem; letter-spacing: -.01em; color: var(--text); text-decoration: none; }
.logo img { border-radius: 10px; }
nav { display: flex; gap: .35rem; margin-inline: auto; flex-wrap: wrap; }
nav a { color: var(--muted); text-decoration: none; padding: .4rem .75rem; border-radius: 999px; font-size: .98rem; }
nav a:hover { color: var(--text); background: var(--tint); }
.actions { display: flex; gap: .6rem; align-items: center; margin-inline-start: auto; flex-wrap: wrap; justify-content: flex-end; }
.lang { position: relative; }
.lang summary { cursor: pointer; list-style: none; padding: .45rem .85rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); font-size: .95rem; }
.lang summary::-webkit-details-marker { display: none; }
.lang summary::after { content: "\25BE"; margin-inline-start: .4rem; color: var(--muted); }
.lang ul { position: absolute; inset-inline-end: 0; margin-top: .5rem; min-width: 10rem; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--lift); padding: .35rem; z-index: 15; }
.lang a { display: block; padding: .45rem .75rem; border-radius: 9px; color: var(--text); text-decoration: none; }
.lang a:hover, .lang a[aria-current] { background: var(--tint); }

/* buttons */
.button { display: inline-block; padding: .8rem 1.45rem; border-radius: 999px; background: linear-gradient(135deg, var(--brand), var(--brand-strong)); color: var(--on-brand); text-decoration: none; font-weight: 650; border: 1px solid transparent; box-shadow: 0 12px 28px -14px var(--brand); transition: transform .18s ease, box-shadow .18s ease; }
.button:hover { transform: translateY(-2px); box-shadow: 0 18px 34px -14px var(--brand); }
.button.ghost { background: var(--surface); color: var(--brand-strong); border-color: var(--line); box-shadow: none; }
.button.ghost:hover { border-color: var(--brand); }
.button.light { background: #fff; color: #2f1c85; box-shadow: 0 16px 32px -16px rgba(0, 0, 0, .6); }
.actions .button { padding: .5rem 1rem; font-size: .95rem; }
.buttons { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: 1.75rem; }

/* hero */
.hero { padding: 5.5rem 0 5rem; isolation: isolate; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: -20% -10% 0; z-index: -2; pointer-events: none;
  background: radial-gradient(40% 45% at 18% 28%, var(--glow-a), transparent 70%), radial-gradient(36% 40% at 82% 22%, var(--glow-b), transparent 70%), radial-gradient(34% 38% at 70% 82%, var(--glow-c), transparent 70%); }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .6;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(70% 60% at 50% 30%, #000, transparent); mask-image: radial-gradient(70% 60% at 50% 30%, #000, transparent); }
.split { display: grid; grid-template-columns: 1.1fr 1fr; gap: 4rem; align-items: center; }
.split > * { min-width: 0; }
.hero h1 { background: linear-gradient(115deg, var(--text) 35%, var(--brand) 75%, var(--accent)); -webkit-background-clip: text; background-clip: text; color: transparent; padding-bottom: .08em; }
.badges { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; margin-top: 2rem; }
.badges li { position: relative; padding-inline-start: 1.6rem; font-size: .95rem; color: var(--muted); }
.badges li::before { content: "\2713"; position: absolute; inset-inline-start: 0; top: .15em; width: 1.15rem; height: 1.15rem; border-radius: 50%; display: grid; place-items: center; font-size: .7rem; font-weight: 800; background: var(--accent); color: var(--bg); }

/* messages */
.stage { position: relative; padding: 1rem 0 0; }
.chips { display: flex; gap: .5rem; justify-content: flex-end; margin-bottom: 1rem; }
.chips li { font-size: .8rem; font-weight: 700; letter-spacing: .04em; padding: .35rem .7rem; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); animation: drift 6s ease-in-out infinite; }
.chips li:nth-child(2n) { animation-delay: -2s; }
.chips li:nth-child(3n) { animation-delay: -4s; }
.message { margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 1.5rem; box-shadow: var(--shadow); }
.message figcaption { font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--brand-strong); }
.message .to { color: var(--muted); font-size: .95rem; margin: .5rem 0 0; }
.message blockquote { margin: .8rem 0 0; background: var(--tint); border-radius: 18px; border-start-start-radius: 5px; padding: 1rem 1.15rem; }
.message.main { box-shadow: var(--lift); transform: rotate(-1deg); }
.message.reply { margin: 0; margin-block-start: -.4rem; margin-inline-start: auto; width: min(22rem, 88%); position: relative; inset-inline-end: -1rem; padding: 1.1rem 1.25rem; box-shadow: var(--lift); animation: drift 7s ease-in-out infinite; }
.message.reply figcaption { color: var(--accent); }
.message.reply blockquote { background: color-mix(in srgb, var(--accent) 14%, transparent); border-radius: 18px; border-start-end-radius: 5px; }
.message.plain { box-shadow: none; background: transparent; border-style: dashed; }
.message.plain figcaption { color: var(--muted); }
.message.plain blockquote { background: transparent; padding: 0; color: var(--muted); }
.message.better { border-color: var(--brand); box-shadow: var(--lift); }
.compare { gap: 1.5rem; align-items: stretch; }
@keyframes drift { 0%, 100% { translate: 0 0; } 50% { translate: 0 -8px; } }

/* sections */
.strip { padding: 2.25rem 0; border-block: 1px solid var(--line); background: var(--surface); }
.strip .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .75rem 1.5rem; }
.strip h2 { font-size: 1rem; font-weight: 650; color: var(--muted); margin: 0; letter-spacing: 0; text-align: center; }
.pills { display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; }
.pills li { padding: .4rem .9rem; border-radius: 999px; background: var(--tint); border: 1px solid var(--line); font-size: .93rem; }
.grid, .steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 1.6rem; box-shadow: var(--shadow); transition: transform .25s ease, border-color .25s ease; }
.card:hover { transform: translateY(-6px); border-color: var(--brand); }
.card p { margin: 0; color: var(--muted); }
.card .art { display: block; width: 100%; margin-bottom: 1.25rem; }
.steps { counter-reset: step; }
.step { counter-increment: step; position: relative; }
.step::after { content: counter(step); position: absolute; top: 1rem; inset-inline-start: 1rem; display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 14px; background: linear-gradient(135deg, var(--brand), var(--brand-strong)); color: var(--on-brand); font-weight: 800; box-shadow: var(--shadow); }
.flow { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; counter-reset: flow; }
.stage-step { counter-increment: flow; position: relative; padding: 1.35rem 1.2rem; }
.stage-step.auto { border-color: color-mix(in srgb, var(--brand) 45%, var(--line)); background: linear-gradient(180deg, color-mix(in srgb, var(--brand) 9%, var(--surface)), var(--surface)); }
.stage-step h3 { font-size: 1.05rem; }
.stage-step p { font-size: .95rem; }
.stage-step:not(:last-child)::after { content: "\2192"; position: absolute; inset-inline-end: -.95rem; top: 1.25rem; z-index: 1; width: 1.5rem; height: 1.5rem; border-radius: 50%; display: grid; place-items: center; font-size: .85rem; background: var(--surface); border: 1px solid var(--line); color: var(--brand-strong); }
.who { display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; padding: .25rem .65rem; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); margin-bottom: .9rem; }
.stage-step.auto .who { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.planned { max-width: 44rem; margin: 1.75rem auto 0; text-align: center; border: 2px dashed var(--line); border-radius: 22px; padding: 1.4rem 1.5rem; }
.planned .who { border-color: var(--accent); color: var(--accent); margin-bottom: .6rem; }
.planned h3 { margin-bottom: .3rem; }
.planned p { margin: 0; color: var(--muted); }
.icon { display: grid; place-items: center; width: 3.1rem; height: 3.1rem; margin-bottom: 1.1rem; border-radius: 16px; color: var(--brand-strong); background: linear-gradient(135deg, var(--glow-a), var(--glow-b)); }
.languages .art { width: 100%; }
.samples { display: grid; gap: .75rem; margin-top: 1.75rem; }
.sample { display: grid; grid-template-columns: 7.5rem 1fr; gap: .75rem; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: .75rem 1rem; box-shadow: var(--shadow); }
.sample span { font-size: .8rem; font-weight: 750; color: var(--brand-strong); }
.sample p { margin: 0; font-size: .98rem; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; }
.ticks li { position: relative; padding-block: 1rem; padding-inline: 3.4rem 1.1rem; margin-bottom: .85rem; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
.ticks li::before { content: "\2713"; position: absolute; inset-inline-start: 1rem; top: 1.1rem; width: 1.6rem; height: 1.6rem; border-radius: 50%; display: grid; place-items: center; font-size: .85rem; font-weight: 800; background: var(--accent); color: var(--bg); }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 28px; padding: clamp(1.5rem, 4vw, 2.75rem); box-shadow: var(--lift); }
.price { font-size: 1.2rem; font-weight: 700; }
.notice { border: 1px solid var(--line); border-inline-start: 5px solid var(--accent); border-radius: 14px; background: var(--tint); padding: 1rem 1.15rem; margin-top: 1.5rem; }
details:not(.lang) { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; margin-bottom: .85rem; transition: border-color .2s ease; }
details:not(.lang)[open] { border-color: var(--brand); box-shadow: var(--shadow); }
details:not(.lang) summary { cursor: pointer; font-weight: 650; padding-block: 1.1rem; padding-inline: 1.35rem 3rem; list-style: none; position: relative; }
details:not(.lang) summary::-webkit-details-marker { display: none; }
details:not(.lang) summary::after { content: "+"; position: absolute; inset-inline-end: 1.35rem; top: 50%; translate: 0 -50%; font-size: 1.5rem; font-weight: 400; color: var(--brand-strong); }
details:not(.lang)[open] summary::after { content: "\2212"; }
details:not(.lang) p { margin: 0; padding: 0 1.35rem 1.25rem; color: var(--muted); }
.banner { position: relative; overflow: hidden; isolation: isolate; text-align: center; color: #fff; border-radius: 36px; padding: clamp(3rem, 7vw, 5rem) 1.5rem; background: linear-gradient(135deg, #3b1fb0, #5b3fd9 55%, #0f8f95); box-shadow: var(--lift); }
.banner::before, .banner::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; background: rgba(255, 255, 255, .10); }
.banner::before { width: 22rem; height: 22rem; top: -11rem; left: -6rem; }
.banner::after { width: 28rem; height: 28rem; bottom: -18rem; right: -8rem; }
.banner h2 { max-width: 34rem; margin-inline: auto; }
.banner .buttons { justify-content: center; }

/* sign-up page */
.join { min-height: calc(100vh - 12rem); }
.join .split { align-items: start; }
.join h1 { font-size: clamp(2rem, 4vw, 2.75rem); }
.join .art { width: min(22rem, 100%); display: block; margin-bottom: 1.5rem; }
.timeline { counter-reset: line; }
.timeline li { counter-increment: line; position: relative; padding-block-end: 1.5rem; padding-inline-start: 3.6rem; }
.timeline li::before { content: counter(line); position: absolute; inset-inline-start: 0; top: -.1rem; display: grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--brand-strong)); color: var(--on-brand); font-weight: 800; }
.timeline li:not(:last-child)::after { content: ""; position: absolute; inset-inline-start: 1.2rem; top: 2.6rem; bottom: .2rem; width: 2px; background: var(--line); }
.timeline h3 { margin-bottom: .25rem; }
.timeline p { margin: 0; color: var(--muted); }

/* footer, legal, chooser */
footer { padding: 2.5rem 0 3rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .95rem; background: var(--surface); }
.links { display: flex; gap: 1.25rem; flex-wrap: wrap; }
.chooser { padding: 4rem 0; }
.chooser li { margin: .5rem 0; font-size: 1.2rem; }
.legal { padding: 3.5rem 0; }
.legal section { padding: .75rem 0; }

/* right-to-left (Arabic): letters join, so no letter spacing; a little more line height */
[dir="rtl"] body { font-family: "Segoe UI", "Noto Sans Arabic", "Geeza Pro", Tahoma, system-ui, sans-serif; line-height: 1.8; }
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3 { letter-spacing: 0; line-height: 1.35; hyphens: manual; }
[dir="rtl"] .who, [dir="rtl"] .message figcaption { letter-spacing: 0; font-size: .85rem; }
[dir="rtl"] .stage-step:not(:last-child)::after { content: "\2190"; }
[dir="rtl"] .message.main { transform: rotate(1deg); }
.sample[dir="rtl"] { font-family: "Segoe UI", "Noto Sans Arabic", "Geeza Pro", Tahoma, sans-serif; }

/* fade up on scroll (site.js adds these classes) */
.reveal { transition: opacity .7s ease, translate .7s ease, transform .25s ease, border-color .25s ease; }
.reveal.waiting { opacity: 0; translate: 0 28px; }

@media (max-width: 72rem) {
  .flow { grid-template-columns: repeat(2, 1fr); }
  .stage-step:not(:last-child)::after, [dir="rtl"] .stage-step:not(:last-child)::after { content: none; }
}
@media (max-width: 60rem) {
  nav { display: none; }
  .split { grid-template-columns: 1fr; gap: 3rem; }
  .grid, .steps { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 40rem) {
  section { padding: 3.5rem 0; }
  .strip { padding: 1.75rem 0; }
  .hero { padding: 2.75rem 0 3.5rem; }
  .grid, .steps, .two, .flow { grid-template-columns: 1fr; }
  .two { gap: 1.25rem; }
  /* One short header row; the sign-up button moves to the bottom of the screen, under the thumb.
     (No blur here: a blurred header would hold the fixed button inside itself.) */
  .top { background: var(--bg); backdrop-filter: none; }
  .bar { min-height: 4rem; gap: .4rem; width: calc(100% - 1.5rem); }
  .logo { font-size: 1.05rem; gap: .35rem; }
  .logo img { width: 28px; height: 28px; }
  .actions { gap: .35rem; }
  .lang summary { padding: .4rem .55rem; font-size: .85rem; }
  .lang summary::after { margin-inline-start: .25rem; }
  .actions .button { padding: .42rem .65rem; font-size: .85rem; }
  .actions .button:not(.ghost) { position: fixed; inset-inline: 1rem; bottom: 1rem; z-index: 20; text-align: center; padding: .85rem 1.25rem; font-size: 1.05rem; box-shadow: 0 14px 30px -10px rgba(20, 10, 70, .6); }
  footer { padding-bottom: 6rem; }
  .message.reply { inset-inline-end: 0; }
  .message.main { transform: none; }
  .sample { grid-template-columns: 1fr; gap: .15rem; }
  .banner { border-radius: 26px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
