/* ════════════════════════════════════════════════════════════════
   KETAB MOBIN — GET PAGE · FULL STYLESHEET
   ════════════════════════════════════════════════════════════════ */

/* ── فونت ── */
@font-face {
  font-family: 'AbarFa';
  src: url('/assets/font/AbarFaNum-VF.woff') format('woff');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* ── متغیرها ── */
:root {
  --green-deep:   #0d2818;
  --green-dark:   #153d24;
  --green-mid:    #1e5c37;
  --green-light:  #2d8a53;
  --green-brand:  #006B52;
  --green-pale:   #60BB9B;
  --gold:         #c9a84c;
  --gold-light:   #e2c47a;
  --gold-dim:     rgba(201,168,76,.3);
  --cream:        #f5edd8;
  --white:        #ffffff;
  --text-muted:   rgba(245,237,216,.55);
  --font:         'AbarFa', 'Tahoma', sans-serif;
  --r-sm:         10px;
  --r-md:         18px;
  --r-lg:         28px;
  --ease:         cubic-bezier(.25,.8,.25,1);
  --dur:          .35s;
}

/* ── ریست ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
  font-family: var(--font);
  font-weight: 400;
  background: var(--green-deep);
  color: var(--cream);
  direction: rtl;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a   { text-decoration: none; color: inherit; }
button { font-family: var(--font); cursor: pointer; border: none; background: none; padding: 0; }

/* ══════════════════════════════════════
   SLIMI CORNERS
══════════════════════════════════════ */
.slimi-corner {
  position: fixed;
  width: clamp(140px, 20vw, 240px);
  z-index: 1;
  pointer-events: none;
  opacity: 0.8;
}
.slimi-corner img { width: 100%; height: auto; }
.slimi--tr { top: 0; right: 0; }
.slimi--tl { top: 0; left: 0; transform: scaleX(-1); }
.slimi--br { bottom: 0; right: 0; transform: scaleY(-1); }
.slimi--bl { bottom: 0; left: 0; transform: scale(-1,-1); }

/* ══════════════════════════════════════
   ANIMATIONS
══════════════════════════════════════ */
[data-anim] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .6s var(--ease), transform .6s var(--ease);
}
[data-anim="fade-down"] { transform: translateY(-20px); }
[data-anim].visible    { opacity: 1; transform: translateY(0); }

/* ══════════════════════════════════════
   HERO
══════════════════════════════════════ */
.hero {
  position: relative;
  min-height: 100dvh;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  overflow: hidden;
  background:
    radial-gradient(ellipse 80% 60% at 50% 20%, #214d34 0%, var(--green-deep) 70%);
  padding-bottom: 60px;
  z-index: 2;
}

.hero__bg-orbs { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: .18;
}
.orb--1 { width: 500px; height: 500px; background: var(--green-pale); top: -10%; right: -15%; }
.orb--2 { width: 350px; height: 350px; background: var(--gold);       bottom: 10%; left: -10%; }
.orb--3 { width: 250px; height: 250px; background: var(--green-mid);  top: 50%;   left: 40%;  }

/* ناوبری */
.nav {
  position: relative;
  z-index: 10;
  padding: 24px 40px;
  display: flex;
  align-items: center;
}
.nav__logo { height: 48px; width: auto; }

/* محتوای hero */
.hero__content {
  position: relative;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 32px 24px 0;
  gap: 14px;
}

.hero__bismillah {
  font-size: .95rem;
  letter-spacing: .06em;
  color: var(--gold);
  font-weight: 400;
}

.hero__title {
  font-size: clamp(2.8rem, 8vw, 5.2rem);
  font-weight: 700;
  line-height: 1.1;
  background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold) 50%, #a07830 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  background-size: 200% 100%;
  animation: shimmer 4s ease-in-out infinite;
}

@keyframes shimmer {
  0%, 100% { background-position: 0% 50%; }
  50%       { background-position: 100% 50%; }
}

.hero__verse {
  font-size: clamp(.88rem, 2vw, 1.05rem);
  color: var(--gold-light);
  font-weight: 400;
  opacity: .85;
}

.hero__desc {
  font-size: clamp(.9rem, 2vw, 1.05rem);
  color: var(--text-muted);
  max-width: 420px;
  line-height: 1.7;
  font-weight: 400;
}

/* آمار */
.hero__stats {
  display: flex;
  gap: 0;
  background: rgba(255,255,255,.06);
  border: 1px solid var(--gold-dim);
  border-radius: var(--r-md);
  overflow: hidden;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  margin-top: 4px;
}
.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px 32px;
  gap: 4px;
}
.stat--mid {
  border-left: 1px solid var(--gold-dim);
  border-right: 1px solid var(--gold-dim);
}
.stat__num {
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--gold);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.stat__label {
  font-size: .76rem;
  color: var(--text-muted);
  font-weight: 400;
  letter-spacing: .04em;
}

/* دکمه‌های hero */
.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  padding-bottom: 4px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: var(--r-sm);
  font-family: var(--font);
  font-size: .92rem;
  font-weight: 500;
  cursor: pointer;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), background var(--dur) ease;
  border: none;
  outline: none;
}
.btn__icon { width: 20px; height: 20px; object-fit: contain; flex-shrink: 0; }

.btn--primary  { background: var(--gold); color: var(--green-deep); }
.btn--primary:hover  { background: var(--gold-light); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(201,168,76,.35); }
.btn--secondary { background: rgba(255,255,255,.1); color: var(--cream); border: 1px solid var(--gold-dim); }
.btn--secondary:hover { background: rgba(255,255,255,.18); transform: translateY(-2px); }
.btn--ghost { background: transparent; color: var(--text-muted); border: 1px solid rgba(255,255,255,.15); }
.btn--ghost:hover { color: var(--cream); border-color: rgba(255,255,255,.35); transform: translateY(-2px); }

/* ══════════════════════════════════════
   GALLERY / SLIDER
══════════════════════════════════════ */
.gallery__section {
  position: relative;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 32px 0 0;
}

.gallery__wrapper {
  position: relative;
  width: 100%;
  max-width: 900px;
  padding: 0 52px;
}

.gallery__viewport {
  overflow: hidden;
  direction: rtl;
  border-radius: var(--r-md);
}

.gallery__track {
  display: flex;
  flex-direction: row;
  gap: 16px;
  transition: transform .5s cubic-bezier(.25,.8,.25,1);
}

.gallery__slide {
  flex: 0 0 calc((100% - 32px) / 3);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0,0,0,.5);
  transition: transform .3s ease;
}
.gallery__slide:hover { transform: translateY(-6px); }
.gallery__slide img  { width: 100%; height: auto; display: block; pointer-events: none; user-select: none; }

/* دکمه‌های ناوبری */
.gallery__btn {
  position: absolute;
  top: 50%;
  transform: translateY(-60%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(201,168,76,.18);
  border: 1px solid var(--gold-dim);
  color: var(--gold-light);
  display: grid;
  place-items: center;
  transition: background var(--dur) ease, transform var(--dur) var(--ease);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 5;
}
.gallery__btn svg { width: 18px; height: 18px; }
.gallery__btn:hover { background: rgba(201,168,76,.35); transform: translateY(-60%) scale(1.08); }

/* در RTL: prev = راست، next = چپ */
.gallery__btn--prev { right: 4px; }
.gallery__btn--next { left: 4px; }

/* نقاط */
.gallery__dots {
  display: flex;
  gap: 8px;
  align-items: center;
}
.gallery__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,.25);
  border: none;
  cursor: pointer;
  transition: background var(--dur) ease, width var(--dur) var(--ease);
}
.gallery__dot.active {
  background: var(--gold);
  width: 22px;
  border-radius: 999px;
  box-shadow: 0 0 8px var(--gold-dim);
}

/* ══════════════════════════════════════
   FEATURES
══════════════════════════════════════ */
.features {
  position: relative;
  z-index: 2;
  padding: 90px 24px;
  background: linear-gradient(180deg, var(--green-deep) 0%, var(--green-dark) 100%);
}

.section-header {
  text-align: center;
  margin-bottom: 48px;
}
.section-header h2 {
  font-size: clamp(1.5rem, 4vw, 2.3rem);
  font-weight: 600;
  color: var(--cream);
  margin-bottom: 8px;
}
.section-header p {
  font-size: .92rem;
  color: var(--text-muted);
  font-weight: 400;
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
  max-width: 1000px;
  margin: 0 auto;
}

.feat-card {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(201,168,76,.12);
  border-radius: var(--r-md);
  padding: 26px 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: background var(--dur) ease, border-color var(--dur) ease, transform var(--dur) var(--ease);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.feat-card:hover {
  background: rgba(255,255,255,.08);
  border-color: rgba(201,168,76,.3);
  transform: translateY(-4px);
}

.feat-card__icon {
  width: 42px;
  height: 42px;
  background: rgba(201,168,76,.12);
  border-radius: var(--r-sm);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.feat-card__icon svg { width: 21px; height: 21px; stroke: var(--gold); }
.feat-card h3 { font-size: 1.02rem; font-weight: 600; color: var(--cream); }
.feat-card p  { font-size: .87rem; color: var(--text-muted); line-height: 1.8; font-weight: 400; }

/* ══════════════════════════════════════
   CTA / DOWNLOAD SECTION
══════════════════════════════════════ */
.cta {
  position: relative;
  z-index: 2;
  padding: 90px 24px;
  background: radial-gradient(ellipse 80% 60% at 50% 50%, var(--green-dark) 0%, var(--green-deep) 100%);
}

.cta__inner {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.cta__bismillah {
  font-size: .9rem;
  letter-spacing: .06em;
  color: var(--gold);
  font-weight: 400;
  opacity: .85;
}

.cta__inner h2 {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 700;
  color: var(--cream);
}

.cta__desc {
  font-size: .95rem;
  color: var(--text-muted);
  line-height: 1.7;
  font-weight: 400;
  max-width: 380px;
}

/* تب‌های پلتفرم */
.platform-tabs {
  display: flex;
  background: rgba(255,255,255,.06);
  border: 1px solid var(--gold-dim);
  border-radius: var(--r-md);
  padding: 5px;
  gap: 4px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  width: 100%;
  max-width: 400px;
}

.platform-tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 12px;
  border-radius: calc(var(--r-md) - 5px);
  font-size: .88rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: background var(--dur) ease, color var(--dur) ease, box-shadow var(--dur) ease;
}
.platform-tab:hover { color: var(--cream); background: rgba(255,255,255,.08); }
.platform-tab--active {
  background: rgba(201,168,76,.18);
  color: var(--gold-light);
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
}
.tab__icon { width: 18px; height: 18px; flex-shrink: 0; }

/* پنل‌ها */
.platform-panels { width: 100%; }

.platform-panel { display: none; }
.platform-panel--active { display: block; animation: panel-in .3s var(--ease) both; }

@keyframes panel-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ══════════════════════════════════════
   DOWNLOAD BUTTONS
══════════════════════════════════════ */
.dl-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

.dl-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--r-sm);
  color: var(--cream);
  text-align: right;
  direction: rtl;
  width: 100%;
  transition: background var(--dur) ease, border-color var(--dur) ease, transform var(--dur) var(--ease);
  position: relative;
  overflow: hidden;
}
.dl-btn:hover {
  background: rgba(255,255,255,.13);
  border-color: rgba(201,168,76,.35);
  transform: translateX(-3px);
}
.dl-btn:active { transform: translateX(-1px) scale(.99); }

.dl-btn--featured {
  background: rgba(201,168,76,.12);
  border-color: rgba(201,168,76,.3);
  box-shadow: 0 2px 12px rgba(201,168,76,.08);
}
.dl-btn--featured:hover {
  background: rgba(201,168,76,.2);
  border-color: rgba(201,168,76,.5);
}

.dl-btn--apk { border-style: dashed; }
.dl-btn--web { color: var(--gold-light); }
.dl-btn--web-hero { padding: 20px 22px; border-radius: var(--r-md); }

/* حالت "به‌زودی" */
.dl-btn--soon {
  opacity: .75;
  cursor: pointer;
}
.dl-btn--soon:hover {
  opacity: 1;
  background: rgba(255,255,255,.1);
  border-color: rgba(201,168,76,.25);
  transform: translateX(-2px);
}

.dl-btn__logo {
  width: 34px;
  height: 34px;
  object-fit: contain;
  border-radius: 8px;
  flex-shrink: 0;
  color: var(--gold-light);
}
.dl-btn__logo--lg { width: 42px; height: 42px; }

.dl-btn__text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  text-align: right;
}
.dl-btn__sub  { font-size: 10px; color: rgba(245,237,216,.5); letter-spacing: .03em; }
.dl-btn__name { font-size: 14.5px; font-weight: 600; color: var(--cream); line-height: 1.2; }
.dl-btn--web .dl-btn__name { color: var(--gold-light); }

.dl-btn__arrow {
  width: 17px;
  height: 17px;
  color: rgba(245,237,216,.4);
  flex-shrink: 0;
  transition: transform var(--dur) var(--ease);
  transform: scaleX(-1);
}
.dl-btn:hover .dl-btn__arrow { transform: scaleX(-1) translateX(-4px); }

.dl-btn__badge {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--gold-light);
  background: rgba(201,168,76,.15);
  border: 1px solid rgba(201,168,76,.3);
  border-radius: 99px;
  padding: 2px 8px;
  flex-shrink: 0;
}

/* فیچرهای وب */
.web-feature-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
  padding: 0 4px;
}
.web-feat {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: rgba(245,237,216,.6);
}
.web-feat svg { width: 15px; height: 15px; color: var(--gold); flex-shrink: 0; }

/* ══════════════════════════════════════
   FOOTER
══════════════════════════════════════ */
.footer {
  position: relative;
  z-index: 2;
  border-top: 1px solid rgba(201,168,76,.1);
  padding: 48px 24px;
}

.footer__inner {
  max-width: 480px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}

.footer__logo  { height: 44px; width: auto; border-radius: 12px; }
.footer__tagline { font-size: .88rem; color: var(--text-muted); font-weight: 400; }

.footer__links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  justify-content: center;
}
.footer__links a {
  font-size: .85rem;
  color: var(--text-muted);
  transition: color var(--dur) ease;
}
.footer__links a:hover { color: var(--gold-light); }

.footer__copy {
  font-size: .78rem;
  color: rgba(245,237,216,.3);
  letter-spacing: .03em;
}

/* ══════════════════════════════════════
   POPUP — به‌زودی
══════════════════════════════════════ */
.popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
}
.popup-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.popup {
  background: linear-gradient(145deg, #1c4030 0%, #0f2618 100%);
  border: 1px solid rgba(201,168,76,.3);
  border-radius: var(--r-lg);
  padding: 40px 32px 32px;
  max-width: 380px;
  width: 100%;
  position: relative;
  text-align: center;
  box-shadow: 0 32px 80px rgba(0,0,0,.6), 0 0 0 1px rgba(255,255,255,.06);
  animation: popup-in .35s cubic-bezier(.34,1.56,.64,1) both;
}

@keyframes popup-in {
  from { transform: scale(.88) translateY(20px); opacity: 0; }
  to   { transform: scale(1) translateY(0); opacity: 1; }
}

.popup-overlay.is-open .popup { animation: popup-in .35s cubic-bezier(.34,1.56,.64,1) both; }

.popup__close {
  position: absolute;
  top: 14px;
  left: 14px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255,255,255,.08);
  color: var(--text-muted);
  display: grid;
  place-items: center;
  transition: background var(--dur) ease, color var(--dur) ease;
}
.popup__close:hover { background: rgba(255,255,255,.16); color: var(--cream); }
.popup__close svg { width: 16px; height: 16px; }

.popup__icon {
  width: 64px;
  height: 64px;
  background: rgba(201,168,76,.12);
  border: 1px solid rgba(201,168,76,.25);
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin: 0 auto 16px;
}
.popup__icon svg { width: 28px; height: 28px; stroke: var(--gold); }

.popup__title {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--cream);
  margin-bottom: 4px;
}
.popup__store {
  font-size: .85rem;
  color: var(--gold-light);
  opacity: .85;
  margin-bottom: 12px;
}
.popup__desc {
  font-size: .88rem;
  color: var(--text-muted);
  line-height: 1.7;
}

.popup__divider {
  height: 1px;
  background: rgba(201,168,76,.15);
  margin: 20px 0 16px;
}

.popup__alt {
  font-size: .82rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.popup__web-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: rgba(201,168,76,.15);
  border: 1px solid rgba(201,168,76,.3);
  border-radius: var(--r-sm);
  color: var(--gold-light);
  font-size: .9rem;
  font-weight: 500;
  transition: background var(--dur) ease, transform var(--dur) var(--ease);
}
.popup__web-btn:hover { background: rgba(201,168,76,.28); transform: translateY(-2px); }
.popup__web-btn svg { width: 16px; height: 16px; }

/* ══════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════ */
@media (max-width: 600px) {
  .nav { padding: 20px 24px; }
  .stat { padding: 14px 20px; }
  .gallery__wrapper { padding: 0 44px; }
  .gallery__slide { flex: 0 0 calc((100% - 16px) / 2); }
  .slimi-corner { width: 100px; }
  .platform-tab span { display: none; }
  .platform-tab { padding: 10px; }
}

@media (min-width: 768px) {
  .dl-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .dl-grid .dl-btn--featured { grid-column: 1 / -1; }
  .dl-grid--single { display: flex; flex-direction: column; }
}

/* ══════════════════════════════════════
   FOCUS & SELECTION
══════════════════════════════════════ */
:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}
::selection { background: var(--gold); color: var(--green-deep); }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  [data-anim] { opacity: 1 !important; transform: none !important; }
}
