/* Khzenti website, design test: Sky and navy, Apple type with the system
   font (Alexandria for Arabic), one tint. Values mirror app/src/theme/index.ts.
   Light only. Fonts are served from this site, never from a third party. */
@font-face { font-family: Alexandria; font-weight: 400; font-display: swap; src: url(fonts/Alexandria_400Regular.woff2) format("woff2"); }
@font-face { font-family: Alexandria; font-weight: 700; font-display: swap; src: url(fonts/Alexandria_700Bold.woff2) format("woff2"); }
@font-face { font-family: Alexandria; font-weight: 800; font-display: swap; src: url(fonts/Alexandria_800ExtraBold.woff2) format("woff2"); }

:root {
  --base: #E9F0FA;
  --surface: #FFFFFF;
  --surface-alt: #F3F7FC;
  --border: #D3DEF0;
  --ink: #101B33;
  --ink-muted: #52607D;
  --accent: #15306B;
  --violet: #15306B;
  --tint-soft: rgba(21, 48, 107, 0.08);
  --on-violet: #FFFFFF;
  --on-violet-muted: #C9D6F2;
  --on-violet-edge: rgba(255, 255, 255, 0.4);
  --on-ink-muted: #C3CBDA;
  --peach: #FFD9B8;
  --mint: #CDEFE4;
  --coral-soft: #FFECE8;
  --text: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Alexandria, Arial, sans-serif;
  --head: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, Alexandria, Arial, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--base); color: var(--ink); font: 400 16px/24px var(--text); -webkit-font-smoothing: antialiased; }
body[dir="rtl"] { --text: Alexandria, -apple-system, "Segoe UI", Tahoma, Arial, sans-serif; --head: Alexandria, -apple-system, "Segoe UI", Tahoma, Arial, sans-serif; }
[hidden] { display: none !important; }
.wrap { max-width: 680px; margin: 0 auto; }

/* A white header on a hairline, like the app's sign-in. No colour block. */
.top, .hero { background: var(--surface); color: var(--ink); padding-inline: 16px; }
.top { padding-block: 20px 8px; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: block; line-height: 0; }
.brand .logo { height: 28px; width: auto; }
.brand .logo-ar { display: none; }
body[dir="rtl"] .brand .logo-en { display: none; }
body[dir="rtl"] .brand .logo-ar { display: inline; }
/* The language switch is a segmented control, navy on the chosen side. */
.langs { display: flex; gap: 2px; padding: 3px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); }
.langs button {
  min-height: 32px; padding: 0 14px; border-radius: 999px; cursor: pointer; border: 0;
  font: 600 13px/16px var(--text); background: transparent; color: var(--ink-muted);
}
.langs button[data-lang="ar"] { font-family: Alexandria, sans-serif; }
.langs button[aria-pressed="true"] { background: var(--violet); color: var(--on-violet); }
.hero { padding-block: 24px 28px; border-bottom: 1px solid var(--border); }
h1 { margin: 0 0 12px; font: 700 40px/46px var(--head); letter-spacing: -0.8px; }
/* Arabic marks sit outside the Latin line box, so its headings need more room. */
body[dir="rtl"] h1 { line-height: 60px; margin-bottom: 20px; font-weight: 800; }
body[dir="rtl"] h2 { line-height: 38px; }
.lede { margin: 0 0 16px; font-size: 17px; line-height: 26px; }
.hero .lede { margin-bottom: 24px; color: var(--ink-muted); }
.cta {
  display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 28px;
  border-radius: 12px; background: var(--violet); color: var(--on-violet);
  font: 600 17px/22px var(--text); text-decoration: none;
}

/* The page body on the sky base: white cards on a hairline, no shadows. */
.sheet { padding: 16px 16px 32px; background: var(--base); }
.card { margin-bottom: 12px; padding: 24px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); }
.card.peach { background: var(--peach); border-color: transparent; }
.tile { margin-top: 20px; padding: 16px; border-radius: 12px; background: var(--surface-alt); }
.tile p:last-child, .card > :last-child { margin-bottom: 0; }
h2 { margin: 0 0 12px; font: 700 24px/30px var(--head); letter-spacing: -0.4px; }
p, li { margin: 0 0 12px; }
ul { margin: 0 0 12px; padding-inline-start: 20px; }
li::marker { color: var(--violet); }
a { color: var(--violet); text-underline-offset: 2px; }
strong { font-weight: 600; }
code { font-family: inherit; font-weight: 600; }
body[dir="rtl"] h1, body[dir="rtl"] h2 { letter-spacing: 0; }
body[dir="rtl"] strong { font-weight: 700; }

/* Numbered steps */
.steps { margin: 0; padding: 0; list-style: none; counter-reset: step; }
.steps li { position: relative; min-height: 32px; padding-inline-start: 44px; counter-increment: step; }
.steps li::before {
  content: counter(step); position: absolute; inset-inline-start: 0; top: -2px;
  width: 32px; height: 32px; border-radius: 50%; background: var(--violet); color: var(--on-violet);
  display: flex; align-items: center; justify-content: center; font: 700 15px/1 var(--head);
}
body[dir="rtl"] .steps li::before { content: counter(step, arabic-indic); }

.stamp, footer p { margin: 0; font-size: 12px; line-height: 16px; color: var(--ink-muted); text-align: center; }
.stamp { margin-top: 20px; }
footer { padding: 0 16px 40px; }
a:focus-visible, button:focus-visible { outline: 3px solid currentColor; outline-offset: 2px; }

/* Legal pages: long text on white cards */
.hero .stamp { margin: 0; text-align: start; color: var(--ink-muted); }
h2:not(:first-child) { margin-top: 32px; }
h3 { margin: 20px 0 6px; font: 600 17px/24px var(--text); }
.muted { color: var(--ink-muted); font-size: 14px; line-height: 22px; }
.note, .flag { margin: 16px 0; padding: 16px; border-radius: 12px; background: var(--surface-alt); }
.flag { background: var(--peach); }
.note > :last-child, .flag > :last-child { margin-bottom: 0; }
.toc ol { margin: 0; padding-inline-start: 20px; }
.toc li { margin-bottom: 4px; }
table { display: block; overflow-x: auto; width: 100%; margin: 0 0 12px; border-collapse: collapse; font-size: 14px; line-height: 20px; }
th, td { padding: 10px; border-bottom: 1px solid var(--border); text-align: start; vertical-align: top; }
th { font-weight: 600; }
tbody tr:last-child td { border-bottom: 0; }
footer a { color: var(--ink-muted); }

/* Plus: buttons, fields, states. Button variants match the app: one navy
   primary, the quiet one is the soft navy tint. No outlines. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 52px; padding: 0 20px;
  border: 0; border-radius: 12px; background: var(--violet); color: var(--on-violet);
  font: 600 17px/22px var(--text); text-decoration: none; cursor: pointer;
}
.btn.primary { background: var(--accent); color: var(--on-violet); }
.btn.ink { background: var(--violet); color: var(--on-violet); }
.btn.ghost { background: var(--tint-soft); color: var(--violet); }
.btn[disabled] { opacity: 0.5; cursor: default; }
.btn + .btn { margin-top: 10px; }
.row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.row .btn { width: auto; min-height: 34px; padding: 0 14px; border-radius: 999px; font-size: 13px; line-height: 16px; }
.field { display: grid; gap: 6px; margin: 0 0 12px; }
.field span { color: var(--ink-muted); font-size: 13px; line-height: 18px; font-weight: 600; }
.field input { width: 100%; min-height: 50px; padding: 0 16px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-alt); color: var(--ink); font: 400 16px/24px var(--text); }
input:focus-visible { outline: 3px solid var(--violet); outline-offset: 2px; }
.turnstile { min-height: 65px; margin: 0 0 12px; }
.or { margin: 14px 0; color: var(--ink-muted); font-size: 13px; line-height: 18px; text-align: center; }
.meta { color: var(--ink-muted); font-size: 13px; line-height: 18px; }
.status { margin: 12px 0; padding: 12px 16px; border-radius: 12px; background: var(--surface-alt); font-size: 14px; line-height: 20px; }
.status.ok { background: var(--mint); }
.status.err { background: var(--coral-soft); }
.plans { display: grid; gap: 12px; margin: 16px 0; }
.plan { padding: 18px; border-radius: 12px; background: var(--surface-alt); border: 1px solid var(--border); }
.plan h3 { margin: 0 0 4px; }
.plan .price { margin: 4px 0 2px; font: 700 26px/30px var(--head); letter-spacing: -0.5px; }
body[dir="rtl"] .plan .price { letter-spacing: 0; }
.plan .per { margin: 0 0 12px; color: var(--ink-muted); font-size: 13px; line-height: 18px; }
.card > .note:first-child, .card > .status:first-child { margin-top: 0; }

/* Invite page: the code on the navy tag, as in the emails */
.codeTag { padding: 20px; border-radius: 14px; background: var(--violet); color: var(--on-violet); text-align: center; }
.codeTag span { display: block; color: var(--on-violet-muted); font-size: 13px; line-height: 18px; }
.codeTag strong { display: block; margin-top: 4px; padding-inline-start: 8px; font: 700 34px/42px ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: 8px; }
body[dir="rtl"] .codeTag strong { font-family: ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: 8px; }
.invite-reward { margin: 14px 0; }
.invite-get { margin-top: 12px; }
.invite-get .note { margin-top: 0; }
.invite-get .meta { margin: 8px 0 12px; text-align: center; }

@media (min-width: 560px) { .plans { grid-template-columns: 1fr 1fr; } }
@media (min-width: 600px) { .hero { padding-bottom: 36px; } .card { padding: 32px; } }

/* Invite page: one block per phone, this phone's first */
.platform + .platform { margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--border); }
.platform .steps { margin-top: 16px; }
.platform .steps li { margin-bottom: 10px; }
.platform .meta { margin: 10px 0 0; }
.qr { display: flex; align-items: center; gap: 14px; margin-top: 12px; padding: 12px; border-radius: 12px; background: var(--surface-alt); font-size: 13px; line-height: 18px; }
.qr img { display: block; width: 96px; height: 96px; flex: none; padding: 6px; border-radius: 8px; background: var(--surface); }
