/* OPENCHATBOT — Modernist design system + site styles.
   Vanilla CSS, no build step. Logical properties (inset-inline-*, etc.)
   are used wherever possible so RTL (Arabic, default) and LTR (English)
   mirror automatically from the <html dir> attribute alone. */

@import url('https://fonts.googleapis.com/css2?family=Archivo:wght@400;500;600;700;800&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Noto+Kufi+Arabic:wght@400;500;700;800&display=swap');

:root {
  --color-bg: #f3f2f2;
  --color-surface: #eae9e9;
  --color-text: #201e1d;
  --color-accent: #ec3013;
  --color-accent-600: #dd2b0f;
  --color-accent-700: #ae1800;
  --color-accent-800: #7c1405;
  --color-accent-100: #fff2ef;
  --color-divider: rgba(32, 30, 29, 0.4);

  --color-neutral-100: #f8f4f4;
  --color-neutral-200: #eae7e7;
  --color-neutral-300: #d7d3d3;
  --color-neutral-400: #bab6b6;
  --color-neutral-500: #9b9797;
  --color-neutral-600: #7d7979;
  --color-neutral-700: #605d5d;
  --color-neutral-800: #444141;
  --color-neutral-900: #2d2b2b;

  --font-heading: "Archivo", system-ui, sans-serif;
  --font-body: "Archivo", system-ui, sans-serif;

  --shadow-md: 0 3px 10px rgba(45, 43, 43, 0.16);
  --shadow-lg: 0 12px 32px rgba(45, 43, 43, 0.22);
}

[data-theme="dark"] {
  --color-bg: #2d2b2b;
  --color-text: #f8f4f4;
  --color-divider: #605d5d;
  --color-neutral-100: #444141;
  --color-neutral-200: #605d5d;
  --color-neutral-600: #d7d3d3;
  --color-neutral-700: #d7d3d3;
  --color-neutral-800: #eae7e7;
}

* , *::before, *::after { box-sizing: border-box; }
html { color-scheme: light; }
html[data-theme="dark"] { color-scheme: dark; }
body {
  margin: 0; background: var(--color-bg); color: var(--color-text);
  font-family: var(--font-body); font-size: 15px; line-height: 1.55;
  transition: background 0.3s ease, color 0.3s ease;
}
html[lang="ar"] body { font-family: 'Noto Kufi Arabic', var(--font-heading), sans-serif; }
h1, h2, h3, h4 {
  font-family: var(--font-heading); font-weight: 800; line-height: 1.1;
  letter-spacing: -0.02em; margin: 0;
}
p { margin: 0; }
a { color: var(--color-accent-700); text-decoration: none; }
a:hover { color: var(--color-accent); }
img { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }

.wrap { max-width: 1120px; margin: 0 auto; padding-inline: 32px; }
.hr { height: 2px; border: 0; background: var(--color-divider); margin: 0; }

/* — buttons — */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  cursor: pointer; text-decoration: none; border: none;
  font-family: var(--font-heading); font-weight: 800; font-size: 14px;
  color: var(--color-text); background: transparent; border: 1px solid transparent;
  padding: 12px 20px; border-radius: 0;
}
.btn-primary { background: var(--color-accent); color: #fff; }
.btn-primary:hover { background: var(--color-accent-600); color: #fff; }
.btn-secondary { border-color: var(--color-divider); color: var(--color-text); }
.btn-secondary:hover { background: rgba(32,30,29,0.07); color: var(--color-text); }
.btn-ghost { color: var(--color-accent); border: none; background: none; padding: 8px 10px; }
.btn-ghost:hover { background: rgba(236,48,19,0.1); }
.btn-block { width: 100%; justify-content: space-between; font-size: 16px; padding: 16px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.cta-arrow { display: inline-block; animation: arrowNudgeLtr 1.4s ease-in-out infinite; }
[dir="rtl"] .cta-arrow { animation-name: arrowNudgeRtl; }
@keyframes arrowNudgeLtr { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(6px); } }
@keyframes arrowNudgeRtl { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(-6px); } }

/* — tag — */
.tag { display: inline-flex; align-items: center; font-size: 11px; letter-spacing: 0.02em; padding: 3px 10px; background: var(--color-accent-100); color: var(--color-accent-800); }
[data-theme="dark"] .tag { background: var(--color-neutral-100); color: var(--color-accent); }

/* — nav — */
.nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 32px; border-bottom: 2px solid var(--color-divider);
}
.nav-brand { font-family: var(--font-heading); font-weight: 800; font-size: 22px; letter-spacing: -0.03em; color: var(--color-text); }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a { color: var(--color-text); font-weight: 500; font-size: 15px; }
.nav-links a:hover { color: var(--color-accent); }
.nav-sep { width: 2px; height: 20px; background: var(--color-divider); }

.dark-toggle {
  width: 44px; height: 24px; border-radius: 2px; border: 2px solid var(--color-divider);
  background: var(--color-neutral-200); position: relative; padding: 0; cursor: pointer;
  flex-shrink: 0; transition: background 0.2s ease;
}
[data-theme="dark"] .dark-toggle { background: var(--color-neutral-800); }
.dark-toggle .knob {
  position: absolute; top: 1px; inset-inline-start: 1px; width: 18px; height: 18px;
  border-radius: 50%; background: #ffb020; color: #201e1d;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-heading); font-weight: 800; font-size: 10px; line-height: 1;
  transition: inset-inline-start 0.2s ease, background 0.2s ease;
}
[data-theme="dark"] .dark-toggle .knob { inset-inline-start: 19px; background: #000; color: #f8f4f4; }

/* — scroll reveal — */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }
.lift { transition: transform 0.25s ease, box-shadow 0.25s ease; }
.lift:hover { transform: translateY(-4px); }

.kicker { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--color-accent-700); }
.kicker-dash { width: 32px; height: 2px; background: var(--color-accent); flex-shrink: 0; }

/* — hero — */
.hero { padding: 96px 32px 80px; display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center; }
.hero h1 { font-size: 60px; margin-bottom: 24px; text-wrap: pretty; }
.hero-sub { font-size: 19px; line-height: 1.65; color: var(--color-neutral-700); max-width: 520px; margin-bottom: 20px; }
.hero-growth { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 600; margin-bottom: 36px; }
.hero-growth .arrow-up { display: inline-block; color: var(--color-accent); font-size: 18px; animation: arrowUp 1.6s ease-in-out infinite; }
@keyframes arrowUp { 0% { transform: translateY(6px); opacity: 0.2; } 50% { transform: translateY(-2px); opacity: 1; } 100% { transform: translateY(6px); opacity: 0.2; } }
.hero-ctas { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; }

/* — chat widget mock — */
.chat-widget {
  border-radius: 16px; background: #f3f2f2; color: #201e1d; min-height: 520px;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 30px 60px -20px rgba(0,0,0,0.35);
}
.chat-head { background: #201e1d; color: #f8f4f4; padding: 16px 20px; display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; }
.chat-close { width: 26px; height: 26px; border-radius: 50%; border: 2px solid #7d7979; display: flex; align-items: center; justify-content: center; font-size: 12px; flex-shrink: 0; }
.chat-lang-pill { border: 2px solid #7d7979; border-radius: 999px; padding: 5px 14px; font-size: 12px; color: #f8f4f4; }
.chat-bot-name { font-family: var(--font-heading); font-weight: 700; font-size: 15px; }
.chat-status { font-size: 11px; color: #bab6b6; display: flex; align-items: center; gap: 5px; }
.chat-status .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--color-accent); }
.chat-body { flex: 1; padding: 20px; display: flex; flex-direction: column; gap: 12px; }
.chat-typing { align-self: flex-start; background: #e6e4e4; border: 2px solid #d7d3d3; padding: 14px 18px; display: flex; gap: 5px; animation: chatIn 0.3s ease both; }
[dir="rtl"] .chat-typing, [dir="rtl"] .chat-bubble { align-self: flex-end; }
.chat-typing span { width: 6px; height: 6px; border-radius: 50%; background: #8a8686; animation: dotBounce 1.1s ease infinite; }
.chat-typing span:nth-child(2) { animation-delay: 0.15s; }
.chat-typing span:nth-child(3) { animation-delay: 0.3s; }
.chat-bubble { align-self: flex-start; background: #e6e4e4; border: 2px solid #d7d3d3; color: #201e1d; padding: 12px 16px; max-width: 88%; font-size: 13.5px; line-height: 1.5; animation: chatIn 0.35s ease both; }
.chat-chips-label { font-size: 11px; color: #7d7979; margin-bottom: 2px; }
.chat-chip { border: 2px solid #d7d3d3; color: #201e1d; border-radius: 999px; padding: 9px 16px; font-size: 13px; animation: chatIn 0.3s ease both; align-self: flex-start; }
[dir="rtl"] .chat-chip { align-self: flex-end; }
@keyframes chatIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes dotBounce { 0%, 60%, 100% { transform: translateY(0); opacity: 0.4; } 30% { transform: translateY(-4px); opacity: 1; } }
.chat-foot { border-top: 2px solid #e0dede; padding: 14px 16px; flex-shrink: 0; }
.chat-input-row { display: flex; align-items: center; gap: 10px; }
.chat-fake-input { flex: 1; border: 2px solid #d7d3d3; border-radius: 999px; padding: 10px 16px; font-size: 13px; color: #8a8686; }
.chat-send { width: 38px; height: 38px; border-radius: 50%; background: var(--color-accent); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.chat-disclaimer { font-size: 10px; color: #8a8686; text-align: center; margin-top: 10px; }

/* — trust strip — */
.trust-strip { padding: 0 32px 56px; display: flex; align-items: center; gap: 32px; flex-wrap: wrap; color: var(--color-neutral-600); font-size: 13px; font-weight: 600; letter-spacing: 0.04em; }
.trust-tick { height: 16px; width: 2px; background: var(--color-divider); }

/* — how it works — */
.dot-grid { background-image: radial-gradient(circle, var(--color-neutral-400) 1px, transparent 1px); background-size: 28px 28px; padding: 88px 32px; }
.steps { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 24px; position: relative; }
.steps-line { position: absolute; top: 28px; inset-inline: 16.6%; height: 2px; background: var(--color-divider); z-index: 0; }
.steps-line-fill { height: 100%; width: 100%; background: var(--color-accent); transform-origin: left; animation: stepLine 1.4s ease-out both; }
[dir="rtl"] .steps-line-fill { transform-origin: right; }
@keyframes stepLine { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.step { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: flex-start; }
.step-num { width: 56px; height: 56px; border-radius: 50%; background: var(--color-accent); color: #fff; display: flex; align-items: center; justify-content: center; font-family: var(--font-heading); font-weight: 800; font-size: 20px; margin-bottom: 20px; box-shadow: var(--shadow-md); }
.step-title { font-family: var(--font-heading); font-weight: 700; font-size: 18px; margin-bottom: 6px; }
.step-sub { font-size: 14px; color: var(--color-neutral-700); }

/* — control room / dashboard — */
.dash-title { font-size: 38px; margin: 16px 0 48px; max-width: 600px; text-wrap: pretty; }
.dash-grid { border: 2px solid var(--color-divider); box-shadow: var(--shadow-lg); padding: 32px; display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 2px; background: var(--color-divider); }
.dash-cell { background: var(--color-bg); padding: 24px; }
.dash-cell.full { grid-column: 1 / -1; }
.dash-label { font-size: 13px; color: var(--color-neutral-700); margin-bottom: 12px; }
.dash-value { font-family: var(--font-heading); font-weight: 800; font-size: 38px; }
.dash-value.accent { color: var(--color-accent-700); }
.compare-title { font-size: 13px; color: var(--color-neutral-700); margin-bottom: 16px; }
.compare-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.compare-label { font-size: 12px; font-weight: 700; color: var(--color-neutral-600); margin-bottom: 10px; }
.compare-label.accent { color: var(--color-accent-700); }
.bar-track { height: 8px; border-radius: 999px; background: var(--color-neutral-200); overflow: hidden; margin-bottom: 8px; }
.bar-fill { height: 100%; width: 0%; background: var(--color-neutral-500); animation: barFill 1.6s ease-out both; }
.bar-fill.accent { background: var(--color-accent); }
@keyframes barFill { from { width: 0%; } }
.compare-value { font-family: var(--font-heading); font-weight: 800; font-size: 22px; }
.compare-value.accent { color: var(--color-accent-700); }

/* — footer — */
.site-footer { border-top: 2px solid var(--color-divider); padding: 28px 32px; display: flex; justify-content: space-between; max-width: 1120px; margin: 0 auto; font-size: 14px; color: var(--color-neutral-600); }

/* — about page — */
.about-intro { padding: 80px 32px; display: grid; grid-template-columns: 0.5fr 1fr; gap: 48px; }
.about-intro h1 { font-size: 42px; }
.about-body-lead { font-size: 19px; line-height: 1.7; color: var(--color-neutral-800); max-width: 640px; text-wrap: pretty; }
.about-sales { padding: 80px 32px; }
.about-sales-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.about-sales-head .arrow-up { color: var(--color-accent); font-size: 30px; line-height: 1; animation: arrowUp 1.6s ease-in-out infinite; }
.about-sales h2 { font-size: 34px; }
.about-sales-body { font-size: 18px; line-height: 1.7; color: var(--color-neutral-800); margin: 0 0 48px; max-width: 720px; }
.figures { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); border-top: 2px solid var(--color-divider); }
.figure { padding: 32px 24px 32px 0; border-bottom: 2px solid var(--color-divider); }
[dir="rtl"] .figure { padding: 32px 0 32px 24px; }
.figure .arrow-up { display: block; color: var(--color-accent); font-size: 22px; line-height: 1; margin-bottom: 10px; animation: arrowUp 1.8s ease-in-out infinite; }
.figure-num { font-family: var(--font-heading); font-weight: 800; font-size: 40px; letter-spacing: -0.02em; }
.figure-label { font-size: 14px; color: var(--color-neutral-700); margin-top: 8px; line-height: 1.5; }

/* — pricing page — */
.pricing-section { padding: 80px 32px; }
.pricing-section h1 { font-size: 42px; margin-bottom: 12px; }
.pricing-sub { font-size: 18px; color: var(--color-neutral-700); margin-bottom: 48px; max-width: 560px; }
.plancard {
  max-width: 440px; margin: 0 auto; border: 2px solid var(--color-divider); background: var(--color-neutral-100);
  box-shadow: var(--shadow-lg); position: relative; overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.plancard:hover { transform: translateY(-6px); box-shadow: 0 24px 48px -16px rgba(236,48,19,0.28); }
.plancard-bar { height: 6px; background: var(--color-accent); }
.plancard-body { padding: 40px 36px 36px; }
.plancard-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.plancard-name { font-family: var(--font-heading); font-weight: 700; font-size: 22px; }
.plancard-price-row { display: flex; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.plancard-price { font-family: var(--font-heading); font-weight: 800; font-size: 56px; line-height: 1; color: var(--color-accent); }
.plancard-unit { font-size: 15px; color: var(--color-neutral-600); font-weight: 500; }
.plancard-usd-note { font-size: 13px; color: var(--color-neutral-600); margin-bottom: 24px; padding-bottom: 24px; border-bottom: 2px solid var(--color-divider); }
.plancard-features { display: flex; flex-direction: column; gap: 14px; margin: 0 0 32px; }
.plancard-feature { display: flex; align-items: center; gap: 12px; font-size: 15px; line-height: 1.5; }
.plancard-check { flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%; background: var(--color-accent); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }

/* — contact page — */
.contact-hero { background: var(--color-accent); padding: 120px 32px; }
.contact-hero .kicker { color: #fff; }
.contact-hero .kicker-dash { background: #fff; }
.contact-hero-inner { max-width: 960px; margin: 0 auto; }
.contact-hero h1 { font-size: 52px; color: #fff; margin-bottom: 20px; max-width: 760px; text-wrap: pretty; animation: fadeUpBig 0.8s ease both; }
.contact-sub { font-size: 19px; color: #fff; margin-bottom: 40px; max-width: 600px; line-height: 1.6; animation: fadeUpBig 0.8s ease both; animation-delay: 0.15s; }
.contact-cta {
  background: #fff; color: var(--color-accent-700); font-weight: 700; padding: 16px 28px;
  display: inline-flex; align-items: center; gap: 12px; font-size: 17px;
  transition: transform 0.2s ease; animation: fadeUpBig 0.8s ease both; animation-delay: 0.3s;
}
.contact-cta:hover { transform: translateY(-3px); color: var(--color-accent-700); }
.contact-note { margin-top: 20px; font-size: 14px; color: #fff; }
@keyframes fadeUpBig { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }

/* — payment page — */
.pay-section { max-width: 1000px; margin: 0 auto; padding: 64px 32px 96px; display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 48px; align-items: start; animation: fadeUpBig 0.6s ease both; }
.pay-section h1 { font-size: 36px; margin-bottom: 32px; }
.pay-field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 8px; }
.payinput { width: 100%; box-sizing: border-box; border: 2px solid var(--color-divider); background: var(--color-bg); color: var(--color-text); padding: 12px 14px; font-size: 15px; font-family: inherit; outline: none; transition: border-color 0.2s ease; }
.payinput:focus { border-color: var(--color-accent); }
.pay-widget-host { display: flex; flex-direction: column; gap: 12px; }
.pay-note { font-size: 12px; color: var(--color-neutral-600); text-align: center; display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 8px; }
.pay-status { border: 2px solid var(--color-divider); background: var(--color-neutral-100); padding: 24px; font-size: 14px; text-align: center; }
.pay-status.error { border-color: var(--color-accent); color: var(--color-accent-800); }
.pay-summary { border: 2px solid var(--color-divider); background: var(--color-neutral-100); padding: 28px 24px; }
.step-row { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.step-badge-sm { flex-shrink: 0; width: 28px; height: 28px; border-radius: 50%; background: var(--color-accent); color: #fff; display: flex; align-items: center; justify-content: center; font-family: var(--font-heading); font-weight: 800; font-size: 14px; }
.step-row h3 { font-size: 17px; margin: 0; }
.pay-summary-kicker { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--color-neutral-600); margin-bottom: 16px; }
.pay-summary-row { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: 16px; border-bottom: 2px solid var(--color-divider); margin-bottom: 16px; }
.pay-summary-plan { font-weight: 700; font-size: 16px; }
.pay-summary-price { font-family: var(--font-heading); font-weight: 800; font-size: 28px; color: var(--color-accent); }
.pay-summary-price small { font-size: 14px; color: var(--color-neutral-600); font-weight: 500; }
.pay-summary-features { display: flex; flex-direction: column; gap: 10px; font-size: 14px; color: var(--color-neutral-700); }
.pay-method-select { margin-bottom: 32px; }
.pay-method-label { font-size: 13px; font-weight: 700; margin-bottom: 14px; }
.pay-method-options { display: flex; gap: 16px; flex-wrap: wrap; }
.pay-method-card { flex: 1 1 200px; text-align: start; cursor: pointer; border: 2px solid var(--color-divider); background: var(--color-bg); color: var(--color-text); padding: 20px; font-family: inherit; transition: border-color 0.2s ease; }
.pay-method-card:hover { border-color: var(--color-accent); }
.pay-method-card-title { font-weight: 700; font-size: 16px; margin-bottom: 6px; }
.pay-method-card-sub { font-size: 12.5px; color: var(--color-neutral-600); }
.pay-method-back { display: inline-block; background: none; border: none; color: var(--color-accent-700); font-size: 13px; font-weight: 600; padding: 0; margin-bottom: 20px; cursor: pointer; font-family: inherit; }
.pay-method-back:hover { color: var(--color-accent); }

.pay-result { border: 2px solid var(--color-divider); background: var(--color-neutral-100); padding: 40px 32px; text-align: center; animation: fadeUpBig 0.6s ease both; }
.pay-result-icon { width: 56px; height: 56px; border-radius: 50%; background: var(--color-accent); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 26px; margin: 0 auto 20px; }
.pay-result.fail .pay-result-icon { background: var(--color-neutral-600); }
.pay-result-title { font-family: var(--font-heading); font-weight: 800; font-size: 22px; margin-bottom: 10px; }
.pay-result-sub { font-size: 15px; color: var(--color-neutral-700); margin-bottom: 24px; }

/* HyperPay widget re-skin to match the design system */
.wpwl-form { font-family: var(--font-body) !important; padding: 0 !important; border: none !important; box-shadow: none !important; }
.wpwl-label { font-size: 13px !important; font-weight: 600 !important; color: var(--color-text) !important; }
.wpwl-control { border: 2px solid var(--color-divider) !important; border-radius: 0 !important; background: var(--color-bg) !important; color: var(--color-text) !important; box-shadow: none !important; }
.wpwl-control:focus { border-color: var(--color-accent) !important; box-shadow: none !important; }
.wpwl-button-pay { background: var(--color-accent) !important; border-radius: 0 !important; font-family: var(--font-heading) !important; font-weight: 800 !important; text-transform: none !important; box-shadow: none !important; }
.wpwl-button-pay:hover { background: var(--color-accent-600) !important; }
.wpwl-wrapper-brand { filter: none !important; }

/* — responsive — */
@media (max-width: 860px) {
  .hero, .about-intro, .pay-section { grid-template-columns: 1fr; }
  .hero h1 { font-size: 40px; }
  .dash-grid, .compare-grid, .figures { grid-template-columns: 1fr; }
  .nav-links { gap: 14px; flex-wrap: wrap; }
  .contact-hero h1 { font-size: 34px; }
}
