/* Qisttah — tokens from the design system "قسطة" */
:root {
  --surface: #F7F1E6; --surface-raised: #FFFDF8; --sand: #EADFC9;
  --ink: #26331C; --ink-muted: #56614B;
  --olive: #4F6B3A; --on-olive: #FFFDF8; --leaf: #7E9F5A;
  --apricot: #E07A3F; --apricot-text: #A04A18; --wheat: #D9A94E;
  --danger: #A4271C; --focus: #26331C;
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-6: 24px;
  --space-8: 32px; --space-12: 48px; --space-16: 64px;
  --radius-sm: 8px; --radius-md: 14px; --radius-lg: 24px; --radius-pill: 999px;
  --font: "IBM Plex Sans Arabic", "Noto Sans Arabic", Tahoma, sans-serif;
  --wrap: 1120px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --surface: #1C2416; --surface-raised: #26301E; --sand: #34402A;
    --ink: #F3EDE1; --ink-muted: #C3BCAD; --olive: #9DBB78; --on-olive: #1C2416;
    --apricot: #EE9058; --apricot-text: #F2A675; --wheat: #E2B867;
    --danger: #F2A49C; --focus: #F3EDE1;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }
body { margin: 0; background: var(--surface); color: var(--ink); font-family: var(--font); font-size: 16px; line-height: 28px; }
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--olive); text-underline-offset: 4px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { margin: 0 0 var(--space-4); line-height: 1.35; text-wrap: balance; }
h1 { font-size: clamp(32px, 6vw, 48px); line-height: 1.3; font-weight: 700; }
h2 { font-size: clamp(24px, 4vw, 32px); font-weight: 700; }
h3 { font-size: 20px; font-weight: 600; }
p { margin: 0 0 var(--space-4); }
.lead { font-size: 18px; line-height: 32px; color: var(--ink-muted); max-width: 60ch; }
.muted { color: var(--ink-muted); }
.small { font-size: 14px; line-height: 24px; }
.wrap { width: min(100% - 2 * var(--space-4), var(--wrap)); margin-inline: auto; }
.skip { position: absolute; inset-inline-start: var(--space-4); top: -60px; background: var(--ink); color: var(--surface); padding: var(--space-2) var(--space-4); border-radius: var(--radius-sm); z-index: 10; }
.skip:focus { top: var(--space-4); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* header */
.site-header { border-bottom: 1px solid var(--sand); background: var(--surface); position: sticky; top: 0; z-index: 5; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); min-height: 72px; }
.brand { display: flex; align-items: center; gap: var(--space-3); text-decoration: none; color: var(--ink); }
.brand svg { width: 132px; }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: var(--space-6); }
.nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; }
.nav a[aria-current="page"] { color: var(--olive); text-decoration: underline; text-decoration-thickness: 2px; }
.menu-btn { display: none; }
@media (max-width: 760px) {
  .menu-btn { display: inline-flex; align-items: center; gap: var(--space-2); background: none; border: 1px solid var(--sand); border-radius: var(--radius-md); color: var(--ink); font: inherit; font-weight: 600; padding: var(--space-2) var(--space-3); cursor: pointer; min-height: 44px; }
  .nav { position: absolute; inset-inline: 0; top: 72px; background: var(--surface); border-bottom: 1px solid var(--sand); display: none; }
  .nav.open { display: block; }
  .nav ul { flex-direction: column; gap: 0; padding: var(--space-2) var(--space-4) var(--space-4); }
  .nav a { display: block; padding: var(--space-3) 0; }
  .header-cta { display: none; }
}

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2); min-height: 48px; padding: 0 var(--space-6); border-radius: var(--radius-md); font: inherit; font-weight: 700; text-decoration: none; border: 2px solid transparent; cursor: pointer; }
.btn-primary { background: var(--olive); color: var(--on-olive); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-sm { min-height: 44px; padding: 0 var(--space-4); font-size: 15px; }

/* sections */
section { padding-block: var(--space-12); }
@media (min-width: 900px) { section { padding-block: var(--space-16); } }
.alt { background: var(--sand); }
.eyebrow { display: inline-block; font-size: 14px; font-weight: 600; color: var(--apricot-text); margin-bottom: var(--space-2); }

.hero .wrap { display: grid; gap: var(--space-8); align-items: center; }
@media (min-width: 900px) { .hero .wrap { grid-template-columns: 1.2fr 1fr; } }
.hero-actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-6); }
.hero-art { justify-self: center; width: min(360px, 80vw); }
.badge { display: inline-flex; align-items: center; gap: var(--space-2); background: var(--surface-raised); border: 1px solid var(--sand); border-radius: var(--radius-pill); padding: var(--space-1) var(--space-3); font-size: 14px; font-weight: 600; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--apricot); }

.grid { display: grid; gap: var(--space-6); }
@media (min-width: 700px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.card { background: var(--surface-raised); border: 1px solid var(--sand); border-radius: var(--radius-lg); padding: var(--space-6); }
.card h3 { margin-bottom: var(--space-2); }
.card p:last-child { margin-bottom: 0; }
.status { display: inline-block; font-size: 13px; font-weight: 600; color: var(--ink-muted); border: 1px solid var(--sand); border-radius: var(--radius-pill); padding: 0 var(--space-3); margin-bottom: var(--space-3); }

/* plate explainer */
.plate { display: grid; gap: var(--space-8); align-items: center; }
@media (min-width: 900px) { .plate { grid-template-columns: 1fr 1.2fr; } }
.plate-legend { list-style: none; padding: 0; margin: 0 0 var(--space-4); display: grid; gap: var(--space-3); }
.plate-legend li { display: flex; gap: var(--space-3); align-items: flex-start; }
.swatch { flex: none; width: 20px; height: 20px; border-radius: 50%; margin-top: 4px; }
.sw-olive { background: var(--olive); } .sw-apricot { background: var(--apricot); } .sw-wheat { background: var(--wheat); }
.source { font-size: 14px; color: var(--ink-muted); }

/* steps */
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-6); }
@media (min-width: 800px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li { counter-increment: s; }
.steps li::before { content: counter(s, arabic-indic); display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--olive); color: var(--on-olive); font-weight: 700; margin-bottom: var(--space-3); }

/* about */
.facts { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-3); }
.facts li { padding-inline-start: var(--space-6); position: relative; }
.facts li::before { content: ""; position: absolute; inset-inline-start: 0; top: 10px; width: 10px; height: 10px; border-radius: 50%; background: var(--leaf); }

/* forms */
.form-card { background: var(--surface-raised); border: 1px solid var(--sand); border-radius: var(--radius-lg); padding: var(--space-6); max-width: 560px; }
.field { display: grid; gap: var(--space-2); margin-bottom: var(--space-4); }
.field label { font-weight: 600; font-size: 15px; }
.field .hint { font-size: 14px; line-height: 22px; color: var(--ink-muted); }
input[type="text"], input[type="email"], select, textarea { width: 100%; font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--ink-muted); border-radius: var(--radius-sm); padding: var(--space-3); min-height: 48px; }
textarea { min-height: 140px; resize: vertical; }
input[type="email"] { direction: ltr; text-align: right; }
.check { display: flex; gap: var(--space-3); align-items: flex-start; margin-bottom: var(--space-4); font-size: 15px; line-height: 26px; }
.check input { width: 22px; height: 22px; margin-top: 3px; flex: none; accent-color: var(--olive); }
.hp { display: none; }
.error { color: var(--danger); font-size: 14px; font-weight: 600; min-height: 1em; }

/* faq */
.faq details { border-bottom: 1px solid var(--sand); padding-block: var(--space-4); }
.faq summary { cursor: pointer; font-weight: 600; font-size: 17px; list-style: none; display: flex; justify-content: space-between; gap: var(--space-4); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 22px; color: var(--olive); }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: var(--space-3) 0 0; color: var(--ink-muted); }

/* prose pages */
.prose { max-width: 72ch; }
.prose h2 { margin-top: var(--space-8); font-size: 24px; }
.prose ul { padding-inline-start: var(--space-6); }
.prose li { margin-bottom: var(--space-2); }

/* footer */
.site-footer { border-top: 1px solid var(--sand); padding-block: var(--space-12) var(--space-8); }
.site-footer .cols { display: grid; gap: var(--space-8); }
@media (min-width: 800px) { .site-footer .cols { grid-template-columns: 1.4fr 1fr 1fr; } }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-2); }
.site-footer a { color: var(--ink); }
.disclaimer { margin-top: var(--space-8); padding: var(--space-4); border-radius: var(--radius-md); background: var(--sand); font-size: 14px; line-height: 24px; }
