/* الصفحة الرئيسية */

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes draw { from { stroke-dashoffset: 400; } to { stroke-dashoffset: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes pulse { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }

.anim-draw { stroke-dasharray: 400; animation: draw 2.2s ease-in-out both; }
.anim-rise { animation: rise 1s ease-out both; }
.anim-pulse { animation: pulse 2.4s ease-in-out infinite; }

body {
  position: relative;
}

/* علامة الخلفية الدوّارة؛ الغلاف يقصّ ما يتجاوز عرض الشاشة */
.bgmark {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.bgmark__inner {
  position: absolute;
  top: 40px;
  left: 50%;
  width: min(1100px, 160%);
  transform: translateX(-50%);
  color: var(--watermark);
}

.bgmark svg {
  width: 100%;
  height: auto;
  animation: spin 120s linear infinite;
}

main {
  position: relative;
  z-index: 1;
}

.site-footer {
  position: relative;
  z-index: 1;
}

.display {
  font-size: clamp(28px, 3.4vw, 46px);
  font-weight: 700;
  line-height: 1.45;
  letter-spacing: -.01em;
}

.display--24 { max-width: 24ch; }
.display--26 { max-width: 26ch; }

.section-head {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rule {
  display: block;
  width: 48px;
  height: 2px;
  background: var(--accent);
}

/* ===== البطل ===== */

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 34px;
  padding: 96px 24px 0;
  text-align: center;
}

.hero__logo {
  width: clamp(120px, 14vw, 180px);
  height: auto;
}

.hero__mark {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.hero__word {
  font-size: clamp(52px, 7vw, 92px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -.01em;
}

.hero__tag {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 14px;
  color: var(--muted);
  letter-spacing: .08em;
}

.hero__tag-line {
  display: block;
  width: 44px;
  height: 1px;
  background: var(--ink);
}

.hero__divider {
  width: 1px;
  height: 40px;
  background: var(--muted);
}

.hero__title {
  font-size: clamp(26px, 3vw, 40px);
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: -.01em;
}

.hero__lead {
  max-width: 620px;
  font-size: 18px;
  line-height: 1.9;
  color: var(--muted);
}

.hero__platforms {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 10px;
  font-size: 16px;
}

.chip__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.chip--on {
  background: var(--accent);
  color: var(--on-accent);
}

.chip--on .chip__dot {
  background: var(--bg-alt);
}

.chip--soon {
  border: 1px dashed var(--line-strong);
  color: var(--muted);
}

.chip--soon .chip__dot {
  border: 1px solid var(--muted);
}

/* ===== ماذا تحتاج؟ ===== */

.need {
  /* في التصميم يقع هذا القسم داخل البطل، فيرث حافته الإضافية (24px) */
  max-width: calc(1280px + 48px + 2 * clamp(20px, 5vw, 80px));
  padding-inline: calc(24px + clamp(20px, 5vw, 80px));
  display: flex;
  flex-direction: column;
  gap: 48px;
  padding-top: calc(34px + clamp(80px, 12vh, 140px));
  padding-bottom: calc(80px + clamp(80px, 12vh, 140px));
}

.need__body {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 40px;
}

.need__list {
  display: flex;
  flex: 1 1 380px;
  flex-direction: column;
  min-width: 0;
  border-top: 1px solid var(--line);
}

.need__item {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  min-height: 64px;
  padding: 14px 18px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--ink-soft);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -.01em;
  text-align: right;
  cursor: pointer;
}

.need__item[aria-pressed="true"] {
  background: var(--accent);
  color: var(--on-accent);
}

.need__dot {
  flex: none;
  width: 10px;
  height: 10px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
}

.need__item[aria-pressed="true"] .need__dot {
  border-color: transparent;
  background: var(--on-accent);
}

.need__panel {
  display: flex;
  flex: 1 1 420px;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid var(--line);
  background: var(--bg-alt);
}

.need__cat {
  font-size: 14px;
  color: var(--muted);
}

.need__app {
  font-size: clamp(34px, 4vw, 52px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -.01em;
}

.need__answer {
  font-size: 18px;
  line-height: 1.9;
  color: var(--ink-soft);
}

.need__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 8px;
}

.btn--46 {
  min-height: 46px;
}

/* ===== رحلة الطلب ===== */

.journey {
  border-top: 1px solid var(--line);
  background: var(--bg-alt);
}

.journey__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.journey__step {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 30px 20px;
  border-left: 1px solid var(--line);
}

.journey__step:first-child {
  padding-right: 0;
}

.journey__step:last-child {
  border-left: 0;
}

.journey__num {
  font-size: 13px;
  color: var(--muted);
}

.journey__title {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -.01em;
}

.journey__apps {
  font-size: 14px;
  color: var(--muted);
}

/* ===== التطبيقات ===== */

.apps__intro {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-top: clamp(96px, 14vh, 160px);
  padding-bottom: 24px;
}

.apps__groups {
  display: flex;
  flex-direction: column;
  gap: 64px;
  padding-top: 24px;
  padding-bottom: clamp(80px, 12vh, 140px);
}

.app-group {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.app-group__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  padding-top: 22px;
  border-top: 1px solid var(--ink);
}

.app-group__titles {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.app-group__name {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 26px;
  font-weight: 400;
}

.app-group__bar {
  width: 18px;
  height: 3px;
  background: var(--accent);
}

.app-group__sub {
  font-size: 15px;
  color: var(--muted);
}

.app-group__count {
  font-size: 14px;
  color: var(--muted);
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.app-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  transition: transform .18s ease, box-shadow .18s ease;
}

.app-card:hover {
  transform: translateY(-3px);
  border-color: var(--ink);
  box-shadow: 0 14px 30px var(--shadow-card-hover);
}

.app-card--wide {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) auto;
  align-items: center;
  gap: 40px;
}

.app-card__head {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.app-card__head img {
  flex: none;
}

.app-card__titles {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.app-card__name {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.1;
}

.app-card__sub {
  font-size: 15px;
  color: var(--muted);
}

.checks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.checks li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink-list);
}

.checks li::before {
  content: "";
  flex: none;
  width: 16px;
  height: 16px;
  background: var(--blue);
  -webkit-mask: url("/assets/icons/check.svg") center / contain no-repeat;
  mask: url("/assets/icons/check.svg") center / contain no-repeat;
}

.app-card__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.app-card--wide .app-card__foot {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.btn--card {
  padding: 0 18px;
}

.text-link {
  font-size: 15px;
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 5px;
}

.text-link[href]:hover {
  text-decoration-thickness: 2px;
}

.text-link.is-soon {
  text-decoration: none;
}

/* ===== كيف تعمل ===== */

.how {
  background: linear-gradient(180deg, var(--bg-alt) 0%, var(--bg) 240px);
}

.how__inner {
  display: flex;
  flex-direction: column;
  gap: 48px;
  padding-block: clamp(80px, 12vh, 140px);
}

.how__steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(24px, 3.5vw, 56px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.how__step {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-top: 28px;
  border-top: 1px solid var(--ink);
}

.how__num {
  font-size: 14px;
  color: var(--muted);
}

.how__title {
  font-size: clamp(22px, 2.2vw, 30px);
  font-weight: 700;
}

.how__text {
  font-size: 16px;
  line-height: 1.8;
  color: var(--muted);
}

/* ===== المنصات ===== */

.platforms {
  position: relative;
  overflow: hidden;
  background: var(--bg-alt);
}

.platforms__mark {
  position: absolute;
  left: -8%;
  bottom: -40%;
  width: 46%;
  color: var(--watermark-2);
}

.platforms__mark svg {
  width: 100%;
  height: auto;
}

.platforms__inner {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  padding-block: clamp(80px, 12vh, 130px);
}

.platforms__inner .display {
  line-height: 1.5;
}

.platforms__list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 260px;
}

.platforms__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--ink);
}

.platforms__name {
  font-size: 24px;
}

.platforms__name--soon {
  color: var(--muted);
}

.badge {
  padding: 6px 14px;
  font-size: 14px;
}

.badge--on {
  background: var(--accent);
  color: var(--on-accent);
}

.badge--soon {
  border: 1px dashed var(--muted);
  color: var(--muted);
}

/* ===== الأسئلة ===== */

.faq {
  display: flex;
  flex-direction: column;
  gap: 40px;
  padding-block: clamp(96px, 14vh, 160px);
}

.faq__row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 40px;
  padding: 26px 0;
  border-top: 1px solid var(--line);
}

.faq__row:last-child {
  border-bottom: 1px solid var(--line);
}

.faq__q {
  flex: 1 1 320px;
  font-size: 21px;
  font-weight: 700;
}

.faq__a {
  flex: 2 1 420px;
  font-size: 16px;
  line-height: 1.8;
  color: var(--muted);
}

/* ===== التذييل ===== */

.site-footer {
  border-top: 1px solid var(--line);
}

.site-footer__inner {
  display: flex;
  flex-direction: column;
  gap: 48px;
  padding-top: 64px;
  padding-bottom: 36px;
}

.site-footer__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.site-footer__brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.site-footer__sep {
  width: 1px;
  height: 40px;
  background: var(--ink);
}

.site-footer__names {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.site-footer__name {
  font-size: 24px;
}

.site-footer__tag {
  font-size: 13px;
  color: var(--muted);
}

.site-footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  font-size: 15px;
}

.site-footer__nav a {
  color: var(--muted);
  text-decoration: none;
}

.site-footer__nav a:hover {
  color: var(--ink);
}

.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
}

/* ===== الشاشات الأصغر ===== */

@media (max-width: 860px) {
  .app-grid,
  .app-card--wide {
    grid-template-columns: minmax(0, 1fr);
  }

  .app-card--wide {
    gap: 22px;
  }

  .how__steps {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 720px) {
  .hero {
    padding-top: 64px;
  }

  .need__list,
  .need__panel {
    flex-basis: 100%;
  }

  .need__item {
    font-size: 17px;
  }

  .journey__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .journey__step,
  .journey__step:first-child {
    padding: 22px 16px;
    border-left: 0;
    border-bottom: 1px solid var(--line);
  }

  .journey__step:nth-child(odd) {
    padding-right: 0;
    border-left: 1px solid var(--line);
  }

  .journey__step:nth-child(n+3) {
    border-bottom: 0;
  }

  .app-card {
    padding: 22px;
  }

  .platforms__list {
    width: 100%;
    min-width: 0;
  }

  .faq__q,
  .faq__a {
    flex-basis: 100%;
  }
}

@media (max-width: 480px) {
  .checks {
    grid-template-columns: minmax(0, 1fr);
  }

  .app-card__name {
    font-size: 24px;
  }
}
