:root {
  --bg: #ffffff;
  --bg-soft: #f8faff;
  --text: #111827;
  --muted: #5b6578;
  --line: #e6ebf3;
  --primary-start: #27beda;
  --primary-end: #784cdf;
  --card-shadow: 0 18px 48px rgba(38, 57, 119, 0.08);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
}

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

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.container {
  width: min(1120px, 92vw);
  margin: 0 auto;
}

.top-lang-bar {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(120, 76, 223, 0.12);
}

.top-lang-bar-row {
  min-height: 60px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

[dir="rtl"] .top-lang-bar-row {
  justify-content: flex-start;
}

.section {
  padding: 92px 0;
}

.section-soft {
  background: linear-gradient(130deg, #fafcff 0%, #f5f8ff 45%, #ffffff 100%);
}

.section-header {
  text-align: center;
  margin-bottom: 44px;
}

.section-header h2 {
  margin: 0;
  font-size: clamp(1.95rem, 3vw, 3.2rem);
  letter-spacing: -0.02em;
}

.section-header p {
  margin: 10px auto 0;
  color: var(--muted);
  max-width: 700px;
  font-size: 1.05rem;
}

.gradient-text {
  background: linear-gradient(100deg, var(--primary-start), var(--primary-end));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero {
  min-height: 100vh;
  display: grid;
  align-items: center;
  background:
    radial-gradient(circle at 85% 15%, rgba(39, 190, 218, 0.18), transparent 35%),
    radial-gradient(circle at 10% 85%, rgba(120, 76, 223, 0.14), transparent 35%),
    linear-gradient(120deg, #ffffff 0%, #f8fbff 55%, #fcfaff 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 56px;
  align-items: center;
}

.language-selector-wrap {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 8px 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(120, 76, 223, 0.14);
  box-shadow: 0 10px 26px rgba(38, 57, 119, 0.09);
}

.language-selector-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: #5f6b82;
  letter-spacing: 0.01em;
}

.language-selector {
  appearance: none;
  border: 1.5px solid transparent;
  border-radius: 999px;
  background:
    linear-gradient(#ffffff, #ffffff) padding-box,
    linear-gradient(110deg, rgba(39, 190, 218, 0.4), rgba(120, 76, 223, 0.45)) border-box;
  color: var(--text);
  padding: 8px 34px 8px 14px;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 8px 16px rgba(39, 55, 115, 0.1);
  background-image:
    linear-gradient(#ffffff, #ffffff),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%235f6b82' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"),
    linear-gradient(110deg, rgba(39, 190, 218, 0.4), rgba(120, 76, 223, 0.45));
  background-repeat: no-repeat, no-repeat, no-repeat;
  background-position: 0 0, right 12px center, 0 0;
  background-size: auto, 12px 8px, auto;
}

.language-selector:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 20px rgba(39, 55, 115, 0.14);
}

.language-selector:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px rgba(39, 190, 218, 0.2),
    0 12px 20px rgba(39, 55, 115, 0.14);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-logo {
  width: 28px;
  height: 28px;
  display: block;
}

.brand-dot {
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: linear-gradient(130deg, var(--primary-start), var(--primary-end));
}

.brand-name {
  font-weight: 800;
  font-size: 1.35rem;
}

.hero h1 {
  margin: 22px 0 16px;
  font-size: clamp(2.2rem, 5vw, 4.2rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
  max-width: 17ch;
}

.hero p {
  margin: 0;
  color: var(--muted);
  font-size: 1.1rem;
  max-width: 58ch;
}

.cta-row {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  border: 2px solid transparent;
  padding: 14px 24px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  color: #fff;
  background: linear-gradient(110deg, var(--primary-start), var(--primary-end));
  border: 0;
  background-clip: padding-box;
  box-shadow: 0 14px 28px rgba(74, 110, 220, 0.22);
}

.btn-secondary {
  color: var(--text);
  background: #fff;
  border-color: var(--line);
}

.phone-shell {
  position: relative;
  width: 350px;
  margin: 0 auto;
  border-radius: 44px;
  background: linear-gradient(145deg, #171c2f, #0d1222);
  padding: 14px;
  box-shadow: 0 28px 56px rgba(20, 26, 48, 0.32);
}

.phone-notch {
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  width: 148px;
  height: 28px;
  background: #0b1020;
  border-radius: 0 0 16px 16px;
  z-index: 2;
}

.phone-image {
  width: 100%;
  aspect-ratio: 45 / 97;
  object-fit: cover;
  object-position: top center;
  border-radius: 34px;
  background: linear-gradient(140deg, #f0f8ff, #f9f5ff);
}

.cards {
  display: grid;
  gap: 22px;
}

.cards.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card,
.reward-card,
.screen-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--card-shadow);
}

.card {
  padding: 30px;
}

.card h3 {
  margin: 0 0 6px;
  font-size: 1.2rem;
}

.card p {
  margin: 0;
  color: var(--muted);
}

.step-index {
  width: 30px;
  height: 30px;
  display: inline-grid;
  place-content: center;
  border-radius: 999px;
  background: linear-gradient(120deg, #334155, #1f2937);
  color: #fff;
  font-weight: 700;
  margin-bottom: 16px;
}

.how-grid {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.how-card {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: #fff;
  box-shadow: var(--card-shadow);
  text-align: center;
  padding: 34px 26px 28px;
}

.how-card .step-index {
  position: absolute;
  top: -13px;
  left: -12px;
  margin: 0;
}

.how-icon {
  width: 74px;
  height: 74px;
  margin: 0 auto 16px;
  display: grid;
  place-content: center;
  color: #fff;
  font-size: 2rem;
  border-radius: 22px;
}

.how-icon-cyan { background: linear-gradient(135deg, #27beda, #3f7fe4); }
.how-icon-purple { background: linear-gradient(135deg, #784cdf, #d247bf); }
.how-icon-orange { background: linear-gradient(135deg, #f59e0b, #ef4444); }

.how-card h3 {
  margin: 0 0 8px;
  font-size: 1.25rem;
}

.how-card p {
  margin: 0;
  color: var(--muted);
}

.how-arrow {
  position: absolute;
  right: -26px;
  top: 50%;
  transform: translateY(-50%);
  color: #bcc7da;
  font-size: 1.45rem;
  font-weight: 700;
}

.how-card:last-child .how-arrow {
  display: none;
}

[dir="rtl"] .how-arrow {
  right: auto;
  left: -26px;
  transform: translateY(-50%) scaleX(-1);
}

[dir="rtl"] .language-selector-wrap {
  padding: 6px 12px 6px 8px;
}

[dir="rtl"] .language-selector {
  padding: 8px 14px 8px 34px;
  background-position: 0 0, left 12px center, 0 0;
}

.experience-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.xp-card {
  border: 1px solid var(--line);
  border-radius: 26px;
  background: #fff;
  box-shadow: var(--card-shadow);
  padding: 22px;
}

.xp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.xp-head h3 {
  margin: 0;
  font-size: 1.08rem;
}

.xp-chip {
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 999px;
  background: linear-gradient(120deg, rgba(39, 190, 218, 0.15), rgba(120, 76, 223, 0.16));
  color: #5a35c5;
  padding: 6px 10px;
}

.xp-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.xp-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 12px;
  background: #f8f9fc;
  padding: 10px 12px;
  color: #3f4c60;
  font-size: 0.95rem;
}

.xp-list li .xp-check {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #d8deea;
  display: inline-grid;
  place-content: center;
  color: #fff;
  font-size: 0.75rem;
}

.xp-list li.done .xp-check {
  background: #22c55e;
}

.xp-list li.done {
  background: #effaf2;
  color: #7d879a;
  text-decoration: line-through;
}

.xp-progress {
  margin-top: 16px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px 10px;
}

.xp-progress small {
  grid-column: 1 / -1;
  color: #7c88a2;
}

.xp-bar {
  height: 8px;
  border-radius: 999px;
  background: #e6eaf2;
  overflow: hidden;
}

.xp-bar i {
  display: block;
  width: 25%;
  height: 100%;
  background: linear-gradient(90deg, #27beda, #784cdf);
}

.xp-progress b {
  font-size: 0.8rem;
  color: #5f6b82;
}

.xp-token {
  position: relative;
  text-align: center;
  display: grid;
  place-content: center;
  background: linear-gradient(160deg, #fff7da, #ffe9d6 40%, #ffdff0);
}

.token-badge {
  width: 116px;
  height: 116px;
  border-radius: 50%;
  display: grid;
  place-content: center;
  margin: 0 auto 14px;
  font-size: 3rem;
  color: #fff;
  background: linear-gradient(135deg, #fbbf24, #f97316);
  box-shadow: 0 18px 32px rgba(244, 135, 35, 0.3);
}

.xp-token h3 {
  margin: 0;
  font-size: 2rem;
  background: linear-gradient(90deg, #f97316, #db2777);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.xp-token p {
  margin: 2px 0 4px;
  color: #5c6477;
  font-weight: 600;
}

.xp-token small {
  color: #7b8092;
}

.spark {
  position: absolute;
  color: #f59e0b;
  font-size: 1.35rem;
}

.spark.s1 { top: 20px; left: 20px; }
.spark.s2 { bottom: 20px; right: 20px; }

.mini-box {
  border-radius: 18px;
  padding: 14px;
  margin-bottom: 12px;
}

.mini-box:last-child {
  margin-bottom: 0;
}

.mini-box.orange { background: linear-gradient(130deg, #fff2e2, #ffe7dd); }
.mini-box.purple { background: linear-gradient(130deg, #eff5ff, #f3ecff); }
.mini-box.yellow { background: linear-gradient(130deg, #fff9df, #ffeec7); }

.mini-title {
  font-weight: 700;
  margin-bottom: 4px;
}

.mini-big {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
  margin: 4px 0;
}

.mini-box small {
  color: #6a7385;
}

.streak-dots {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-top: 8px;
}

.streak-dots i {
  height: 6px;
  border-radius: 999px;
  background: #fb923c;
}

.streak-dots i.off {
  background: #d8dee8;
}

.image-fallback {
  display: none;
  margin-top: 10px;
  border-radius: 12px;
  background: #f4f7ff;
  border: 1px dashed #c6d4ef;
  color: #405174;
  padding: 12px;
  font-size: 0.85rem;
}

.phone-image[src=""] {
  display: none;
}

.phone-image[src=""] + .image-fallback {
  display: block;
}

.reward-card {
  overflow: hidden;
  padding: 0 0 26px;
}

.reward-emoji {
  font-size: 2rem;
  margin: 18px 24px 0;
}

.reward-card h3 {
  margin: 10px 24px 8px;
}

.reward-card p {
  margin: 0 24px;
  color: var(--muted);
}

.reward-image {
  width: 100%;
  height: 210px;
  object-fit: cover;
  display: block;
}

.final-cta {
  color: #fff;
  background:
    radial-gradient(circle at 15% 20%, rgba(255, 255, 255, 0.24), transparent 33%),
    radial-gradient(circle at 85% 75%, rgba(255, 255, 255, 0.18), transparent 38%),
    linear-gradient(120deg, #27beda 0%, #784cdf 55%, #9f44d6 100%);
}

.final-cta h2 {
  margin: 0;
  text-align: center;
  font-size: clamp(1.9rem, 3.2vw, 3.4rem);
  letter-spacing: -0.02em;
}

.final-cta p,
.final-cta small {
  display: block;
  text-align: center;
}

.final-cta p {
  margin: 12px auto 0;
  max-width: 58ch;
  color: rgba(255, 255, 255, 0.9);
}

.final-cta .cta-row {
  justify-content: center;
  align-items: center;
}

.btn-light {
  color: #5a33c2;
  background: #fff;
  border-color: #fff;
}

.btn-ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.08);
}

.store-badge-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.store-badge-image {
  width: 180px;
  height: auto;
  display: block;
  border-radius: 10px;
}

@media (max-width: 640px) {
  .store-badge-image {
    width: 170px;
  }
}

.site-footer {
  background: #090d17;
  color: #d0d6e4;
  padding: 34px 0;
}

.footer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.footer-row p {
  margin: 10px 0 0;
}

.site-footer a {
  color: #a7b4cc;
  text-decoration: none;
  transition: color 0.2s ease;
}

.site-footer a:hover {
  color: #ffffff;
}

.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  .section {
    padding: 76px 0;
  }

  .hero {
    min-height: auto;
    padding: 52px 0 24px;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .hero-copy {
    text-align: center;
  }

  .language-selector-wrap {
    justify-content: center;
  }

  .top-lang-bar-row {
    justify-content: center;
  }

  .brand-mark {
    justify-content: center;
  }

  .hero h1 {
    margin-left: auto;
    margin-right: auto;
  }

  .hero p {
    margin-left: auto;
    margin-right: auto;
  }

  .cta-row {
    justify-content: center;
  }

  .cards.three,
  .how-grid,
  .experience-grid {
    grid-template-columns: 1fr;
  }

  .how-arrow {
    display: none;
  }

  .phone-shell {
    width: min(350px, 86vw);
  }

  .footer-row {
    flex-direction: column;
    text-align: center;
  }
}
