/* Macanc information pages (terms, privacy, cookies, copyright, guidelines, security, 404, error), Dec 2026 look:
   the same calm near-black, off-white text and one warm sand accent as the download page, a serif title in English,
   Saudi for Arabic, the bubble-only logo, a list of sections beside the text on wide screens, and an English / Arabic switch. */
@font-face { font-family: 'Instrument Serif'; src: url('/vendor/fonts/instrument-serif/InstrumentSerif-Regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Inter'; src: url('/vendor/fonts/inter/Inter-latin.woff2') format('woff2'); font-weight: 100 900; font-display: swap; }
@font-face { font-family: 'Saudi'; src: url('/vendor/fonts/saudi/Saudi-Regular.ttf') format('truetype'); font-weight: 400; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: 'Saudi'; src: url('/vendor/fonts/saudi/Saudi-SemiBold.ttf') format('truetype'); font-weight: 600 700; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF; }

:root { color-scheme: dark; --pg-bg: #0b0b0c; --pg-panel: #141416; --pg-text: #d9d8d4; --pg-bright: #f1f0ec; --pg-mut: #96969c; --pg-line: rgba(255,255,255,.09); --accent: #d9a574; --pg-ac-soft: #e3cfae; }
@media (prefers-color-scheme: light) { :root { color-scheme: light; --pg-bg: #f6f4ef; --pg-panel: #ffffff; --pg-text: #2b2a28; --pg-bright: #121211; --pg-mut: #6f6d68; --pg-line: rgba(0,0,0,.1); --accent: #9a6435; --pg-ac-soft: #8a5a2f; } }
* { box-sizing: border-box; }
html { background: var(--pg-bg); }
body { margin: 0 !important; padding: 0 !important; max-width: none !important; background: var(--pg-bg); color: var(--pg-text); font: 16px/1.7 Inter, system-ui, -apple-system, 'Segoe UI', sans-serif; -webkit-font-smoothing: antialiased; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: 420px; z-index: -1; pointer-events: none; background: radial-gradient(60% 100% at 50% 0%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 70%); }
[dir="rtl"], [lang="ar"] { font-family: 'Saudi', Inter, system-ui, sans-serif; }
a { color: var(--pg-ac-soft); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--accent) 45%, transparent); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--accent); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
code { font: 13.5px ui-monospace, SFMono-Regular, Menlo, monospace; background: var(--pg-line); padding: .1em .4em; border-radius: 5px; }
.pg-skip { position: absolute; top: 12px; inset-inline-start: 16px; z-index: 9; background: var(--pg-panel); padding: 8px 12px; transform: translateY(-200%); }
.pg-skip:focus { transform: none; }

/* top bar: bubble logo, link to the download page, language switch */
.pg-top { max-width: 1120px; margin: 0 auto; padding: 18px 24px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.pg-brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--pg-bright); font: 700 17px Inter, sans-serif; }
.pg-brand img { width: 30px; height: 30px; }
.pg-brand span { font: 600 14px 'Saudi', sans-serif; color: #aab2cc; }
.pg-nav { display: flex; align-items: center; gap: 20px; font-size: 14px; }
.pg-nav a { color: var(--pg-mut); text-decoration: none; white-space: nowrap; }
.pg-nav a:hover { color: var(--pg-bright); }
.pg-lang { font: inherit; font-size: 14px; color: var(--pg-bright); background: transparent; border: 1px solid color-mix(in srgb, var(--pg-bright) 25%, transparent); border-radius: 999px; padding: 7px 16px; cursor: pointer; min-height: 36px; }
.pg-lang:hover { border-color: var(--accent); }

/* the text, with the list of sections beside it on wide screens */
.pg-wrap { max-width: 1120px; margin: 0 auto; padding: 24px 24px 40px; display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 56px; }
.pg-toc { position: sticky; top: 24px; align-self: start; font-size: 14px; padding-top: 118px; }
.pg-toc p { margin: 0 0 10px; font: 600 11.5px Inter, sans-serif; letter-spacing: .14em; text-transform: uppercase; color: var(--pg-mut); }
[dir="rtl"] .pg-toc p { letter-spacing: 0; font: 600 13px 'Saudi', sans-serif; }
.pg-toc ol { list-style: none; margin: 0; padding: 0; border-inline-start: 1px solid var(--pg-line); }
.pg-toc a { display: block; padding: 5px 14px; margin-inline-start: -1px; border-inline-start: 1px solid transparent; color: var(--pg-mut); text-decoration: none; line-height: 1.45; }
.pg-toc a:hover, .pg-toc a.on { color: var(--pg-bright); border-inline-start-color: var(--accent); }
.pg-doc { max-width: 44rem; min-width: 0; }
.pg-doc h1 { font: 400 clamp(40px, 6vw, 64px)/1.02 'Instrument Serif', Georgia, serif; letter-spacing: -.015em; color: var(--pg-bright); margin: 26px 0 14px; }
.pg-doc [lang="ar"] h1, .pg-doc[dir="rtl"] h1, article[lang="ar"] h1 { font: 600 clamp(32px, 5vw, 46px)/1.25 'Saudi', sans-serif; letter-spacing: 0; }
.pg-doc .muted { color: var(--pg-mut); font-size: 14px; opacity: 1; }
.pg-doc h2 { font: 600 20px/1.35 Inter, sans-serif; color: var(--pg-bright); margin: 44px 0 10px; padding-top: 22px; border-top: 1px solid var(--pg-line); scroll-margin-top: 20px; }
article[lang="ar"] h2 { font-family: 'Saudi', sans-serif; font-size: 21px; }
.pg-doc p, .pg-doc li { color: var(--pg-text); }
.pg-doc ul { padding-inline-start: 1.2em; }
.pg-doc li { margin: 8px 0; }
.pg-doc li::marker { color: var(--accent); }
.pg-doc b { color: var(--pg-bright); font-weight: 600; }
.pg-doc .pg-lead { font-size: 18px; color: var(--pg-bright); }

/* footer: every information page, and the copyright line */
.pg-foot { max-width: 1120px; margin: 0 auto; padding: 26px 24px 40px; border-top: 1px solid var(--pg-line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px; font-size: 14px; color: var(--pg-mut); }
.pg-foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.pg-foot a { color: var(--pg-mut); text-decoration: none; }
.pg-foot a:hover, .pg-foot a[aria-current] { color: var(--pg-bright); }
.pg-foot p { margin: 0; }

.pg-tocm { display: none; }
@media (max-width: 900px) {
  .pg-wrap { grid-template-columns: 1fr; gap: 0; padding-top: 4px; }
  .pg-toc { display: none; }
  .pg-tocm { display: block; margin: 18px 0 6px; border: 1px solid var(--pg-line); border-radius: 12px; background: var(--pg-panel); font-size: 15px; }
  .pg-tocm summary { cursor: pointer; padding: 12px 16px; min-height: 44px; color: var(--pg-bright); font-weight: 600; }
  .pg-tocm ol { list-style: none; margin: 0; padding: 0 8px 10px; }
  .pg-tocm a { display: block; padding: 9px 8px; color: var(--pg-mut); text-decoration: none; }
}
@media (max-width: 560px) {
  .pg-top { padding: 14px 16px; }
  .pg-nav { gap: 14px; }
  .pg-brand span, .pg-nav a[href="/"] { display: none; }
  .pg-wrap { padding: 0 16px 28px; }
  .pg-doc h2 { margin-top: 34px; }
  .pg-foot { padding: 22px 16px 32px; }
}

/* short pages: page not found, something went wrong */
.er { min-height: 100vh; display: flex; flex-direction: column; }
.er-main { flex: 1; display: flex; align-items: center; justify-content: center; padding: 24px 16px 60px; text-align: center; }
.er-main > div { max-width: 460px; }
.er-code { font: 600 12px ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .22em; color: var(--accent); margin: 0 0 6px; }
.er-main h1 { font: 400 clamp(40px, 7vw, 56px)/1.05 'Instrument Serif', Georgia, serif; color: var(--pg-bright); margin: 0 0 10px; }
.er-main div[lang="ar"] h1 { font: 600 30px/1.3 'Saudi', sans-serif; margin-top: 22px; }
.er-main p { margin: 0 0 6px; color: var(--pg-mut); }
.er-main div[lang="ar"] { padding-top: 18px; margin-top: 18px; border-top: 1px solid var(--pg-line); }
.er-go { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; margin-top: 28px; padding: 0 26px; border-radius: 999px; background: var(--pg-bright); color: var(--pg-bg) !important; font-weight: 600; text-decoration: none !important; white-space: nowrap; gap: .4em; }
.er-go:hover { background: var(--accent); }

@media print { body::before, .pg-top, .pg-toc, .pg-foot { display: none; } body { background: #fff; color: #000; } }

/* the language is chosen before the first paint (page-lang-early.js): only that language's text is drawn, and the few
   translated labels wait until page-lang.js has set them, so nothing shows in one language and then flips */
html.pg-js[lang="ar"] article[lang="en"], html.pg-js[lang="en"] article[lang="ar"] { display: none; }
html.pg-js[lang="ar"] article[lang="ar"][hidden] { display: block; }
html.pg-js:not(.pg-ready) [data-ar] { visibility: hidden; }
