/* ------------------------------------------------------------------ *
 *  ستايل مشترك لصفحات الموقع (landing / features / buy / legal):
 *  الألوان، الخلفية، الشريط العلوي، القوائم المنسدلة، الأزرار،
 *  زر اللغة (علم)، كرت المستخدم، أقسام الصفحة، الفوتر، التوست.
 *  كل صفحة تضيف ستايلها الخاص بعده.
 * ------------------------------------------------------------------ */
:root {
  --bg: #09090b;
  --bg2: #111114;
  --elev: #202024;
  --line: #232327;
  --fg: #f5f5f5;
  --muted: #a1a1a6;
  --dim: #6e6e73;
  --primary: #ff1018;
  --primary-soft: rgba(255, 16, 24, 0.14);
  --glass: rgba(17, 17, 20, 0.62);
  --glass-line: rgba(255, 255, 255, 0.07);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: hidden; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: 'Alexandria', system-ui, sans-serif;
  overflow-x: hidden;
}
/* العناصر المخفية تبقى مخفية حتى لو كان لها display خاص (flex/grid) */
[hidden] { display: none !important; }
html[lang="en"] body { font-family: Inter, system-ui, sans-serif; }
::selection { background: var(--primary); color: #fff; }

/* موجة عند الضغط */
.ripple {
  position: fixed; z-index: 9998; pointer-events: none;
  width: 10px; height: 10px; border-radius: 50%;
  border: 2px solid var(--primary);
  transform: translate(-50%, -50%);
  animation: ripple .55s ease-out forwards;
}
@keyframes ripple {
  to { width: 70px; height: 70px; opacity: 0; }
}
/* شبكة نقاط خفيفة — الخلفية الوحيدة (بدون كرات أو توهج) */
.dots {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, 0.06) 1.2px, transparent 1.2px);
  background-size: 26px 26px;
}


main, nav, footer { position: relative; z-index: 1; }

/* ---------- الشريط العلوي (زجاجي) ---------- */
nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 12px clamp(16px, 5vw, 56px);
  background: rgba(9, 9, 11, 0.55);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  backdrop-filter: blur(18px) saturate(1.3);
  border-bottom: 1px solid var(--glass-line);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--fg); }
.brand img, .brand svg { width: 34px; height: 34px; }
.brand img { object-fit: contain; }
.brand b { font-family: Inter, sans-serif; font-weight: 900; letter-spacing: .12em; font-size: 15px; }
.brand b span { color: var(--primary); }
/* التبويبات: كبسولة زجاجية واحدة، كل تبويب أيقونة + اسم */
/* هالة حمراء ضبابية تتبع الماوس (تُضاف من site.js) — خلف المحتوى */
.cursor-glow {
  position: fixed; top: 0; left: 0; z-index: 0; pointer-events: none;
  width: 420px; height: 420px; margin: -210px 0 0 -210px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 16, 24, 0.22) 0%, rgba(255, 16, 24, 0.08) 35%, rgba(255, 16, 24, 0) 70%);
  filter: blur(28px); opacity: 0; transition: opacity .4s, transform .05s linear;
  will-change: transform;
}
.cursor-glow.show { opacity: 1; }
@media (hover: none), (max-width: 900px) { .cursor-glow { display: none; } }

.nav-links {
  display: flex; gap: 2px; padding: 4px;
  border: 1px solid var(--glass-line); border-radius: 999px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
.nav-links > a, .nav-dd > a {
  display: inline-flex; align-items: center; gap: 7px;
  color: var(--muted); text-decoration: none; font-size: 13px; font-weight: 600;
  padding: 7px 14px; border-radius: 999px; transition: .15s;
}
.nav-links > a svg, .nav-dd > a svg { width: 14px; height: 14px; flex-shrink: 0; }
.nav-links > a:hover, .nav-dd:hover > a { color: var(--fg); background: rgba(255, 255, 255, 0.06); }
/* التبويب الحالي: خلفية + خط ملوّن تحته */
.nav-links > a, .nav-dd > a { position: relative; }
.nav-links > a.on, .nav-dd.on > a { color: var(--fg); background: rgba(255, 255, 255, 0.06); }
.nav-links > a > span, .nav-dd > a > span { position: relative; }
/* الخط تحت الكلمة: يظهر بالـ hover ويثبت على التبويب الحالي */
.nav-links > a > span::after, .nav-dd > a > span::after {
  content: ''; position: absolute; left: 50%; bottom: -6px; transform: translateX(-50%) scaleX(0);
  width: 100%; height: 3px; border-radius: 999px; background: var(--primary);
  box-shadow: 0 0 12px rgba(255, 16, 24, 0.9), 0 0 4px rgba(255, 16, 24, 1);
  opacity: 0; transition: transform .22s ease, opacity .22s ease;
}
.nav-links > a:hover > span::after, .nav-dd:hover > a > span::after { transform: translateX(-50%) scaleX(0.7); opacity: 0.75; }
.nav-links > a.on > span::after, .nav-dd.on > a > span::after { transform: translateX(-50%) scaleX(1); opacity: 1; }
.nav-dd.on > a > span::after { left: 50%; }

/* القوائم المنسدلة (تظهر بالـ hover) */
.nav-dd { position: relative; }
.nav-dd > a .chev { transition: transform .2s; }
.nav-dd:hover > a .chev { transform: rotate(180deg); }
.dd-wrap {
  position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
  padding-top: 12px; z-index: 60;
  opacity: 0; visibility: hidden; transition: .18s;
}
.nav-dd:hover .dd-wrap { opacity: 1; visibility: visible; }
.dd-menu {
  width: 640px; max-width: calc(100vw - 32px);
  display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 10px;
  background: rgba(14, 14, 17, 0.92); border: 1px solid var(--glass-line); border-radius: 16px;
  -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px);
  box-shadow: 0 20px 60px rgba(0,0,0,.6);
  animation: menuIn .18s ease both;
}
.dd-menu.small { width: 230px; grid-template-columns: 1fr; padding: 6px; border-radius: 13px; }
.dd-item {
  display: flex; align-items: center; gap: 12px; padding: 12px;
  border-radius: 11px; text-decoration: none; color: var(--fg); transition: .13s;
  font-size: 13.5px; font-weight: 600;
}
.dd-item:hover { background: rgba(255, 255, 255, 0.05); }
.dd-item .ico { width: 36px; height: 36px; margin: 0; flex-shrink: 0; }
.dd-item .ico svg { width: 18px; height: 18px; }
.dd-item:hover .ico { color: var(--primary); background: var(--primary-soft); }
.dd-item b { display: block; font-size: 14px; margin-bottom: 2px; }
.dd-item small { display: block; color: var(--dim); font-size: 12px; line-height: 1.5; }

/* أيقونة داخل مربع (تستخدمها القائمة المنسدلة وبطاقات المميزات) */
.ico {
  width: 42px; height: 42px; border-radius: 11px;
  display: flex; align-items: center; justify-content: center;
  background: var(--elev); color: var(--muted); transition: .25s;
  margin-bottom: 16px;
}
.ico svg { width: 20px; height: 20px; }

.nav-side { display: flex; align-items: center; gap: 8px; }
@media (max-width: 1080px) { .nav-links > a, .nav-dd > a { padding: 7px 10px; font-size: 12.5px; } }
@media (max-width: 900px) { .nav-links { display: none; } }

/* زر اللغة: علم الدولة الحالية (أمريكا = English، السعودية = عربي) — الضغط يبدّل */
.lang-flag {
  width: 46px; height: 38px; border-radius: 12px;
  border: 1px solid var(--glass-line); background: var(--glass);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer; transition: .15s; padding: 0;
}
.lang-flag:hover { border-color: #3a3a40; background: rgba(32, 32, 36, 0.8); }
.lang-flag svg {
  width: 22px; height: 15px; border-radius: 2.5px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
  transition: transform .2s;
}
.lang-flag:hover svg { transform: scale(1.08); }

/* زر تسجيل الدخول: كبسولة زجاجية + شعار Discord قبل الكلمة */
.btn-login {
  display: inline-flex; align-items: center; gap: 9px;
  height: 38px; padding: 0 16px; border-radius: 12px;
  border: 1px solid var(--glass-line); background: var(--glass);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  color: var(--fg); font-family: inherit; font-size: 13px; font-weight: 700;
  cursor: pointer; transition: .15s; text-decoration: none; white-space: nowrap;
}
.btn-login:hover { border-color: #3a3a40; background: rgba(32, 32, 36, 0.8); }
.btn-login svg { width: 16px; height: 16px; flex-shrink: 0; color: #fff; }

/* ---------- الأزرار ---------- */
.btn {
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; gap: 9px;
  border: 0; border-radius: 11px; padding: 13px 26px;
  font-family: inherit; font-size: 14.5px; font-weight: 700;
  text-decoration: none; transition: .18s; user-select: none; cursor: pointer;
}
.btn:active { transform: scale(.97); }
/* لمعة تمر على الزر */
.btn::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,.25) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform .6s;
}
html[dir="rtl"] .btn::after { transform: translateX(120%); }
.btn:hover::after { transform: translateX(120%); }
html[dir="rtl"] .btn:hover::after { transform: translateX(-120%); }
.btn-light { background: #fff; color: #0a0a0c; }
.btn-light:hover { background: #e9e9ea; box-shadow: 0 0 32px rgba(255,255,255,.15); }
.btn-dark {
  background: rgba(255,255,255,.04); color: var(--fg);
  border: 1px solid var(--line);
}
.btn-dark:hover { border-color: #3a3a40; background: var(--elev); }
.btn-red { background: var(--primary); color: #fff; box-shadow: 0 0 26px rgba(255, 16, 24, 0.35); }
.btn-red:hover { background: #ff3a41; box-shadow: 0 0 36px rgba(255, 16, 24, 0.5); }
.btn-sm { padding: 9px 18px; font-size: 13px; }
.btn svg { width: 17px; height: 17px; flex-shrink: 0; }
.btn:disabled { opacity: .55; cursor: not-allowed; }

/* شريط المستخدم بعد الدخول */
.user-chip {
  display: inline-flex; align-items: center; gap: 10px; height: 38px;
  border: 1px solid var(--glass-line); border-radius: 12px;
  background: var(--glass); padding: 0 6px 0 14px; cursor: pointer;
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  transition: .15s;
}
html[dir="rtl"] .user-chip { padding: 0 14px 0 6px; }
.user-chip:hover { border-color: #3a3a40; }
.user-chip img { width: 28px; height: 28px; border-radius: 8px; }
.user-chip b { font-size: 13px; }
.user-wrap { position: relative; display: inline-block; }
.user-menu {
  position: absolute; top: calc(100% + 8px); inset-inline-end: 0; z-index: 60;
  min-width: 230px; padding: 6px;
  background: rgba(14, 14, 17, 0.94); border: 1px solid var(--glass-line); border-radius: 13px;
  -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px);
  box-shadow: 0 16px 48px rgba(0,0,0,.55);
  animation: menuIn .16s ease both;
}
@keyframes menuIn { from { opacity: 0; transform: translateY(-6px); } }
.user-menu .email {
  display: block; padding: 10px 12px 8px; color: var(--dim);
  font-size: 11.5px; direction: ltr; text-align: end;
  border-bottom: 1px solid var(--line); margin-bottom: 6px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.user-menu a, .user-menu button {
  display: flex; align-items: center; gap: 9px; width: 100%;
  background: none; border: 0; border-radius: 9px; padding: 9px 12px;
  color: var(--fg); font-family: inherit; font-size: 13px; font-weight: 600;
  text-decoration: none; transition: .13s; text-align: start; cursor: pointer;
}
.user-menu a:hover, .user-menu button:hover { background: rgba(255, 255, 255, 0.05); }
.user-menu .danger { color: #ff6b70; }
.user-menu svg { width: 15px; height: 15px; flex-shrink: 0; }

/* ---------- أقسام الصفحة (تظهر عند السكرول) ---------- */
[data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .6s cubic-bezier(.2,.7,.2,1), transform .6s cubic-bezier(.2,.7,.2,1); }
[data-reveal].shown { opacity: 1; transform: none; }
/* من يفضّل تقليل الحركة يرى كل شيء مباشرة */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  [data-reveal], .card, .feat { opacity: 1 !important; transform: none !important; transition: none !important; }
}

.sec { position: relative; padding: 96px clamp(16px, 6vw, 72px); border-top: 1px solid var(--line); }
.sec-in { max-width: 1120px; margin: 0 auto; }
.sec-head { text-align: center; max-width: 660px; margin: 0 auto; }
.eyebrow {
  display: block; color: var(--dim); font-family: Inter, sans-serif;
  font-size: 11.5px; font-weight: 700; letter-spacing: .26em; margin-bottom: 18px;
}
.eyebrow::before { content: '— '; }
html[lang="ar"] .eyebrow { font-family: inherit; letter-spacing: .04em; font-size: 12.5px; }
.sec h2 { font-size: clamp(30px, 4.6vw, 52px); font-weight: 800; line-height: 1.15; letter-spacing: -.02em; }
html[lang="ar"] .sec h2 { letter-spacing: 0; }
.sec .lead { color: var(--muted); font-size: clamp(14.5px, 1.6vw, 17px); line-height: 1.85; margin-top: 16px; }

/* بطاقات زجاجية بأيقونة عائمة فوق الحافة (لماذا TiTans / كيف يعمل) */
.cards3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 28px; padding-top: 104px; }
.fcard {
  position: relative; text-align: center;
  border: 1px solid var(--glass-line); border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  padding: 62px 28px 34px; transition: .25s;
}
.fcard:hover { border-color: rgba(255, 255, 255, 0.14); background: rgba(255, 255, 255, 0.045); transform: translateY(-4px); }
.fcard .fico {
  position: absolute; top: -46px; left: 50%; transform: translateX(-50%);
  width: 92px; height: 92px; border-radius: 24px;
  background: rgba(12, 12, 15, 0.85); border: 1px solid var(--glass-line);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  display: flex; align-items: center; justify-content: center; color: var(--primary);
  box-shadow: 0 12px 30px rgba(0,0,0,.55); transition: .25s;
}
.fcard .fico svg { width: 34px; height: 34px; }
.fcard:hover .fico { border-color: rgba(255, 255, 255, 0.16); }
.fcard .num { display: block; color: var(--primary); font-family: Inter, sans-serif; font-size: 11px; font-weight: 700; letter-spacing: .26em; margin-bottom: 10px; }
.fcard b { display: block; font-size: 19px; font-weight: 800; margin-bottom: 12px; }
.fcard p { color: var(--muted); font-size: 14px; line-height: 1.85; }

/* صندوق المساعدة (زجاجي بدون توهج أحمر) */
.help-box {
  border: 1px solid var(--glass-line); border-radius: 22px; text-align: center; padding: 72px 24px;
  background: rgba(255, 255, 255, 0.03);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
}
.help-box h2 { font-size: clamp(26px, 3.6vw, 40px); font-weight: 800; }
.help-box p { color: var(--muted); font-size: 15px; margin: 14px 0 30px; }
.help-box .cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ---------- الفوتر: الشعار والاسم / الروابط / الحقوق ---------- */
footer.foot {
  border-top: 1px solid var(--line);
  padding: 34px clamp(16px, 5vw, 56px);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 18px;
}
.foot .brand { justify-self: start; }
.foot .brand b { letter-spacing: .16em; font-size: 14px; }
.foot-links { display: flex; gap: 22px; flex-wrap: wrap; justify-content: center; }
.foot-links a { color: var(--muted); font-size: 13px; font-weight: 600; text-decoration: none; transition: .15s; }
.foot-links a:hover { color: var(--fg); }
.foot .copy { justify-self: end; color: var(--dim); font-size: 12.5px; white-space: nowrap; }
@media (max-width: 800px) {
  footer.foot { grid-template-columns: 1fr; text-align: center; }
  .foot .brand, .foot .copy { justify-self: center; }
}

.toast {
  position: fixed; bottom: 24px; right: 50%; transform: translateX(50%);
  z-index: 100; background: rgba(14, 14, 17, 0.94); border: 1px solid var(--glass-line);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-radius: 12px; padding: 12px 20px; font-size: 13px; color: var(--fg);
  box-shadow: 0 12px 40px rgba(0,0,0,.5); display: none; max-width: calc(100vw - 32px);
}
