/* ============================================================
   Wuthqa — English (LTR) layer
   Loaded AFTER colors_and_type.css + site.css + site-pages.css
   on /en pages only. Sets the Latin type system (Poppins headings
   + Source Serif 4 body) and flips direction-sensitive rules to LTR.
   ============================================================ */
/* ---- Type system ------------------------------------------------ */
/* Re-point the "primary" family token to Poppins so every inline
   var(--font-ar) (buttons, nav, kickers, chips, labels) renders Latin. */
:root { --font-ar: 'Poppins', ui-sans-serif, system-ui, sans-serif; }

body { font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif; line-height: 1.75; }

/* Headings, UI labels & numerals stay Poppins (geometric, brand) */
h1, h2, h3, h4, h5, h6,
.wq-hero-title, .wq-phero h1,
.wq-nav-link, .wq-nav-trigger, .wq-nav-lang,
.wq-kicker-label, .wq-kicker-idx,
.wq-btn, .wq-chip, .wq-filter-pill, .wq-nl-tag,
.wq-svc-num, .wq-res-year, .wq-step-num, .wq-prac-aside .num,
.wq-nav-dd-item .tx .t, .wq-footer-col h5, .wq-footer-logo span,
.wq-post-cat, .wq-res-type, .wq-branch .tag, .wq-partner-head .role,
.wq-nl-issue-n, .wq-nl-lbl, .wq-blog-count {
  font-family: 'Poppins', ui-sans-serif, sans-serif;
}

/* Slightly tighten serif prose for English measure */
.wq-prose p, .wq-lede, .wq-aside-row .d,
.wq-svc-card p, .wq-value p, .wq-prac-item .d, .wq-prac-aside p,
.wq-feat-body > p, .wq-post-body > p, .wq-res-main > p,
.wq-nl-benefit .d, .wq-nl-card-sub, .wq-contrib-item p,
.wq-step-body p, .wq-ach-item p, .wq-partner .tag, .wq-partner-bio p,
.wq-hero-lead, .wq-phero p, .wq-lab-head > p, .wq-contact-copy > p,
.wq-nl-strip-copy p, .wq-nl-lede { letter-spacing: 0; }

/* ---- LTR direction flips ---------------------------------------- */
/* Text that was right-aligned for RTL */
.wq-nav-mobile a { text-align: left; }
.wq-ach-tab { text-align: left; }
.wq-lic .n { direction: ltr; text-align: left; }
.wq-footer-contact .en { direction: ltr; text-align: left; }

/* Forward "read/next" arrows now point right; nudge them rightward */
.wq-btn:hover .wq-btn-arrow { transform: translateX(5px); }
.wq-feat:hover .wq-feat-rd,
.wq-post:hover .wq-post-foot .rd { gap: 11px; }
.wq-nl-issue:hover .wq-nl-issue-go { transform: translateX(5px); }

/* Knowledge nav dropdown anchors to the trigger's left edge in LTR */
.wq-nav-dropdown { right: auto; left: 0; }

/* Research card: divider rail moves to the right side */
.wq-res-aside { border-left: none; padding-left: 0; border-right: 1px solid var(--border-soft); padding-right: 28px; }
@media (max-width: 980px) {
  .wq-res-aside { border-right: none; padding-right: 0; }
}

/* Hero / band metric separators: keep them between cells in LTR */
.wq-hero-metric, .wq-band .wq-metric-cell { padding-right: 0; padding-left: 24px; border-right: none; border-left: 1px solid rgba(255,255,255,.14); }
.wq-band .wq-metric-cell { border-left-color: var(--border); }
.wq-hero-metric:first-child, .wq-band .wq-metric-cell:first-child { padding-left: 0; border-left: none; }
.wq-hero-metric:last-child { border-right: none; }
@media (max-width: 980px) {
  .wq-hero-metrics-inner .wq-hero-metric:nth-child(odd) { border-left: none; padding-left: 0; }
  .wq-band .wq-metric-cell:nth-child(odd) { border-left: none; padding-left: 0; }
}

/* Decorative spiral marks read better mirrored to the right in LTR */
.wq-hero-mark, .wq-lab-mark, .wq-phero-mark { left: auto; right: -90px; }
.wq-lab-mark { right: -140px; }
.wq-contact-mark { right: auto; left: -120px; }

/* Numerals/metrics: Poppins already; ensure crisp tabular feel */
.wq-metric-cell .font-en, .wq-hero-metric .font-en { font-feature-settings: "tnum" 1; }

/* ---- Platform / SaaS surfaces (LTR) ----------------------- */
.wq-auth-brand-mark { left: auto; right: -90px; }
.wq-promo-mark { right: auto; left: -120px; }
.wq-plan-name, .wq-plan-tagline, .wq-plan-note, .wq-bal .lb, .wq-bal .big,
.wq-topup .t, .wq-topup .p, .wq-pf-card h4, .wq-how-step h4, .wq-faq-item h4,
.wq-order-head .nm, .wq-pkg-active .nm { font-family: 'Poppins', ui-sans-serif, sans-serif; }
.wq-plan-includes .lb { letter-spacing: .04em; }
.wq-input.en { direction: ltr; }
/* keep numerals tabular */
.wq-plan-price .amt, .wq-bal .big, .wq-topup .p, .wq-order-total .amt { font-feature-settings: "tnum" 1; }

/* ---- Services mega-menu (top nav) ------------------------------- */
.wq-nav-hasmenu { position: relative; display: inline-flex; align-items: center; }
.wq-nav-hasmenu > .wq-nav-link { display: inline-flex; align-items: center; gap: 5px; cursor: pointer; }
/* Chevron always visible; rotates when the mega-menu is open. */
.wq-nav-hasmenu > .wq-nav-link svg, .wq-nav-hasmenu > .wq-nav-link [data-lucide] { transition: transform .2s ease; opacity: .85; }
.wq-nav-hasmenu.open > .wq-nav-link svg, .wq-nav-hasmenu.open > .wq-nav-link [data-lucide] { transform: rotate(180deg); }
.wq-mega { position: absolute; top: calc(100% + 16px); left: 50%; transform: translateX(-50%) translateY(8px);
  width: min(700px, 92vw); background: #14120d; border: 1px solid rgba(200, 168, 75, .22); border-radius: 16px;
  box-shadow: 0 30px 70px -24px rgba(0, 0, 0, .72); padding: 16px; opacity: 0; visibility: hidden;
  transition: opacity .2s ease, transform .2s ease; z-index: 120; }
.wq-nav-hasmenu.open .wq-mega { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.wq-mega::before { content: ''; position: absolute; top: -16px; left: 0; right: 0; height: 16px; } /* hover bridge over the gap */
.wq-mega-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; }
.wq-mega-item { display: flex; align-items: flex-start; gap: 12px; padding: 11px 13px; border-radius: 11px;
  text-decoration: none; transition: background .2s ease; }
.wq-mega-item:hover { background: rgba(200, 168, 75, .10); }
.wq-mega-ic { flex-shrink: 0; width: 38px; height: 38px; border-radius: 10px; display: inline-flex;
  align-items: center; justify-content: center; background: rgba(200, 168, 75, .14); color: var(--gold); }
.wq-mega-tx { display: flex; flex-direction: column; min-width: 0; }
.wq-mega-name { color: #fff; font-weight: 600; font-size: 14.5px; }
.wq-mega-tag { color: rgba(255, 255, 255, .52); font-size: 12px; line-height: 1.45; margin-top: 2px; }
.wq-mega-all { display: inline-flex; align-items: center; gap: 7px; margin: 6px 4px 0; padding: 9px 13px;
  color: var(--gold); font-weight: 600; font-size: 13.5px; text-decoration: none; border-top: 1px solid rgba(255, 255, 255, .08); width: calc(100% - 8px); }
.wq-mega-all:hover { color: #fff; }

/* Mobile services accordion */
.wq-mobile-svc { width: 100%; display: flex; align-items: center; justify-content: space-between;
  background: none; border: none; font: inherit; color: inherit; cursor: pointer; }
.wq-mobile-svc svg, .wq-mobile-svc [data-lucide] { transition: transform .2s ease; }
.wq-mobile-svc.open svg, .wq-mobile-svc.open [data-lucide] { transform: rotate(180deg); }
.wq-mobile-sub { display: flex; flex-direction: column; padding: 2px 0 8px 16px; }
.wq-mobile-sublink { padding: 9px 4px; color: rgba(255, 255, 255, .7); text-decoration: none; font-size: 15px; }
.wq-mobile-sublink.is-all { color: var(--gold); font-weight: 600; }

/* ============================================================
   Guided assistant - free bilingual browser chatbot
   ============================================================ */
.wq-chat { position: fixed; right: 24px; bottom: 24px; z-index: 90; font-family: var(--font-en);
  display: flex; flex-direction: column; align-items: flex-end; gap: 14px; }
.wq-chat.rtl { right: auto; left: 24px; align-items: flex-start; }

/* Floating action button */
.wq-chat-fab { position: relative; width: 60px; height: 60px; border-radius: var(--r-full); border: none; cursor: pointer;
  background: var(--gold); color: #17140f; display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 14px 30px -8px rgba(120, 96, 40, .55), 0 4px 10px -4px rgba(0, 0, 0, .3);
  transition: transform .25s var(--ease), background .25s var(--ease); }
.wq-chat-fab:hover { background: var(--gold-600); transform: translateY(-3px); }
.wq-chat-fab.open { background: #141210; }
.wq-chat-fab::after { content: ''; position: absolute; inset: 0; border-radius: var(--r-full);
  box-shadow: 0 0 0 0 rgba(165, 149, 107, .5); animation: wqChatPulse 2.6s var(--ease) infinite; pointer-events: none; }
.wq-chat-fab.open::after { animation: none; }
@keyframes wqChatPulse { 0% { box-shadow: 0 0 0 0 rgba(165, 149, 107, .45); } 70% { box-shadow: 0 0 0 16px rgba(165, 149, 107, 0); } 100% { box-shadow: 0 0 0 0 rgba(165, 149, 107, 0); } }
@media (prefers-reduced-motion: reduce) { .wq-chat-fab::after { animation: none; } .wq-chat-panel { animation: none; } }

/* Panel */
.wq-chat-panel { width: 390px; max-width: calc(100vw - 40px); height: 620px; max-height: calc(100dvh - 116px);
  background: #fff; border-radius: 20px; overflow: hidden; display: flex; flex-direction: column;
  box-shadow: 0 30px 60px -18px rgba(20, 16, 10, .5), 0 10px 24px -12px rgba(0, 0, 0, .3);
  animation: wqChatIn .28s var(--ease) both; }
@keyframes wqChatIn { from { opacity: 0; transform: translateY(14px) scale(.97); } to { opacity: 1; transform: none; } }

/* Header */
.wq-chat-head { flex: 0 0 auto; display: flex; align-items: center; gap: 12px; padding: 14px 14px 14px 18px;
  background: linear-gradient(115deg, #1c1813 0%, #141210 100%); color: #fff; }
.wq-chat.rtl .wq-chat-head { padding: 14px 18px 14px 14px; }
.wq-chat-avatar { flex: 0 0 40px; width: 40px; height: 40px; border-radius: var(--r-full); overflow: hidden;
  background: #fff; display: inline-flex; align-items: center; justify-content: center; }
.wq-chat-avatar img { width: 82%; height: 82%; object-fit: contain; }
.wq-chat-id { display: flex; flex-direction: column; min-width: 0; margin-inline-end: auto; }
.wq-chat-name { font-weight: 600; font-size: 15px; letter-spacing: .01em; }
.wq-chat-status { display: inline-flex; align-items: center; font-size: 12px; color: rgba(255, 255, 255, .68); margin-top: 2px; }
.wq-chat-hbtn { flex: 0 0 auto; width: 32px; height: 32px; border-radius: var(--r-full); border: none; cursor: pointer;
  background: rgba(255, 255, 255, .08); color: rgba(255, 255, 255, .85); display: inline-flex; align-items: center; justify-content: center;
  transition: background .2s var(--ease), color .2s var(--ease); }
.wq-chat-hbtn:hover { background: rgba(255, 255, 255, .16); color: #fff; }

/* Body */
.wq-chat-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: 18px 16px; background: #f6f4ef;
  display: flex; flex-direction: column; gap: 10px; }
.wq-chat-msg { max-width: 86%; font-size: 14px; line-height: 1.6; padding: 11px 14px; }
.wq-chat-msg.bot { align-self: flex-start; background: #fff; color: var(--teal-900); border: 1px solid var(--border-soft);
  border-radius: 4px 16px 16px 16px; box-shadow: 0 6px 14px -10px rgba(20, 16, 10, .3); }
.wq-chat.rtl .wq-chat-msg.bot { border-radius: 16px 4px 16px 16px; }
.wq-chat-msg.user { align-self: flex-end; background: var(--gold); color: #17140f; border-radius: 16px 16px 4px 16px; font-weight: 600; }
.wq-chat.rtl .wq-chat-msg.user { border-radius: 16px 16px 16px 4px; }
.wq-chat-actions { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 10px; }
.wq-chat-actions a { display: inline-flex; align-items: center; gap: 5px; min-height: 34px; padding: 7px 10px;
  color: #6f5924; background: rgba(200, 168, 75, .13); border: 1px solid rgba(171, 140, 57, .35);
  border-radius: 9px; text-decoration: none; font-size: 12px; font-weight: 650; line-height: 1.3;
  transition: background .2s var(--ease), border-color .2s var(--ease), transform .2s var(--ease); }
.wq-chat-actions a:hover { background: rgba(200, 168, 75, .22); border-color: var(--gold-600); transform: translateY(-1px); }
.wq-chat-actions a:active { transform: translateY(0) scale(.98); }
.wq-chat-note { display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; margin: 2px 0;
  background: var(--gold-tint); border: 1px solid rgba(165, 149, 107, .28); border-radius: 12px;
  color: var(--fg-3); font-size: 12px; line-height: 1.55; }
.wq-chat-note [data-lucide], .wq-chat-note svg { color: var(--gold); flex-shrink: 0; margin-top: 1px; }

/* Quick-reply options */
.wq-chat-opts { display: flex; flex-direction: column; gap: 8px; margin-top: 6px; }
.wq-chat-opt { display: inline-flex; align-items: center; gap: 10px; width: 100%; text-align: start; cursor: pointer;
  padding: 11px 14px; border-radius: 12px; background: #fff; border: 1px solid var(--border);
  font-family: var(--font-en); font-weight: 500; font-size: 13.5px; color: var(--teal-900);
  transition: border-color .2s var(--ease), background .2s var(--ease), transform .2s var(--ease); }
.wq-chat-opt [data-lucide], .wq-chat-opt svg { color: var(--gold); flex-shrink: 0; }
.wq-chat-opt:hover { border-color: var(--gold); background: var(--gold-tint); transform: translateX(2px); }
.wq-chat.rtl .wq-chat-opt:hover { transform: translateX(-2px); }
.wq-chat-opt.ghost { background: transparent; border-color: transparent; color: var(--fg-3); font-weight: 600; padding: 8px 14px; }
.wq-chat-opt.ghost [data-lucide], .wq-chat-opt.ghost svg { color: var(--fg-3); }

/* Suggested starter questions — routed through the assistant, shown only at the greeting */
.wq-chat-sugg { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 10px; }
.wq-chat-sugg-lbl { width: 100%; font-family: var(--font-en); font-size: 11px; font-weight: 600; letter-spacing: .04em;
  text-transform: uppercase; color: var(--fg-3); margin-bottom: 1px; }
.wq-chat-suggchip { cursor: pointer; padding: 7px 12px; border-radius: 999px; background: var(--surface);
  border: 1px solid var(--border); font-family: var(--font-en); font-weight: 500; font-size: 12.5px;
  color: var(--teal-900); transition: border-color .2s var(--ease), background .2s var(--ease); }
.wq-chat-suggchip:hover { border-color: var(--gold); background: var(--gold-tint); }
.wq-chat-opt.ghost:hover { background: var(--border-soft); border-color: transparent; color: var(--teal); transform: none; }

/* Typed question flow */
.wq-chat-typing { display: inline-flex; align-items: center; gap: 5px; min-width: 58px; min-height: 40px; }
.wq-chat-typing > span { width: 6px; height: 6px; border-radius: var(--r-full); background: var(--gold-600); opacity: .34;
  animation: wqChatTyping 1s ease-in-out infinite; }
.wq-chat-typing > span:nth-child(2) { animation-delay: .12s; }
.wq-chat-typing > span:nth-child(3) { animation-delay: .24s; }
@keyframes wqChatTyping { 0%, 70%, 100% { opacity: .3; transform: translateY(0); } 35% { opacity: 1; transform: translateY(-2px); } }

.wq-chat-compose { flex: 0 0 auto; display: grid; grid-template-columns: minmax(0, 1fr) 42px; gap: 8px;
  padding: 11px 12px; background: #fff; border-top: 1px solid var(--border-soft); }
.wq-chat-compose input { min-width: 0; height: 42px; padding: 0 13px; border: 1px solid #cfc9bd; border-radius: 10px;
  background: #fbfaf7; color: #211e19; font: 500 13px/1.3 var(--font-en); outline: none;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), background .2s var(--ease); }
.wq-chat.rtl .wq-chat-compose input { font-family: var(--font-ar); }
.wq-chat-compose input::placeholder { color: #777167; opacity: 1; }
.wq-chat-compose input:focus { border-color: var(--gold-600); background: #fff; box-shadow: 0 0 0 3px rgba(200, 168, 75, .18); }
.wq-chat-compose input:disabled { opacity: .68; cursor: wait; }
.wq-chat-compose button { width: 42px; height: 42px; border: none; border-radius: 10px; background: var(--gold); color: #17140f;
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
  transition: background .2s var(--ease), transform .2s var(--ease), opacity .2s var(--ease); }
.wq-chat-compose button:hover:not(:disabled) { background: #d7b85d; transform: translateY(-1px); }
.wq-chat-compose button:active:not(:disabled) { transform: translateY(0) scale(.98); }
.wq-chat-compose button:disabled { opacity: .42; cursor: not-allowed; }

.wq-chat button:focus-visible, .wq-chat a:focus-visible, .wq-chat input:focus-visible {
  outline: 3px solid rgba(200, 168, 75, .48); outline-offset: 2px; }

/* Footer */
.wq-chat-foot { flex: 0 0 auto; text-align: center; padding: 9px; font-size: 11px; letter-spacing: .04em;
  color: var(--fg-3); background: #fff; border-top: 1px solid var(--border-soft); }

@media (max-width: 560px) {
  .wq-chat { right: 16px; bottom: 16px; }
  .wq-chat.rtl { left: 16px; right: auto; }
  .wq-chat-panel { width: calc(100vw - 32px); max-width: none; height: min(620px, calc(100dvh - 104px)); max-height: none; }
  .wq-chat-fab { width: 56px; height: 56px; }
  .wq-chat-msg { max-width: 90%; }
}

@media (prefers-reduced-motion: reduce) {
  .wq-chat-typing > span { animation: none; opacity: .65; transform: none; }
  .wq-chat-fab, .wq-chat-opt, .wq-chat-actions a, .wq-chat-compose button { transition: none; }
}

/* ---- SectionGate "Coming soon" placeholder ---------------------- */
.wq-soon { padding: 84px 0; background: var(--surface, #f6f4ef); }
.wq-soon-inner { max-width: var(--container, 1200px); margin: 0 auto; padding: 44px 32px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  gap: 12px; border: 1px dashed var(--border, #e3ded3); border-radius: var(--r-xl, 20px);
  background: repeating-linear-gradient(135deg, transparent, transparent 12px,
    rgba(200, 168, 75, .045) 12px, rgba(200, 168, 75, .045) 24px); }
.wq-soon-ic { display: inline-flex; align-items: center; justify-content: center; width: 54px; height: 54px;
  border-radius: 50%; background: var(--gold-tint, rgba(200, 168, 75, .12)); color: var(--gold, #c8a84b); }
.wq-soon-t { font-family: 'Source Serif 4', Georgia, serif; font-weight: 600; font-size: clamp(19px, 2.2vw, 23px);
  color: var(--teal, #123); margin: 0; }
.wq-soon-s { font-family: var(--font-en, system-ui); font-size: 13px; font-weight: 600; letter-spacing: .04em;
  text-transform: uppercase; color: var(--fg-3, #8a8578); margin: 0; }
