/* ==========================================================================
   AC-PAGES — Shared page-level design system for Arabic Consultant subpages.
   --------------------------------------------------------------------------
   Purpose: internal pages (about, contact, faq, case-studies, careers,
   how-we-work, …) each carried their own byte-identical 2.5 KB inline
   <style> block for the dark page chrome (hero, cards, grids, icons).
   Any palette or spacing change had to be repeated on every page, and they
   were already drifting from ac-master-theme.css. This file is that block,
   de-duplicated, plus the reusable components the pages keep re-inventing.

   Cascade: load AFTER ac-master-theme.css (it restates the dark base on
   purpose) and BEFORE ac-accessibility.css, which must keep the final word
   on contrast.

   Language: Arabic-first. Directional properties use logical CSS so the
   layout stays correct if a page ever flips to LTR.
   ========================================================================== */

/* Tokens.
   ac-master-theme.css already owns the palette (--ac-bg-dark, --ac-primary,
   --ac-cyan, --ac-text-*, --ac-border, --ac-radius-sm/md/lg/full,
   --ac-transition, --ac-font). This sheet loads after it, so re-declaring one
   of those names would silently win and re-style master-theme components on
   only these pages — the exact drift this refactor exists to remove. Only the
   names the master theme does not define are declared here. */
:root {
  --ac-cyan-soft: rgba(0, 210, 255, 0.12);
  --ac-cyan-border: rgba(0, 210, 255, 0.3);
  /* Badge outlines sat a touch stronger than the card/icon hairlines. */
  --ac-cyan-border-strong: rgba(0, 210, 255, 0.35);
  --ac-text-body: rgba(255, 255, 255, 0.7);
  --ac-shadow: 0 12px 36px rgba(0, 0, 0, 0.4);
  --ac-shadow-hover: 0 20px 48px rgba(0, 100, 255, 0.15);
  --ac-max-width: 1240px;
}

/* --------------------------------------------------------------------------
   1. Dark base — this is what the six inline blocks declared verbatim.
   -------------------------------------------------------------------------- */
html,
body,
.body-25 {
  /* Literals, not tokens: these blocks rendered exactly this way before the
     move, and the master theme's equivalents differ (its --ac-font adds system
     fallbacks, its text alpha is 0.85 not 0.75). Keeping the literals is what
     makes removing the inline blocks invisible. */
  background-color: #080c14 !important;
  color: #ffffff !important;
  direction: rtl !important;
  text-align: right !important;
  font-family: 'Tajawal', 'IBM Plex Sans Arabic', sans-serif !important;
  overflow-x: clip !important;
}

/* --------------------------------------------------------------------------
   2. Hero
   -------------------------------------------------------------------------- */
.page-hero-dark {
  padding: 90px 24px 60px;
  text-align: center;
  background: radial-gradient(circle at 50% 0%, rgba(0, 100, 255, 0.18) 0%, rgba(8, 12, 20, 0) 70%);
}

.page-hero-dark h1 {
  font-size: clamp(30px, 5vw, 48px);
  font-weight: 900;
  color: var(--ac-text-primary);
  margin-bottom: 16px;
  line-height: 1.3;
}

.page-hero-dark p {
  font-size: 17px;
  color: rgba(255, 255, 255, 0.75);
  max-width: 720px;
  margin: 0 auto 30px;
  line-height: 1.8;
}

.badge-tag-dark {
  display: inline-block;
  padding: 6px 18px;
  background: rgba(0, 100, 255, 0.15);
  border: 1px solid var(--ac-cyan-border-strong);
  border-radius: 50px;
  color: var(--ac-cyan);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 18px;
}

/* --------------------------------------------------------------------------
   3. Content shell + cards + grids
   -------------------------------------------------------------------------- */
.content-section-dark {
  max-width: var(--ac-max-width);
  margin: 0 auto;
  padding: 0 24px 80px;
}

.dark-grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
}

.dark-grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 32px;
}

.dark-card {
  background: linear-gradient(145deg, #0e1526 0%, #090d16 100%);
  border: 1px solid var(--ac-border);
  border-radius: 18px;
  padding: 32px;
  box-shadow: var(--ac-shadow);
  transition: all 0.3s ease;
}

.dark-card:hover {
  border-color: rgba(0, 100, 255, 0.45);
  transform: translateY(-4px);
  box-shadow: var(--ac-shadow-hover);
}

.dark-card h3 {
  font-size: 20px;
  font-weight: 800;
  color: var(--ac-text-primary);
  margin-bottom: 12px;
}

.dark-card p {
  font-size: 15px;
  line-height: 1.75;
  color: var(--ac-text-body);
}

.card-icon-cyan {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--ac-cyan-soft);
  border: 1px solid var(--ac-cyan-border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ac-cyan);
  margin-bottom: 20px;
  font-size: 22px;
}


/* --------------------------------------------------------------------------
   4. Buttons — the pages previously hard-coded these per link.
   -------------------------------------------------------------------------- */
.ac-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 30px;
  border: 1px solid transparent;
  border-radius: var(--ac-radius-full);
  font-family: var(--ac-font);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--ac-transition);
}

.ac-btn--primary {
  background: linear-gradient(135deg, #0064ff 0%, #004ecc 100%);
  color: #fff;
  box-shadow: 0 10px 28px var(--ac-primary-glow);
}

.ac-btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 38px var(--ac-primary-glow);
  color: #fff;
}

.ac-btn--ghost {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--ac-border);
  color: var(--ac-text-primary);
}

.ac-btn--ghost:hover {
  border-color: var(--ac-border-hover);
  background: rgba(0, 100, 255, 0.1);
  color: var(--ac-text-primary);
}

.ac-btn--whatsapp {
  background: var(--ac-whatsapp);
  color: #04310f;
  box-shadow: 0 10px 28px rgba(37, 211, 102, 0.45);
}

.ac-btn--whatsapp:hover {
  transform: translateY(-2px);
  color: #04310f;
}

/* --------------------------------------------------------------------------
   5. Call to action band
   -------------------------------------------------------------------------- */
.ac-cta {
  max-width: var(--ac-max-width);
  margin: 0 auto 80px;
  padding: 52px 24px;
  text-align: center;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-lg);
  background: radial-gradient(circle at 50% 0%, rgba(0, 100, 255, 0.22) 0%, rgba(8, 12, 20, 0) 72%);
}

.ac-cta h2 {
  font-size: clamp(24px, 3.4vw, 34px);
  font-weight: 900;
  color: var(--ac-text-primary);
  margin-bottom: 12px;
}

.ac-cta p {
  font-size: 16px;
  color: var(--ac-text-secondary);
  max-width: 620px;
  margin: 0 auto 28px;
  line-height: 1.8;
}

.ac-cta .ac-btn {
  margin: 0 8px 10px;
}


/* --------------------------------------------------------------------------
   6. Contact form — WhatsApp-first: the page never posts to a backend that
   does not exist, it validates and opens a pre-filled WhatsApp chat.
   -------------------------------------------------------------------------- */
.ac-form-card {
  max-width: 720px;
  margin: 0 auto;
  padding: 36px;
  background: linear-gradient(145deg, #0e1526 0%, #090d16 100%);
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-lg);
  box-shadow: var(--ac-shadow);
}

.ac-form-card label {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 700;
  color: var(--ac-text-secondary);
  text-align: start;
}

.ac-input {
  width: 100%;
  padding: 13px 16px;
  margin-bottom: 20px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-md);
  color: var(--ac-text-primary);
  font-family: var(--ac-font);
  font-size: 15px;
  transition: border-color var(--ac-transition), background var(--ac-transition);
}

.ac-input::placeholder {
  color: var(--ac-text-muted);
}

.ac-input:focus {
  outline: none;
  border-color: var(--ac-primary);
  background: rgba(0, 100, 255, 0.06);
}

.ac-input--invalid {
  border-color: #ff6b6b;
}

.ac-form-error {
  display: block;
  margin: -14px 0 16px;
  font-size: 13px;
  color: #ff8f8f;
}

.ac-form-success {
  padding: 14px 18px;
  margin-bottom: 20px;
  border: 1px solid rgba(37, 211, 102, 0.4);
  border-radius: var(--ac-radius-md);
  background: rgba(37, 211, 102, 0.1);
  color: #9df3be;
  font-size: 15px;
}

.ac-form-note {
  margin: 14px 0 0;
  font-size: 13px;
  color: var(--ac-text-muted);
  line-height: 1.7;
}

/* --------------------------------------------------------------------------
   7. Lists + RTL helpers
   -------------------------------------------------------------------------- */
.ac-card-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.ac-card-list li {
  position: relative;
  padding-inline-start: 28px;
  margin-bottom: 10px;
  font-size: 15px;
  line-height: 1.8;
  color: var(--ac-text-body);
}

.ac-card-list li::before {
  content: '';
  position: absolute;
  inset-inline-start: 6px;
  inset-block-start: 10px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ac-cyan);
}

/* --------------------------------------------------------------------------
   8. Motion preferences + small screens
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .ac-btn,
  .dark-card,
  .ac-skip-link {
    transition: none;
  }

  .dark-card:hover,
  .ac-btn--primary:hover,
  .ac-btn--whatsapp:hover {
    transform: none;
  }
}

@media (max-width: 600px) {
  .page-hero-dark {
    padding: 64px 20px 44px;
  }

  .content-section-dark {
    padding: 0 20px 60px;
  }

  .dark-card,
  .ac-form-card {
    padding: 24px;
  }

  .ac-cta {
    padding: 40px 20px;
    margin-inline: 20px;
    margin-block-end: 60px;
  }
}

