/* Ramo — shared styles for the public site (privacy / terms / account deletion).
   No build step, no framework, no external requests. Cloudflare Pages serves this
   directory as-is. */

:root {
  --bg: #ffffff;
  --surface: #f6f7f9;
  --text: #16181d;
  --muted: #5b6270;
  --line: #e3e6ea;
  --accent: #0d9488;
  --accent-strong: #0f766e;
  --danger: #b42318;
  --radius: 12px;
  --maxw: 46rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1013;
    --surface: #171a1f;
    --text: #e8eaed;
    --muted: #9aa2af;
    --line: #262b32;
    --accent: #2dd4bf;
    --accent-strong: #5eead4;
    --danger: #f97066;
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans Arabic",
               "Cairo", Tahoma, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.7;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 2.5rem 1.25rem 5rem;
}

/* ── Header ──────────────────────────────────────────────────────────────── */
header.site {
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

header.site .wrap {
  padding-block: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.brand {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
}

.brand span { color: var(--accent); }

nav.site a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
  margin-inline-start: 1.1rem;
}

nav.site a:hover { color: var(--accent); }

/* ── Language sections ───────────────────────────────────────────────────── */
section[lang="ar"] { direction: rtl; text-align: right; }
section[lang="en"] { direction: ltr; text-align: left; }

.langbar {
  display: flex;
  gap: .5rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.langbar a {
  display: inline-block;
  padding: .4rem .9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: .9rem;
  color: var(--muted);
  text-decoration: none;
}

.langbar a:hover { border-color: var(--accent); color: var(--accent); }

.divider {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 3.5rem 0;
}

/* ── Typography ──────────────────────────────────────────────────────────── */
h1 { font-size: 1.9rem; line-height: 1.25; margin: 0 0 .5rem; letter-spacing: -0.02em; }
h2 { font-size: 1.25rem; margin: 2.25rem 0 .6rem; letter-spacing: -0.01em; }
h3 { font-size: 1.05rem; margin: 1.5rem 0 .4rem; }

.updated { color: var(--muted); font-size: .9rem; margin: 0 0 2rem; }

p { margin: 0 0 1rem; }

ul, ol { margin: 0 0 1rem; padding-inline-start: 1.4rem; }
li { margin-bottom: .4rem; }

a { color: var(--accent); }

code {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: .1rem .35rem;
  font-size: .9em;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  direction: ltr;
  display: inline-block;
}

/* ── Callout ─────────────────────────────────────────────────────────────── */
.note {
  background: var(--surface);
  border: 1px solid var(--line);
  border-inline-start: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 1rem 1.15rem;
  margin: 1.5rem 0;
}

.note.warn { border-inline-start-color: var(--danger); }

.note p:last-child { margin-bottom: 0; }

/* ── Table ───────────────────────────────────────────────────────────────── */
.tablewrap { overflow-x: auto; margin: 1rem 0 1.5rem; }

table {
  border-collapse: collapse;
  width: 100%;
  font-size: .95rem;
  min-width: 30rem;
}

th, td {
  border: 1px solid var(--line);
  padding: .6rem .75rem;
  text-align: inherit;
  vertical-align: top;
}

th { background: var(--surface); font-weight: 600; }

/* ── Steps ───────────────────────────────────────────────────────────────── */
ol.steps { counter-reset: step; list-style: none; padding-inline-start: 0; }

ol.steps > li {
  counter-increment: step;
  position: relative;
  padding-inline-start: 2.4rem;
  margin-bottom: 1rem;
}

ol.steps > li::before {
  content: counter(step);
  position: absolute;
  inset-inline-start: 0;
  top: .15rem;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: .85rem;
  font-weight: 700;
  display: grid;
  place-items: center;
}

/* ── Footer ──────────────────────────────────────────────────────────────── */
footer.site {
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: .9rem;
}

footer.site .wrap { padding-block: 1.5rem 2.5rem; }
footer.site a { color: var(--muted); }
