/* Arabic Financial Glossary — single stylesheet.
   RTL-first, optimised for long-form Arabic reading and small screens. */

:root {
  --ink: #1a1a1a;
  --ink-soft: #555;
  --bg: #fdfdfc;
  --accent: #0b6b57;
  --accent-soft: #e6f2ef;
  --rule: #e2e2dd;
  --max: 44rem;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, system-ui, sans-serif;
  font-size: 1.125rem;
  line-height: 1.9;
}

main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
}

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration: none; }

/* Header / footer */
.site-header {
  border-bottom: 1px solid var(--rule);
  background: #fff;
}
.site-title {
  display: block;
  max-width: var(--max);
  margin: 0 auto;
  padding: 1rem 1.25rem;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--ink);
  text-decoration: none;
}
.site-footer {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.5rem 1.25rem 3rem;
  color: var(--ink-soft);
  font-size: 0.95rem;
  border-top: 1px solid var(--rule);
}

/* Headings */
h1 { font-size: 1.9rem; line-height: 1.4; margin: 0.2rem 0 0.6rem; }
h2 { font-size: 1.3rem; margin: 2rem 0 0.6rem; }

.lede { color: var(--ink-soft); font-size: 1.05rem; }

/* Index: category lists */
.category { margin-top: 2.5rem; }
.category h2 {
  padding-bottom: 0.3rem;
  border-bottom: 2px solid var(--accent-soft);
}
.term-list { list-style: none; margin: 0; padding: 0; }
.term-list li { border-bottom: 1px solid var(--rule); }
.term-list a {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 0.75rem 0.25rem;
  text-decoration: none;
  color: var(--ink);
}
.term-list a:hover { background: var(--accent-soft); }
.term-ar { font-weight: 600; }
.term-en { color: var(--ink-soft); font-size: 0.95rem; }

/* Term page */
.breadcrumb {
  font-size: 0.95rem;
  color: var(--ink-soft);
  margin-bottom: 1rem;
}
.breadcrumb a { color: var(--ink-soft); }
.breadcrumb span { margin: 0 0.4rem; }

.term-en-label {
  color: var(--ink-soft);
  font-size: 1rem;
  margin-top: 0;
}
.term-en-label strong { color: var(--ink); }

.definition { margin: 1.25rem 0; }
.definition p { margin: 0 0 1rem; }

.example {
  background: var(--accent-soft);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
}
.example h2 { margin-top: 0; font-size: 1.05rem; }
.example p { margin: 0; }

.related ul { list-style: none; margin: 0; padding: 0; }
.related li { padding: 0.4rem 0; border-bottom: 1px solid var(--rule); }
.related span { color: var(--ink-soft); font-size: 0.9rem; }

@media (max-width: 32rem) {
  body { font-size: 1.0625rem; }
  h1 { font-size: 1.55rem; }
  .term-list a { flex-direction: column; gap: 0.15rem; }
}
