/* ===========================================================================
   LUMEO — أنماط الموقع
   امتداد لنظام التصميم في lumeo.css، خاص بصفحات الموقع والبوابة واللوحة.
   حقوق النشر محفوظة © شركة رامه الذكية للتجارة — ramh.sa
   ========================================================================= */

/* ------------------------------------------------------------ الترويسة */
.site-header {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(16px);
  background: rgba(5, 7, 13, .82);
  border-bottom: 1px solid var(--line-cool);
}
.site-header .bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px; padding: 14px 0;
}
.site-nav { display: flex; align-items: center; gap: 6px; }
.site-nav a {
  padding: 8px 15px; border-radius: 10px;
  font-size: 14px; font-weight: 500; color: var(--text-2); text-decoration: none;
  transition: background .18s var(--ease), color .18s var(--ease);
}
.site-nav a:hover { background: rgba(255,255,255,.04); color: var(--text); text-decoration: none; }
.site-nav a[aria-current='page'] { color: var(--gold-lift); background: var(--gold-wash); }

.burger { display: none; }

@media (max-width: 860px) {
  .site-nav {
    position: fixed; inset: 62px 0 auto 0; z-index: 99;
    flex-direction: column; align-items: stretch; gap: 2px;
    padding: 14px 18px 20px;
    background: var(--ink-050);
    border-bottom: 1px solid var(--line-cool);
    box-shadow: var(--shadow-3);
  }
  .site-nav:not(.open) { display: none; }
  .site-nav a { padding: 12px 14px; }
  .burger {
    display: inline-flex; align-items: center; justify-content: center;
    width: 40px; height: 40px; border-radius: 11px;
    background: var(--ink-200); border: 1px solid var(--line-cool);
    color: var(--text); font-size: 17px; cursor: pointer;
  }
  .header-cta { display: none; }
}

/* ---------------------------------------------------------------- الواجهة */
.hero { padding: clamp(60px, 11vw, 130px) 0 clamp(50px, 8vw, 96px); position: relative; }
.hero-inner { max-width: 780px; }
.hero h1 {
  font-size: clamp(34px, 6.2vw, 66px);
  font-weight: 700; line-height: 1.1; letter-spacing: -.035em;
  margin: 18px 0 20px;
}
.hero h1 .grad {
  background: linear-gradient(100deg, #FFF0C8 5%, var(--gold) 55%, #A9832A);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p.lead { font-size: clamp(15.5px, 1.9vw, 19px); max-width: 620px; }

.pill {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 7px 16px; border-radius: 99px;
  background: var(--gold-wash); border: 1px solid var(--line-strong);
  color: var(--gold-lift); font-size: 12.5px; font-weight: 600;
}

/* شبكة خافتة خلف الواجهة — عمق بلا ضجيج */
.hero::after {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(rgba(148,170,214,.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148,170,214,.045) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 60% at 60% 0%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 60% 0%, #000 20%, transparent 75%);
}

/* ---------------------------------------------------------------- الأقسام */
.section { padding: clamp(50px, 7vw, 92px) 0; }
.section-head { max-width: 640px; margin-bottom: 40px; }
.section-head h2 { margin: 10px 0 12px; }

/* ---------------------------------------------------------------- المزايا */
.feature {
  padding: 26px 24px; border-radius: var(--r-lg);
  background: linear-gradient(168deg, var(--ink-100), var(--ink-050));
  border: 1px solid var(--line-cool);
  transition: transform .25s var(--ease), border-color .25s var(--ease);
}
.feature:hover { transform: translateY(-3px); border-color: var(--line-strong); }
.feature .fico {
  width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center;
  background: var(--gold-wash); border: 1px solid var(--line-strong);
  color: var(--gold-lift); font-size: 20px; margin-bottom: 15px;
}
.feature h3 { font-size: 16.5px; font-weight: 600; margin-bottom: 7px; }
.feature p { font-size: 13.8px; color: var(--muted); line-height: 1.85; }

/* ---------------------------------------------------------------- الباقات */
.plans { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(268px, 1fr)); align-items: start; }

.plan {
  position: relative;
  padding: 30px 26px; border-radius: var(--r-xl);
  background: linear-gradient(168deg, var(--ink-100), var(--ink-050));
  border: 1px solid var(--line-cool);
  display: flex; flex-direction: column; gap: 18px;
  transition: transform .25s var(--ease), border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.plan:hover { transform: translateY(-4px); border-color: var(--line-strong); }

.plan.popular {
  border-color: var(--gold);
  box-shadow: 0 0 0 1px var(--gold), 0 30px 70px -34px rgba(201,162,39,.75);
}
.plan.popular::before {
  content: 'الأكثر طلباً';
  position: absolute; top: -12px; inset-inline-start: 50%; transform: translateX(-50%);
  padding: 5px 16px; border-radius: 99px; white-space: nowrap;
  background: linear-gradient(160deg, var(--gold-lift), var(--gold));
  color: #16120A; font-size: 11.5px; font-weight: 700;
  box-shadow: 0 10px 26px -12px rgba(201,162,39,.9);
}

.plan .pname { font-size: 20px; font-weight: 700; }
.plan .ptag { font-size: 13px; color: var(--muted); }
.plan .price { display: flex; align-items: baseline; gap: 8px; }
.plan .price b { font-size: 40px; font-weight: 700; letter-spacing: -.03em; line-height: 1; }
.plan .price span { font-size: 13px; color: var(--muted); }
.plan ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.plan li { display: flex; gap: 10px; font-size: 13.8px; color: var(--text-2); line-height: 1.6; }
.plan li::before { content: '✓'; color: var(--gold); font-weight: 700; flex: none; }
.plan li.off { color: var(--faint); }
.plan li.off::before { content: '—'; color: var(--faint); }

/* مبدّل الدورة */
.cycle-switch { display: inline-flex; margin-inline: auto; }

/* ---------------------------------------------------------------- الخطوات */
.steps-row { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); counter-reset: step; }
.step-card { padding: 24px; border-radius: var(--r-lg); background: var(--ink-050); border: 1px solid var(--line-cool); }
.step-card .n {
  counter-increment: step;
  width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center;
  background: var(--gold-wash); border: 1px solid var(--line-strong);
  color: var(--gold-lift); font-weight: 700; font-size: 14px; margin-bottom: 13px;
}
.step-card .n::before { content: counter(step); }
.step-card h3 { font-size: 15.5px; font-weight: 600; margin-bottom: 6px; }
.step-card p { font-size: 13.5px; color: var(--muted); line-height: 1.8; }

/* ---------------------------------------------------------------- الجداول */
.table-wrap { overflow-x: auto; border-radius: var(--r); border: 1px solid var(--line-cool); }
table.data { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 620px; }
table.data th, table.data td { padding: 12px 15px; text-align: start; border-bottom: 1px solid var(--line-cool); }
table.data th {
  background: var(--ink-050); font-weight: 600; font-size: 12px;
  color: var(--muted); white-space: nowrap;
  position: sticky; top: 0;
}
table.data tbody tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover { background: rgba(255,255,255,.02); }
table.data td.num { font-variant-numeric: tabular-nums; }

/* ------------------------------------------------------------ لوحة العميل */
.portal-shell { display: grid; grid-template-columns: 244px 1fr; gap: 26px; align-items: start; }
.portal-nav {
  position: sticky; top: 84px;
  display: flex; flex-direction: column; gap: 3px;
  padding: 14px; border-radius: var(--r-lg);
  background: var(--ink-050); border: 1px solid var(--line-cool);
}
.portal-nav a {
  display: flex; align-items: center; gap: 11px;
  padding: 10px 13px; border-radius: 11px;
  color: var(--text-2); font-size: 14px; font-weight: 500; text-decoration: none;
  transition: background .18s var(--ease), color .18s var(--ease);
}
.portal-nav a:hover { background: rgba(255,255,255,.04); color: var(--text); text-decoration: none; }
.portal-nav a[aria-current='page'] {
  background: var(--gold-wash); color: var(--gold-lift); font-weight: 600;
  box-shadow: inset 0 0 0 1px var(--line-strong);
}
.portal-nav .ico { width: 18px; text-align: center; opacity: .85; }

@media (max-width: 860px) {
  .portal-shell { grid-template-columns: 1fr; }
  .portal-nav { position: static; flex-direction: row; overflow-x: auto; }
  .portal-nav a { white-space: nowrap; }
}

/* --------------------------------------------------------------- النماذج */
.form-card { width: min(480px, 100%); margin-inline: auto; }
.form-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.form-grid .full { grid-column: 1 / -1; }

.error-box {
  padding: 13px 16px; border-radius: var(--r);
  background: var(--danger-wash); border: 1px solid rgba(242,88,79,.3);
  color: #FFB9B3; font-size: 13.5px; line-height: 1.7;
}
.ok-box {
  padding: 13px 16px; border-radius: var(--r);
  background: var(--ok-wash); border: 1px solid rgba(52,211,153,.3);
  color: #8FE9C4; font-size: 13.5px; line-height: 1.7;
}

/* ---------------------------------------------------------- رقم السيرفر */
.server-id {
  font-family: var(--mono); font-size: clamp(15px, 2.4vw, 21px); font-weight: 700;
  letter-spacing: .05em; color: var(--gold-lift); word-break: break-all;
}
.code-box {
  font-family: var(--mono); font-size: 11.5px; line-height: 1.6;
  padding: 14px; border-radius: var(--r-sm);
  background: var(--ink-000); border: 1px solid var(--line-cool);
  color: var(--text-2); word-break: break-all;
  max-height: 170px; overflow: auto;
}

/* ---------------------------------------------------------------- التذييل */
.site-footer {
  border-top: 1px solid var(--line-cool);
  background: var(--ink-050);
  padding: 48px 0 30px; margin-top: 60px;
}
.footer-grid { display: grid; gap: 34px; grid-template-columns: 1.6fr repeat(auto-fit, minmax(150px, 1fr)); }
.footer-col h4 { font-size: 12px; font-weight: 600; letter-spacing: .12em; color: var(--gold); margin-bottom: 14px; }
.footer-col a, .footer-col p { display: block; font-size: 13.5px; color: var(--muted); margin-bottom: 9px; text-decoration: none; }
.footer-col a:hover { color: var(--text-2); text-decoration: none; }
.footer-bottom {
  margin-top: 36px; padding-top: 22px; border-top: 1px solid var(--line-cool);
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: 12px; color: var(--faint);
}

/* ------------------------------------------------------------ لوحة الإدارة */
.admin-shell { display: grid; grid-template-columns: 232px 1fr; min-height: 100dvh; }
.admin-side {
  background: var(--ink-050); border-inline-end: 1px solid var(--line-cool);
  padding: 22px 14px; display: flex; flex-direction: column; gap: 20px;
  position: sticky; top: 0; height: 100dvh; overflow-y: auto;
}
.admin-side nav { display: flex; flex-direction: column; gap: 2px; }
.admin-side nav a {
  display: flex; align-items: center; gap: 11px;
  padding: 10px 13px; border-radius: 11px;
  color: var(--text-2); font-size: 13.8px; text-decoration: none;
}
.admin-side nav a:hover { background: rgba(255,255,255,.04); color: var(--text); text-decoration: none; }
.admin-side nav a[aria-current='page'] {
  background: var(--gold-wash); color: var(--gold-lift); font-weight: 600;
}
.admin-main { padding: 24px 28px 60px; min-width: 0; }

@media (max-width: 900px) {
  .admin-shell { grid-template-columns: 1fr; }
  .admin-side {
    position: static; height: auto; flex-direction: row; align-items: center;
    overflow-x: auto; padding: 12px 14px;
    border-inline-end: 0; border-bottom: 1px solid var(--line-cool);
  }
  .admin-side nav { flex-direction: row; }
  .admin-side nav a { white-space: nowrap; }
  .admin-main { padding: 18px 16px 50px; }
}

/* إحصاءات */
.kpi { padding: 18px 20px; }
.kpi .v { font-size: 27px; font-weight: 700; letter-spacing: -.02em; line-height: 1.2; }
.kpi .l { font-size: 12px; color: var(--muted); margin-top: 2px; }

/* ---------------------------------------------------------- نصّ الوثائق */
.doc-body h2 { font-size: 21px; font-weight: 700; margin: 32px 0 12px; }
.doc-body h3 { font-size: 16px; font-weight: 600; margin: 20px 0 8px; color: var(--gold-lift); }
.doc-body p, .doc-body li { font-size: 14.5px; line-height: 1.95; color: var(--text-2); }
.doc-body ul, .doc-body ol { padding-inline-start: 22px; margin: 10px 0; }
.doc-body li { margin-bottom: 7px; }
.doc-body strong { color: var(--text); font-weight: 600; }

/* ------------------------------------------------------ مُدرّج عدد الشاشات */
.stepper { display: flex; align-items: stretch; gap: 8px; }
.stepper .step-input { text-align: center; flex: 1; min-width: 0; }
.step-btn {
  width: 44px; flex: none; border-radius: 12px; cursor: pointer;
  background: var(--ink-300); border: 1px solid var(--line-cool);
  color: var(--text); font-size: 19px; font-weight: 600; line-height: 1;
  transition: background .18s var(--ease), border-color .18s var(--ease);
}
.step-btn:hover { background: var(--ink-200); border-color: var(--line-strong); }
.step-btn:active { transform: translateY(1px); }

.plan-custom .price b { font-size: 34px; }
