/* ==========================================================================
   Dhakker — Public information pages (contact, terms, privacy)

   Scope: shared page chrome for the three static public pages that are not the
   landing page — header, language toggle, long-form prose, contact cards,
   footer. It replaced three near-identical inline <style> blocks that still
   carried the removed 2025 style guide (Playfair Display / DM Sans and the
   legacy #1a472a / #c9a84c palette).

   Every value below maps to a token in brand/tokens/dhakker.tokens.json
   (mirrored in brand/tokens/css/dhakker.css as --dk-*). The local :root aliases
   mirror public/css/landing.css so the public site reads as one surface.
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* Qomra — Arabic display only (headings/signage), single heavy weight.
   Pair with font-synthesis: none so it is never faux-bolded. */
@font-face {
  font-family: 'Qomra';
  src: url('/fonts/qomra.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* 2026 brand palette — source of truth: brand/tokens/dhakker.tokens.json */
:root {
  /* Latin: Sora everywhere. Arabic ([dir="rtl"] flips this): IBM Plex Sans
     Arabic for body/UI, Qomra for headings only (see RTL section). */
  --font-sans: 'Sora', -apple-system, sans-serif;
  --green: #0b2d26;          /* --dk-deep-green */
  --green-light: #2f5a4e;    /* --dk-soft-green */
  --green-dark: #081f1a;     /* --dk-primary-pressed */
  --gold: #c89a4b;           /* --dk-gold */
  --gold-light: #d4ac63;     /* --dk-gold-hover */
  --cream: #f4f1ea;          /* --dk-warm-ivory */
  --cream-dark: #e5e7e6;     /* --dk-light-gray */
  --white: #ffffff;          /* --dk-white */
  --text: #121a18;           /* --dk-charcoal */
  --text-muted: #333f3c;     /* --dk-dark-gray */
  --text-light: #6b7672;     /* --dk-gray */
  --radius: 12px;            /* --dk-radius-lg */
  --radius-lg: 20px;         /* --dk-radius-2xl */
  --shadow-sm: 0 2px 8px rgba(11,45,38,0.06);
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--cream);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

[dir="rtl"] { direction: rtl; text-align: right; }

a { text-decoration: none; color: var(--green); transition: var(--transition); }
a:hover { color: var(--green-light); text-decoration: underline; }

img { max-width: 100%; display: block; }
ul { list-style: none; }

.container { max-width: 800px; margin: 0 auto; padding: 0 24px; }


/* ---------- Header ---------- */
.header {
  background: var(--white);
  border-bottom: 1px solid var(--cream-dark);
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.header-inner { display: flex; align-items: center; gap: 16px; }

/* Brand lockup, not a retypeset wordmark. White header surface → the Deep
   Green (primary) lockup; sized above the 120px lockup minimum. */
.logo { display: inline-block; }
.logo img { width: 148px; height: auto; }

.header-right { margin-inline-start: auto; display: flex; align-items: center; gap: 16px; }

.back-link { color: var(--text-muted); font-size: 0.875rem; font-weight: 500; }

.lang-toggle {
  display: flex;
  gap: 4px;
  background: var(--cream);
  border-radius: 8px;
  padding: 2px;
}

.lang-toggle button {
  border: none;
  background: transparent;
  padding: 6px 10px;
  border-radius: 6px;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  color: var(--text-muted);
  transition: var(--transition);
}

.lang-toggle button:hover { color: var(--green); }

.lang-toggle button.active {
  background: var(--white);
  color: var(--green);
  box-shadow: var(--shadow-sm);
}

.lang-toggle button:focus-visible,
.back-link:focus-visible,
.logo:focus-visible,
.content a:focus-visible,
.contact-link:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
  border-radius: 4px;
}


/* ---------- Page shell ---------- */
.main { padding: 56px 0 80px; }

/* Display 32/1.2/600 — the top of the screen type scale. */
.page-title {
  font-family: var(--font-sans);
  font-size: 2rem;
  line-height: 1.2;
  font-weight: 600;
  color: var(--green);
  letter-spacing: -0.01em;
  margin-bottom: 12px;
}

.page-subtitle {
  color: var(--text-muted);
  font-size: 1.125rem;
  line-height: 1.4;
  margin-bottom: 48px;
}

.last-updated { color: var(--text-light); font-size: 0.875rem; margin-bottom: 48px; }


/* ---------- Long-form prose (terms, privacy) ---------- */
/* H2 24/1.3/600, H3 20/1.35/500, body 16/1.6/400 — per the brand type scale. */
.content h2 {
  font-family: var(--font-sans);
  font-size: 1.5rem;
  line-height: 1.3;
  font-weight: 600;
  color: var(--green);
  margin-top: 48px;
  margin-bottom: 16px;
}

.content h3 {
  font-family: var(--font-sans);
  font-size: 1.25rem;
  line-height: 1.35;
  font-weight: 500;
  color: var(--green-light);
  margin-top: 32px;
  margin-bottom: 12px;
}

.content p { margin-bottom: 20px; color: var(--text); }
.content ul { list-style: disc; margin-inline-start: 24px; margin-bottom: 20px; }
.content li { margin-bottom: 8px; color: var(--text); }
.content strong { font-weight: 600; color: var(--green); }
.content a { text-decoration: underline; }

.contact-box {
  background: var(--white);
  border: 1px solid var(--cream-dark);
  border-inline-start: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 24px;
  margin-top: 48px;
  box-shadow: var(--shadow-sm);
}

.contact-box h3 { margin-top: 0; }


/* ---------- Contact cards ---------- */
.contact-cards { display: grid; gap: 24px; }

.contact-card {
  background: var(--white);
  border: 1px solid var(--cream-dark);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
}

.contact-card h2 {
  font-family: var(--font-sans);
  font-size: 1.25rem;
  line-height: 1.35;
  font-weight: 500;
  color: var(--green);
  margin-bottom: 8px;
}

.contact-card p { margin-bottom: 16px; color: var(--text-muted); }

.contact-card .contact-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  font-size: 1rem;
  color: var(--green);
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-underline-offset: 3px;
}

.contact-card .contact-link:hover { color: var(--green-light); }

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 16px;
}

/* 12px eyebrow label — the one place ALL-CAPS is allowed. */
.info-item h3 {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.125em;
  margin-bottom: 4px;
}

.info-item p { font-weight: 500; color: var(--text); margin-bottom: 0; }


/* ---------- Footer ---------- */
.footer {
  background: var(--green-dark);
  color: rgba(255,255,255,0.6);
  padding: 40px 0;
  text-align: center;
  font-size: 0.875rem;
}

/* Deep Green surface → reverse (white) lockup. */
.footer-brand-logo { display: inline-block; margin-bottom: 20px; }
.footer-brand-logo img { width: 148px; height: auto; margin: 0 auto; }

.footer a { color: var(--gold); }
.footer a:hover { color: var(--gold-light); }

.footer-links { margin-top: 12px; }
.footer-links a { margin: 0 8px; }


/* ---------- Language switching ---------- */
.lang-content { display: none; }
.lang-content.active { display: block; }
/* Inline language spans (header back-link, footer copyright) must not become
   block-level or they break the surrounding flex/inline flow. */
.back-link .lang-content.active,
.footer p .lang-content.active { display: inline; }


/* ---------- RTL (Arabic) ---------- */
/* Arabic uses exactly two fonts: IBM Plex Sans Arabic for body/UI and Qomra
   for headings/display only. */
[dir="rtl"] {
  --font-sans: 'IBM Plex Sans Arabic', 'Sora', -apple-system, sans-serif;
}

[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, [dir="rtl"] h4,
[dir="rtl"] .page-title {
  font-family: 'Qomra', 'IBM Plex Sans Arabic', sans-serif;
  font-synthesis: none;
}


/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .page-title { font-size: 1.75rem; }
  .content h2 { font-size: 1.375rem; }
  .main { padding: 40px 0 60px; }
  .contact-card { padding: 24px; }
  .header-inner { flex-wrap: wrap; gap: 12px; }
  .logo img, .footer-brand-logo img { width: 128px; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition-duration: 0.01ms !important; }
}
