:root {
  --bg: #f6f4ef;
  --surface: #ffffff;
  --text: #1c1b19;
  --muted: #6a665e;
  --line: #e2ded5;
  --accent: #0f6b5c;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #131412;
    --surface: #1c1e1b;
    --text: #efede7;
    --muted: #a09c93;
    --line: #2c2f2a;
    --accent: #5fc7b3;
  }
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: 'Segoe UI', 'SF Arabic', 'Geeza Pro', Tahoma, system-ui, -apple-system, Roboto, 'Noto Sans Arabic',
    'Noto Sans', sans-serif;
  font-size: 17px;
  line-height: 1.7;
}

a {
  color: var(--accent);
  text-underline-offset: 0.2em;
}

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

.wrap {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: 0 20px;
}

header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 20px;
  padding-top: 20px;
  padding-bottom: 20px;
}

.brand {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
  text-decoration: none;
}

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
  font-size: 0.95rem;
}

nav a {
  color: var(--muted);
  text-decoration: none;
}

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

main {
  flex: 1;
}

.hero {
  padding: 56px 0 40px;
}

h1 {
  margin: 0 0 6px;
  font-size: clamp(2rem, 7vw, 3rem);
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.logo {
  display: block;
  width: min(320px, 82%);
  height: auto;
  margin-bottom: 18px;
}

@media (prefers-color-scheme: dark) {
  .logo {
    filter: invert(1);
  }
}

.legal {
  margin: 0 0 20px;
  color: var(--muted);
}

.lead {
  margin: 0;
  max-width: 34em;
  font-size: 1.15rem;
}

section {
  padding: 28px 0;
  border-top: 1px solid var(--line);
  scroll-margin-top: 12px;
}

h2 {
  margin: 0 0 14px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
}

:lang(en) > h2 {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
}

section p {
  margin: 0;
  max-width: 38em;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.grid li {
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
}

.grid h3 {
  margin: 0 0 2px;
  font-size: 1.05rem;
}

.grid p {
  color: var(--muted);
}

dl {
  margin: 0;
}

dl div {
  display: grid;
  grid-template-columns: 11em 1fr;
  gap: 4px 16px;
  padding: 8px 0;
}

dl div + div {
  border-top: 1px solid var(--line);
}

dt {
  color: var(--muted);
}

dd {
  margin: 0;
}

@media (max-width: 520px) {
  dl div {
    grid-template-columns: 1fr;
  }
}

footer {
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9rem;
}

footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 20px;
  padding-top: 20px;
  padding-bottom: 28px;
}

footer p {
  margin: 0;
}
