/* Halaqa Home website: shared tokens and base styles (index, privacy, support). Same palette as the app theme. */
:root {
  --night: #0F2A30; --night2: #173A40; --night3: #1E474E; --line-night: #3E6A66;
  --gold: #E8B04B; --gold-soft: #F2C46B; --gold-ink: #2B1D05; --gold-text: #8A5A0E;
  --sand: #FBF7F0; --sand2: #F3EADB; --paper: #F6E9D3; --paper-ink: #2B2118; --paper-muted: #8C7A63;
  --ink: #1D2A2C; --muted: #5E6B6A; --mist: #B7C9C6; --light: #F6EFE3; --card-line: #E9E1D3;
  --ui: 'Nunito', 'Noto Naskh Arabic', system-ui, sans-serif; --story: 'Literata', 'Noto Naskh Arabic', Georgia, serif; --arabic: 'Noto Naskh Arabic', 'Geeza Pro', serif;
  --ease: cubic-bezier(0.23, 1, 0.32, 1);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--sand); color: var(--ink); font-family: var(--ui); line-height: 1.6; -webkit-font-smoothing: antialiased; }
[dir="rtl"] body { font-family: var(--arabic); }
img, svg { display: block; }
a { color: inherit; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 720px; }

/* Top bar */
.bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 18px 0; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--light); font-weight: 800; font-size: 17px; }
.brand-ar { font-family: var(--arabic); font-weight: 700; color: var(--gold); font-size: 20px; }
.brand svg { flex: none; }
.langs { display: inline-flex; gap: 2px; padding: 3px; border: 1px solid var(--line-night); border-radius: 999px; direction: ltr; }
.noscript { margin: 0; padding: 14px 16px; background: var(--gold); color: var(--gold-ink); font-weight: 800; text-align: center; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.langs button { background: none; border: 0; color: var(--mist); border-radius: 999px; min-width: 44px; min-height: 44px; padding: 0 12px;
  font: 800 13.5px var(--ui); cursor: pointer; transition: background 200ms var(--ease), color 200ms var(--ease), transform 120ms var(--ease); }
.langs button[lang="ar"] { font-family: var(--arabic); font-size: 15px; font-weight: 700; }
.langs button:hover { color: var(--light); }
.langs button:active { transform: scale(0.96); }
.langs button[aria-pressed="true"] { background: var(--gold); color: var(--gold-ink); }
.lang { background: none; border: 1px solid var(--line-night); color: var(--light); border-radius: 999px; padding: 8px 16px;
  font: 700 14px var(--ui); cursor: pointer; min-height: 44px; transition: background 200ms var(--ease), transform 120ms var(--ease); }
.lang:hover { background: var(--night3); }
.lang:active { transform: scale(0.97); }
.lang[lang="ar"] { font-family: var(--arabic); }

/* Footer */
footer.site { background: var(--night); color: var(--mist); font-size: 14px; padding: 36px 0 44px; }
footer.site .row { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; justify-content: space-between; }
footer.site nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
footer.site a { color: var(--light); text-decoration: none; font-weight: 700; }
footer.site a:hover { color: var(--gold); }
footer.site small { display: block; margin-top: 18px; color: #7F9894; }

/* Legal and help pages */
.page-head { background: var(--night); color: var(--light); padding-bottom: 40px; }
.page-head h1 { font-family: var(--story); font-weight: 500; font-size: clamp(30px, 6vw, 44px); line-height: 1.15; margin: 24px 0 8px; }
[dir="rtl"] .page-head h1, [dir="rtl"] .doc h2 { font-family: var(--arabic); font-weight: 700; }
.page-head p { color: var(--mist); margin: 0; font-size: 17px; }
.doc { padding: 36px 16px 56px; }
.doc h2 { font-family: var(--story); font-weight: 500; font-size: 23px; margin: 34px 0 8px; }
.doc p, .doc li { color: #334042; font-size: 16.5px; }
.doc ul { padding-inline-start: 22px; }
.doc li { margin: 6px 0; }
.doc a { color: var(--gold-text); font-weight: 700; }
.box { background: #fff; border: 1px solid var(--card-line); border-radius: 18px; padding: 18px 20px; margin: 18px 0; }
.box.gold { background: var(--paper); border-color: #EAD7B4; }

footer.site nav a { display: inline-flex; align-items: center; min-height: 44px; }

@media (max-width: 480px) {
  .bar .brand-ar { display: none; }
  [dir="rtl"] .bar .brand-ar { display: inline; }
  [dir="rtl"] .bar .brand > span:not(.brand-ar) { display: none; }
  .brand { white-space: nowrap; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
