/* =========================================================================
   BCM CRM — الصفحة التعريفية (Landing)
   -------------------------------------------------------------------------
   خفيفة: بلا صور خارجية ولا خطوط أيقونات، أيقونات SVG مضمَّنة، تخطيط RTL أولاً،
   ويعمل على كل الأحجام (موبايل أولاً). يدعم الوضع الليلي تلقائياً.
   ========================================================================= */
:root {
  --brand: #009444; --brand-600: #00803A; --ink: #10201A; --muted: #5B6B64; --line: #E3EAE6;
  --bg: #F6F9F7; --surface: #fff; --dark: #0C1F17; --radius: 16px; --wrap: 1140px;
}
@media (prefers-color-scheme: dark) {
  :root { --ink: #EAF3EE; --muted: #9DB2A8; --line: #1E3329; --bg: #0A1611; --surface: #0F2119; --dark: #06110C; }
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body.pcm-landing { margin: 0; background: var(--bg); color: var(--ink); font-family: Tajawal, 'IBM Plex Sans Arabic', system-ui, sans-serif; line-height: 1.75; -webkit-font-smoothing: antialiased; }
body.pcm-landing h1, body.pcm-landing h2, body.pcm-landing h3, body.pcm-landing h4 { line-height: 1.3; margin: 0; }
body.pcm-landing a { color: inherit; }
.ic { width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; vertical-align: -.22em; flex: none; }
.pcm-wrap { width: min(100% - 32px, var(--wrap)); margin-inline: auto; }
.pcm-narrow { width: min(100% - 32px, 820px); }
.pcm-skip { position: absolute; inset-inline-start: 8px; top: -60px; background: var(--brand); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 200; text-decoration: none; }
.pcm-skip:focus { top: 8px; }

/* أزرار */
.pcm-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 20px; border-radius: 12px; font: 700 15px Tajawal, sans-serif; text-decoration: none !important; border: 1.5px solid transparent; cursor: pointer; transition: transform .15s, box-shadow .15s, background .15s; }
.pcm-btn:hover { transform: translateY(-1px); }
.pcm-btn-primary { background: var(--brand); color: #fff !important; box-shadow: 0 10px 24px -10px var(--brand); }
.pcm-btn-primary:hover { background: var(--brand-600); }
.pcm-btn-ghost { background: transparent; border-color: var(--line); color: var(--ink) !important; }
.pcm-btn-ghost:hover { border-color: var(--brand); color: var(--brand) !important; }
.pcm-btn-lg { padding: 14px 28px; font-size: 16.5px; border-radius: 14px; }
.pcm-btn[disabled] { opacity: .6; cursor: progress; transform: none; }

/* الشريط العلوي */
.pcm-nav { position: sticky; top: 0; z-index: 100; background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid transparent; transition: border-color .2s, box-shadow .2s; }
.pcm-nav.scrolled { border-color: var(--line); box-shadow: 0 6px 24px -14px rgba(0, 0, 0, .25); }
.pcm-nav-in { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 64px; }
.pcm-brand { display: inline-flex; align-items: center; gap: 10px; font: 800 18px Tajawal, sans-serif; text-decoration: none; }
.pcm-menu { display: flex; align-items: center; gap: 4px; }
.pcm-menu > a:not(.pcm-btn) { padding: 8px 12px; border-radius: 10px; text-decoration: none; font-weight: 600; color: var(--muted); }
.pcm-menu > a:not(.pcm-btn):hover { color: var(--brand); background: color-mix(in srgb, var(--brand) 8%, transparent); }
.pcm-menu .pcm-btn { padding: 8px 16px; font-size: 14px; margin-inline-start: 6px; }
.pcm-nav-tog { display: none; width: 42px; height: 42px; border: 1px solid var(--line); background: var(--surface); border-radius: 12px; color: var(--ink); align-items: center; justify-content: center; cursor: pointer; }
.pcm-nav-tog .ic { width: 22px; height: 22px; }

/* الهيرو */
.pcm-hero-s { padding: clamp(36px, 7vw, 88px) 0 clamp(40px, 6vw, 72px); background:
  radial-gradient(1100px 500px at 85% -10%, color-mix(in srgb, var(--brand) 16%, transparent), transparent 60%),
  radial-gradient(700px 380px at 5% 110%, color-mix(in srgb, var(--brand) 10%, transparent), transparent 60%); }
.pcm-hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.pcm-pill { display: inline-block; padding: 6px 14px; border-radius: 999px; background: color-mix(in srgb, var(--brand) 12%, transparent); color: var(--brand); font: 700 13px Tajawal, sans-serif; margin-bottom: 18px; }
.pcm-hero-copy h1 { font-size: clamp(28px, 4.6vw, 52px); font-weight: 900; letter-spacing: -.01em; }
.pcm-hero-copy h1 em { font-style: normal; color: var(--brand); }
.pcm-lead { font-size: clamp(15px, 1.9vw, 19px); color: var(--muted); margin: 18px 0 26px; max-width: 58ch; }
.pcm-cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.pcm-checks { list-style: none; padding: 0; margin: 24px 0 0; display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--muted); font-weight: 600; font-size: 14px; }
.pcm-checks .ic { color: var(--brand); }

/* معاينة لوحة (CSS فقط) */
.pcm-mock { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .35); padding: 14px; transform: perspective(1200px) rotateY(-6deg) rotateX(2deg); }
[dir="rtl"] .pcm-mock { transform: perspective(1200px) rotateY(6deg) rotateX(2deg); }
.pcm-mock-bar { display: flex; gap: 6px; margin-bottom: 12px; }
.pcm-mock-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.pcm-mock-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 12px; }
.pcm-mock-kpi { background: color-mix(in srgb, var(--brand) 7%, var(--surface)); border-radius: 12px; padding: 10px 12px; }
.pcm-mock-kpi b { display: block; font: 800 20px Inter, sans-serif; color: var(--brand); }
.pcm-mock-kpi span { font-size: 11.5px; color: var(--muted); }
.pcm-mock-kanban { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.pcm-mock-kanban > div { background: var(--bg); border-radius: 10px; padding: 8px; min-height: 120px; }
.pcm-mock-kanban h6 { margin: 0 0 8px; font: 700 11px Tajawal, sans-serif; color: var(--muted); }
.pcm-mock-kanban p { height: 26px; margin: 0 0 6px; border-radius: 7px; background: var(--surface); border: 1px solid var(--line); }
.pcm-mock-kanban p.s { height: 18px; }
.pcm-mock-kanban p.ok { background: color-mix(in srgb, var(--brand) 20%, var(--surface)); border-color: var(--brand); }

/* الأقسام */
.pcm-sec { padding: clamp(44px, 7vw, 88px) 0; }
.pcm-alt { background: color-mix(in srgb, var(--brand) 4%, var(--bg)); }
.pcm-dark { background: var(--dark); color: #EAF3EE; }
.pcm-h2 { font-size: clamp(24px, 3.4vw, 38px); font-weight: 900; text-align: center; }
.pcm-sub { text-align: center; color: var(--muted); margin: 10px auto 34px; max-width: 60ch; }
.pcm-dark .pcm-sub { color: #9DB2A8; }
.pcm-grid { display: grid; gap: 18px; }
.pcm-grid-4 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.pcm-grid-3 { grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.pcm-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; transition: transform .2s, box-shadow .2s, border-color .2s; }
.pcm-card:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--brand) 50%, var(--line)); box-shadow: 0 18px 36px -22px rgba(0, 0, 0, .3); }
.pcm-card h3 { font-size: 17px; margin: 14px 0 6px; }
.pcm-card p { margin: 0; color: var(--muted); font-size: 14.5px; }
.pcm-ico { width: 46px; height: 46px; border-radius: 13px; display: inline-flex; align-items: center; justify-content: center; background: color-mix(in srgb, var(--brand) 12%, transparent); color: var(--brand); }
.pcm-ico .ic { width: 24px; height: 24px; }
.pcm-card-dark { background: #10281E; border-color: #1E3B2C; }
.pcm-card-dark p { color: #A9BEB3; }

.pcm-steps { list-style: none; padding: 0; margin: 34px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; counter-reset: s; }
.pcm-steps li { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.pcm-steps .n { display: inline-flex; width: 38px; height: 38px; border-radius: 12px; align-items: center; justify-content: center; background: var(--brand); color: #fff; font: 800 17px Inter, sans-serif; }
.pcm-steps h3 { font-size: 17px; margin: 12px 0 4px; }
.pcm-steps p { margin: 0; color: var(--muted); font-size: 14.5px; }

/* الأسعار */
.pcm-plans { align-items: stretch; }
.pcm-plan { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 26px 24px; display: flex; flex-direction: column; gap: 14px; }
.pcm-plan.pop { border: 2px solid var(--brand); box-shadow: 0 24px 48px -28px var(--brand); }
.pcm-badge { position: absolute; inset-block-start: -12px; inset-inline-start: 22px; background: var(--brand); color: #fff; font: 700 12px Tajawal, sans-serif; padding: 3px 12px; border-radius: 999px; }
.pcm-plan h3 { font-size: 19px; }
.pcm-price b { font: 900 30px Tajawal, sans-serif; }
.pcm-price small { color: var(--muted); font-size: 13px; }
.pcm-plan ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; flex: 1; color: var(--muted); font-size: 14.5px; }
.pcm-plan li .ic { color: var(--brand); }

/* أسئلة */
.pcm-faq { display: grid; gap: 10px; margin-top: 28px; }
.pcm-faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 0 18px; }
.pcm-faq summary { cursor: pointer; padding: 16px 0; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.pcm-faq summary::-webkit-details-marker { display: none; }
.pcm-faq summary::after { content: '+'; font: 700 22px Inter, sans-serif; color: var(--brand); line-height: 1; }
.pcm-faq details[open] summary::after { content: '–'; }
.pcm-faq details p { margin: 0 0 16px; color: var(--muted); }

/* نموذج الطلب */
.pcm-form { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: clamp(18px, 3vw, 30px); display: grid; gap: 14px; }
.pcm-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pcm-form label { display: grid; gap: 6px; font-weight: 700; font-size: 13.5px; }
.pcm-form input, .pcm-form textarea { width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--bg); color: var(--ink); font: 500 15px Tajawal, sans-serif; }
.pcm-form input:focus, .pcm-form textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 20%, transparent); }
.pcm-hp { position: absolute !important; inset-inline-start: -9999px !important; top: -9999px !important; }
.pcm-msg { margin: 0; min-height: 1.4em; text-align: center; font-weight: 700; }
.pcm-msg.ok { color: #1a7f37; } .pcm-msg.err { color: #b32d2e; }

/* التذييل */
.pcm-foot { background: var(--dark); color: #BFD0C7; padding: 46px 0 0; }
.pcm-foot-in { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 30px; }
.pcm-foot h4 { color: #fff; margin: 0 0 12px; }
.pcm-foot p { font-size: 14px; max-width: 46ch; }
.pcm-foot ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; font-size: 14.5px; }
.pcm-foot a { text-decoration: none; } .pcm-foot a:hover { color: #fff; }
.pcm-foot .pcm-brand { color: #fff; }
.pcm-copy { border-top: 1px solid #1B3428; margin-top: 34px; padding: 16px 0 22px; font-size: 13px; text-align: center; }
.pcm-wa { position: fixed; inset-block-end: max(18px, env(safe-area-inset-bottom)); inset-inline-start: 18px; z-index: 90; width: 54px; height: 54px; border-radius: 50%; background: #25D366; color: #fff; display: flex; align-items: center; justify-content: center; box-shadow: 0 10px 24px -8px rgba(0, 0, 0, .4); }
.pcm-wa .ic { width: 28px; height: 28px; }

/* بطاقة الدخول (نسخة العميل / نطاق مشترك) */
.pcm-gate { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 24px; background: radial-gradient(900px 500px at 50% -10%, color-mix(in srgb, var(--brand) 18%, transparent), transparent 60%), var(--bg); }
.pcm-gate-card { width: min(100%, 420px); background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 38px 30px; text-align: center; box-shadow: 0 30px 60px -34px rgba(0, 0, 0, .35); }
.pcm-gate-logo { border-radius: 18px; object-fit: contain; }
.pcm-gate-card h1 { font-size: 24px; font-weight: 900; margin: 14px 0 6px; }
.pcm-gate-card p { color: var(--muted); margin: 0 0 24px; }
.pcm-gate .pcm-btn { width: 100%; }

/* ---------- تجاوب ---------- */
@media (max-width: 900px) {
  .pcm-hero-grid { grid-template-columns: 1fr; }
  .pcm-hero-art { max-width: 480px; margin-inline: auto; width: 100%; }
  .pcm-mock, [dir="rtl"] .pcm-mock { transform: none; }
  .pcm-foot-in { grid-template-columns: 1fr 1fr; }
  .pcm-foot-in > div:first-child { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .pcm-nav-tog { display: inline-flex; }
  .pcm-menu { position: absolute; inset-inline: 0; top: 64px; background: var(--surface); border-bottom: 1px solid var(--line); padding: 10px 16px 18px; flex-direction: column; align-items: stretch; gap: 4px; display: none; box-shadow: 0 24px 40px -24px rgba(0, 0, 0, .35); }
  .pcm-menu.open { display: flex; }
  .pcm-menu .pcm-btn { margin: 6px 0 0; }
  .pcm-row { grid-template-columns: 1fr; }
  .pcm-cta-row .pcm-btn { flex: 1 1 100%; }
  .pcm-mock-kanban { grid-template-columns: repeat(2, 1fr); }
  .pcm-foot-in { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
