@import url('https://fonts.googleapis.com/css2?family=Quicksand:wght@400;500;600;700&family=Cairo:wght@400;500;600;700;900&display=swap');

/* ──────────────────────────────────────────────────────────────
   Brand tokens
   (Ported from the provided Figma Make design system. The original
   file used Tailwind v4's `@theme` + `@import 'tailwindcss'`, which
   needs a build step. This site is plain HTML/CSS/JS with no build
   tooling, so the same tokens are declared here as ordinary custom
   properties instead — same values, no Tailwind required.)
   ────────────────────────────────────────────────────────────── */
:root {
  --color-brand-purple:   #6C4AB6;
  --color-brand-deep:     #4B2E83;
  --color-brand-bright:   #8B63D9;
  --color-brand-lavender: #C9B8F4;
  --color-brand-pale:     #F1EDFA;
  --color-brand-coral:    #FF7A70;
  --color-brand-yellow:   #FFD45A;
  --color-brand-mint:     #75D6B0;
  --color-brand-dark:     #25213A;
  --color-brand-offwhite: #FCFBFF;
  --font-quicksand: 'Quicksand', sans-serif;
  --font-cairo: 'Cairo', sans-serif;

  --c-bg:           #FCFBFF;
  --c-bg-hero:      #F1EDFA;
  --c-bg-hero2:     #EDF9F4;
  --c-surface:      #FFFFFF;
  --c-surface-alt:  #F1EDFA;
  --c-surface-alt2: #EDE5FA;
  --c-surface-card: #EDF9F4;
  --c-text:         #25213A;
  --c-muted:        #5A5070;
  --c-faint:        #7A7090;
  --c-border:       #C9B8F4;
  --c-border-soft:  #F1EDFA;
  --c-tag-bg:       #F1EDFA;
  --c-scroll-bg:    rgba(252, 251, 255, 0.86);
  --c-footer-bg:    #25213A;
  --c-footer-text:  rgba(255,255,255,0.5);
  --c-footer-head:  #C9B8F4;
  --c-footer-dim:   rgba(255,255,255,0.3);
  --c-footer-rule:  #3A3356;
  --c-progress-bg:  #F1EDFA;
}

[data-theme="dark"] {
  --c-bg:           #100D1C;
  --c-bg-hero:      #1C1630;
  --c-bg-hero2:     #111B18;
  --c-surface:      #1C1830;
  --c-surface-alt:  #241E38;
  --c-surface-alt2: #1E183A;
  --c-surface-card: #141E1A;
  --c-text:         #F0EAFF;
  --c-muted:        #A090C0;
  --c-faint:        #7A6A9A;
  --c-border:       #3A3060;
  --c-border-soft:  #2A2448;
  --c-tag-bg:       #2A2060;
  --c-scroll-bg:    rgba(16, 13, 28, 0.86);
  --c-footer-bg:    #080612;
  --c-footer-text:  rgba(255,255,255,0.4);
  --c-footer-head:  #8B63D9;
  --c-footer-dim:   rgba(255,255,255,0.2);
  --c-footer-rule:  #1E1A34;
  --c-progress-bg:  #2A2448;
}

/* ── Reset & base ── */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-quicksand);
  background-color: var(--c-bg);
  color: var(--c-text);
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.3s ease, color 0.3s ease;
  line-height: 1.55;
}

html[lang="ar"] body { font-family: var(--font-cairo); }

img { max-width: 100%; display: block; }
a { color: inherit; }

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--color-brand-lavender); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--color-brand-bright); }

:focus-visible {
  outline: 2px solid var(--color-brand-purple);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap {
  width: 100%;
  max-width: 1040px;
  margin-inline: auto;
  padding-inline: 24px;
}

/* ── Animations ── */
@keyframes floatSeed {
  0%, 100% { transform: translateY(0px) rotate(-5deg); }
  50%       { transform: translateY(-12px) rotate(5deg); }
}
@keyframes sparkle {
  0%, 100% { opacity: 0.3; transform: scale(0.8); }
  50%       { opacity: 1;   transform: scale(1.2); }
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

.float-seed  { animation: floatSeed 4s ease-in-out infinite; }
.sparkle-1   { animation: sparkle 2s ease-in-out infinite; }
.sparkle-2   { animation: sparkle 2s ease-in-out infinite 0.6s; }
.sparkle-3   { animation: sparkle 2s ease-in-out infinite 1.2s; }
.fade-in-up  { animation: fadeInUp 0.7s ease-out forwards; }

@media (prefers-reduced-motion: reduce) {
  .float-seed, .sparkle-1, .sparkle-2, .sparkle-3, .fade-in-up {
    animation: none !important;
  }
  html { scroll-behavior: auto; }
}

.card-hover { transition: transform 0.25s ease, box-shadow 0.25s ease; }
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(108, 74, 182, 0.22);
}

/* ── Buttons ── */
.btn-primary {
  background: var(--color-brand-purple);
  color: var(--color-brand-offwhite);
  font-family: inherit;
  font-weight: 700;
  border-radius: 100px;
  padding: 14px 28px;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}
.btn-primary:hover {
  background: var(--color-brand-deep);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(108, 74, 182, 0.4);
}
.btn-primary:active { transform: translateY(0); }

.btn-secondary {
  background: transparent;
  color: var(--color-brand-purple);
  font-family: inherit;
  font-weight: 700;
  border-radius: 100px;
  padding: 13px 28px;
  font-size: 1rem;
  border: 2px solid var(--color-brand-purple);
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}
.btn-secondary:hover {
  background: var(--c-tag-bg);
  transform: translateY(-2px);
}

[data-theme="dark"] .btn-secondary { border-color: var(--color-brand-bright); color: var(--color-brand-lavender); }
[data-theme="dark"] .btn-secondary:hover { background: var(--c-tag-bg); }

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--c-tag-bg);
  color: var(--color-brand-purple);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  padding: 6px 14px;
  border-radius: 100px;
  margin-bottom: 16px;
  transition: background 0.3s;
}
[data-theme="dark"] .section-tag { color: var(--color-brand-lavender); }

/* ── Header ── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 24px;
  background: var(--c-scroll-bg);
  backdrop-filter: blur(10px);
  border-block-end: 1px solid var(--c-border-soft);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--c-text);
}

.brand-mark { width: 34px; height: 34px; flex-shrink: 0; }

.brand-name {
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 0.01em;
}

.header-controls {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.pill-btn {
  font-family: inherit;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--color-brand-purple);
  background: var(--c-tag-bg);
  border: none;
  border-radius: 100px;
  padding: 9px 16px;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}
.pill-btn:hover { transform: translateY(-1px); background: var(--c-surface-alt2); }
[data-theme="dark"] .pill-btn { color: var(--color-brand-lavender); }

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  background: var(--c-tag-bg);
  color: var(--color-brand-purple);
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}
.icon-btn:hover { transform: translateY(-1px); background: var(--c-surface-alt2); }
.icon-btn svg { width: 18px; height: 18px; }
[data-theme="dark"] .icon-btn { color: var(--color-brand-lavender); }

.icon-sun  { display: none; }
.icon-moon { display: block; }
[data-theme="dark"] .icon-sun  { display: block; }
[data-theme="dark"] .icon-moon { display: none; }

/* ── Hero ── */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: 88px 96px;
  background: linear-gradient(180deg, var(--c-bg-hero) 0%, var(--c-bg) 78%);
}

.hero-inner {
  position: relative;
  max-width: 720px;
  margin-inline: auto;
  padding-inline: 24px;
  text-align: center;
  z-index: 2;
}

.hero h1 {
  font-size: clamp(2.1rem, 4.6vw, 3.2rem);
  line-height: 1.2;
  margin: 0 0 18px;
  font-weight: 700;
  color: var(--c-text);
}

.hero p.lede {
  font-size: 1.1rem;
  color: var(--c-muted);
  max-width: 540px;
  margin-inline: auto;
  margin-block: 0 32px;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-block-end: 14px;
}

.hero-hint {
  font-size: 0.85rem;
  color: var(--c-faint);
}

.scroll-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-block-start: 56px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-brand-purple);
  text-decoration: none;
}
[data-theme="dark"] .scroll-link { color: var(--color-brand-lavender); }
.scroll-link svg { width: 14px; height: 14px; transition: transform 0.2s; }
.scroll-link:hover svg { transform: translateY(2px); }

/* Decorative floating marks in the hero */
.hero-deco { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.hero-deco svg, .hero-deco img { position: absolute; }
.deco-seed    { inset-block-start: 14%; inset-inline-start: 8%; width: 46px; }
.deco-fruit   { inset-block-start: 18%; inset-inline-end: 9%; width: 40px; }
.deco-blossom { inset-block-end: 10%; inset-inline-start: 14%; width: 34px; }
.deco-spark-1 { inset-block-start: 30%; inset-inline-end: 22%; width: 14px; }
.deco-spark-2 { inset-block-end: 24%; inset-inline-end: 12%; width: 10px; }
.deco-spark-3 { inset-block-start: 46%; inset-inline-start: 4%; width: 10px; }

@media (max-width: 640px) {
  .hero-deco { display: none; }
}

/* ── Stages (the "table" section) ── */
.stages { padding-block: 88px; }

.stages-head {
  max-width: 560px;
  margin-inline: auto;
  text-align: center;
  margin-block-end: 44px;
}

.stages-head h2 {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  margin: 0 0 12px;
  font-weight: 700;
}

.stages-head p {
  color: var(--c-muted);
  margin: 0;
}

.stage-progress {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 720px;
  margin: 0 auto 4px;
  position: relative;
  padding-inline: 8px;
}

.stage-progress::before {
  content: "";
  position: absolute;
  inset-inline: 24px;
  top: 50%;
  height: 3px;
  border-radius: 3px;
  background: var(--c-progress-bg);
  transform: translateY(-50%);
  z-index: 0;
}

.stage-progress span {
  position: relative;
  z-index: 1;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 3px solid var(--c-bg);
}

.stage-progress span:nth-child(1) { background: var(--color-brand-yellow); }
.stage-progress span:nth-child(2) { background: var(--color-brand-mint); }
.stage-progress span:nth-child(3) { background: var(--color-brand-coral); }
.stage-progress span:nth-child(4) { background: var(--color-brand-deep); }

.stages-grid {
  display: flex;
  flex-wrap: wrap;
  border: 1px solid var(--c-border-soft);
  border-radius: 20px;
  overflow: hidden;
  background: var(--c-surface);
  margin-block-start: 28px;
}

.stage-cell {
  flex: 1 1 0;
  padding: 30px 20px;
  text-align: center;
  border-inline-start: 1px solid var(--c-border-soft);
  min-width: 220px;
}
.stage-cell:first-child { border-inline-start: none; }

.stage-icon {
  width: 44px;
  height: 44px;
  margin-inline: auto;
  margin-block-end: 14px;
}

.stage-cell h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0 0 6px;
}

.stage-cell p {
  font-size: 0.9rem;
  color: var(--c-muted);
  margin: 0;
}

@media (max-width: 760px) {
  .stages-grid { flex-direction: column; }
  .stage-cell {
    border-inline-start: none;
    border-block-start: 1px solid var(--c-border-soft);
    display: flex;
    align-items: center;
    gap: 16px;
    text-align: start;
    padding: 20px;
    min-width: 0;
  }
  .stage-cell:first-child { border-block-start: none; }
  .stage-icon { margin: 0; flex-shrink: 0; }
  .stage-text { display: flex; flex-direction: column; gap: 2px; }
}

/* ── CTA section ── */
.cta {
  padding-block: 88px;
  background: var(--c-surface-card);
  transition: background-color 0.3s ease;
}

.cta-inner {
  max-width: 560px;
  margin-inline: auto;
  padding-inline: 24px;
  text-align: center;
}

.cta h2 {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  margin: 0 0 12px;
  font-weight: 700;
}

.cta p.lede {
  color: var(--c-muted);
  margin: 0 0 28px;
}

.cta .btn-primary { font-size: 1.05rem; padding: 16px 32px; }

.cta-footnote {
  margin-block-start: 16px;
  font-size: 0.85rem;
  color: var(--c-faint);
}

/* ── Footer ── */
.site-footer {
  background: var(--c-footer-bg);
  color: var(--c-footer-text);
  padding-block: 40px;
  transition: background-color 0.3s ease;
}

.footer-inner {
  max-width: 1040px;
  margin-inline: auto;
  padding-inline: 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.footer-brand .brand-mark { width: 26px; height: 26px; }
.footer-brand span {
  color: var(--c-footer-head);
  font-weight: 700;
}

.footer-tagline {
  font-size: 0.9rem;
  margin: 4px 0 0;
}

.footer-meta {
  font-size: 0.82rem;
  color: var(--c-footer-dim);
  text-align: end;
}

.footer-rule {
  border: none;
  border-block-start: 1px solid var(--c-footer-rule);
  max-width: 1040px;
  margin: 24px auto 0;
}

@media (max-width: 560px) {
  .footer-inner { text-align: center; justify-content: center; }
  .footer-meta { text-align: center; }
}
